Skip to main content

Raymii.org Raymii.org Logo

Quis custodiet ipsos custodes?
Home | About | All pages | RSS Feed | Gopher

Hi there!

I'm Remy, a developer with a focus on C, C++, linux and embedded systems.

I currently work for De Jong DUKE were I develop software for an embedded platform that powers coffee machines. This is a C++, C and Qt stack running on Yocto linux and Nucleus RTOS. It controls hardware, runs the UI and has a few utilities for IoT connectivity and configuration. Technology is mostly C++ but includes Microsoft Visual C++, Flash, Qt and ARM kernel drivers.

I've been a Linux and UNIX sysadmin for over 10 years.

To read more or get in touch, click here.

This is my personal website, these articles do not reflect or are based on work, opinions or policies of any of my (previous) employers. Any resemblance to reality is pure coincidence.

Latest Items

I enforced the AGPL on my code, here's how it went

20-10-2020 | Remy van Elst

Five years ago I made a website that allowed you to put in a few domains and get an email when the SSL certificate was about to expire. No ads, no fuss, just an easy way for people to keep tabs on their sites without setting up their own monitoring like Nagios. As with all of my software, I released it under the AGPL due to it being web based software. Recently I found a company that hosted certificatemonitor, with some modifications (branding and a dutch tanslation), without any reference to its origin, no source code provided and no mention of the license. In this article I'll talk about what I did to enforce the license and how it went. TL;DR, not as expected. The company responded timely and friendly, but did a half assed attempt (added a link to my site with 'Inspired By Remy' as the text), then after my complaints, took down the entire site.

Read more...

What does raymii.org cost to run?

27-09-2020 | Remy van Elst

Inspired by recent articles from Kev Quirk, Horst Gutmann and Jan-Lukas where they do a cost breakdown of their sites, I decided to do one as well. Kev is around USD 30, Horst is around USD 13 and Jan-Lukas is around 5 USD. Their breakdowns are interesting, from specific wordpress plugins to CDN or DNS costs. I don't have those, but I do have a multitude of small servers running this site, which add up to around USD 20, adding up two domain names gives me around USD 22 per month. It could be a lot cheaper, I only need one server for the gigantuous amounts of static HTML this site consists of, but I do have around 10.000 unique visitors each day, so having redundancy is nice. If I would go all cheap, this site would cost me no more than 2 USD a month including the domain name, but that would take the fun out of it. This article features a list of similar, how much does my site cost articles and a cost breakdown of this site.

Read more...

Tiny Tiny RSS vs Miniflux

26-09-2020 | Remy van Elst

I'm an heavy user of RSS feeds, having over 1500 feeds I follow. Without a decent feed reader that setup wouldn't work. For over eight years now I've been an happy user of Tiny Tiny RSS, a web based feed reader. But, recently I found out about 'miniflux', also a web based RSS reader. In this article I'll compare the two for my use cases, mostly mobile usage. TD;DR, I've switched to Miniflux, due to it being more suited for mobile usage, less ajax heavy, easier to subscribe to feeds and a more pleasant reading layout.

Read more...

Store multiple types in a single std::map in C++ with std::any, just like a python dict

23-09-2020 | Remy van Elst

In C++, everything has a type. When declaring a function you specify the return type and for each parameter you specify what type it is, just as for regular variables. Templates aside (those still have a type), you almost always know what type of data you're working with. There is the 'auto' keyword, which can save you a lot of typing and duplicate code, but fundamentally you're still working with types. Since C++ 17 you can use 'std::any' to store anything, without knowing the type. This is awesome for some tasks, and horrific for most use cases. In this article I'll show an example of a 'std::map' with 'std::any', that behaves like a python 'dict', it's able to store multiple different types in the same container.

Read more...

CookieNumberPrinter, incremental / idle game style numbers in C++

12-09-2020 | Remy van Elst

To level up my software development skills, I'm programming a command line game in my spare time. It is a clone of the famous cookieclicker game by ortiel. A clone of a game is simple enough to get up and running fairly quickly, but also extensible enough when needed. How do you store huge score numbers when they don't fit in a long long? How do you write a game loop, how to use threads to handle user input? Saving a game (how to design a proper save format)? Also a great way to learn about project organization, software architecture and to try out design patterns. As the game is a clone of CookieCliker, which itself is an incremental game, I had to figure out how to work with large numbers. Since this is not a university math project, I allowed myself the luxury of using Boosts Multiprecision. The library handles the large numbers, including caluclation and operations with such a number. I did want to print the numbers in Idle Style, where large numbers are displayed with a suffix, like '1 million' instead of '1000000' and so on. This 'C++' class can be used to print Boost's 'cpp_dec_float' numbers in incremental style. It's just one header.

Read more...

Get all SSH public keys from gitlab

26-08-2020 | Remy van Elst

This small snippet gets all the SSH keys from a gitlab instance. You need to be an administrator, then you can query all keys at once using the API. On the web frontend you can only see the keys per user, not all at once in an overview.

Read more...

Get number of incoming connections on specific port with ss

25-08-2020 | Remy van Elst

Recently I had to write a few monitoring plugins, one of which was a count of incoming connections to a specific network port. In the past I would have used netstat and a combination of grep and wc filter out only specific ports and established connections, but nowdays netstat is replaced by ss on ubuntu. ss has options to filter directly on all sorts of stuff, like state, ports, protocol, making the command I use more readable and use less pipes.

Read more...

Local incremental backups of Google Photos on Ubuntu with gphotos-sync

24-08-2020 | Remy van Elst

'Google Photos' no longer syncs with 'Google Drive' or with their 'Backup and Sync' desktop software. There used to be a checkbox to get your 'Google Photos' pictures in 'Google Drive' but that has been disabled. I used that feature together with their 'Backup and Sync' tool to sync all the photos in 'Google Photos' to my local Windows computer. From there I use 'DigiKam' to manage the photos and backup them offline and offsite. Due to Google removing that feature, I had to go find another way to get the pictures out of 'Google Photos', which, after a few months of (automated) use, 'gphotos-sync' on Ubuntu seems to be the best, stable choice. In this guide I'll show you how to setup incremental backups from 'Google Photos' on Ubuntu. My 'DigiKam' database moved over without problems, and now I'm glad I don't have to use Windows for picture managemant anymore.

Read more...

Get webcam resolution and info on Ubuntu and fix HD

23-08-2020 | Remy van Elst

With all the video calling nowdays due to working from home I decided to get a webcam. Since I mostly work at a workstation, I have no microphone or camera built in. A friend gave me a spare webcam, a generic non-brand. It says 'HD Camera' on the box, but by default it records in 640x480. Using a few tools on Ubuntu you can figure out what resolutions are supported for your device. It turned out to be Cheese, the webcam capture program I used, not supporting the 'mjpeg' format, just the 'yuyv' RAW format. Using another webcam program named Webcamoid solved it, that program was able to use mjpeg.

Read more...

Ubuntu Snap auto updates broke my development setup and there is no way to turn them off

Published: 01-08-2020 | Last update: 02-08-2020 | Author: Remy van Elst

After updating-by-reinstall to Ubuntu 20.04, I installed CLion via snap since that seemed more convinient than manually downloading a java installation. CLion is the best thing since sliced bread, or I mean a C/C++ IDE by JetBrains. Ubuntu snap is a packaging system made by Canonical and pushed hard in Ubuntu. Today I found out the hard way that snap auto-updates and that there is no way to turn that off permanently. CLion was updated, which I noticed because the process was killed. The update broke several key plugins for my workflow and the theme was weird. In this article I'll discuss my disgust, I as the owner of the computer want to be in full control, not some developer that decides I need auto updates. I ended up removing snap completely, and my next install will not be Ubuntu due to this.

Read more...

The Twitter Bitcoin hack can happen anywhere humans are involved

31-07-2020 | Remy van Elst

The recent twitter hack involved social engineering and access to the twitter backend. This opinion piece will show you that this sort of incident can happen everywhere as long as humans are involved. Everywhere there are manual actions or admin / backend panels, this can happen. Pay a support-slave enough and they'll delete an account 'by accident'. Or a rougue sysadmin that disables logging, does something horrible and enables logging again. I'll show you that there is no one size fits all solution. Or at least, not a single fix for all. Treating your employees well, educatingthem on risks and automating as much as possible will get you a long way.

Read more...

View all Items