musicmatzes blog

I have been playing with functional languages a few times now. I have tried Haskell, Elm and Elixir so far, but also played a bit with a LISP-like language that is implemented in Rust for being easily embeddable into Rust programs.

Lately, I also played with “roc” (, which is a new approach for a functional programming language that can compile to binary (using LLVM) that also has some new ideas.

One of these ideas, that I quite like to be honest, is the idea of “platforms”. A developer has to write a minimal platform the program they want to write runs on. This platform is nothing more and nothing less than the interface between roc and the outside world – which is stateful! So the platform deals with allocation and deallocation, talks to the operating system to, for example, read from the commandline or handle incoming network traffic. The platform has to be very minimal, and must ensure that there is no state leaked through to the roc program!

roc itself has a syntax that is rather nice, although I think there can be improvements. The idea of the authors is that roc should be easy to use, like Elixir or Elm, spark joy in the programmer and still be fast. In fact, it has been shown (in a very unscientific benchmark IIRC, but that's more due to the fact that roc is in very early development as in due to other reasons) that roc can in fact outperform imperative languages in some cases! Leveraging the power of LLVM is one of the reasons for that, but also that roc enables performance optimizations that are not possible or very hard in other circumstances.

To conclude, I am really looking forward to roc and hope that it will be more “you can play with this”-ready than it is today. Right now, compiling everything from source all the time (roc is written in Rust) and having only very few pieces of documentation available, makes playing with roc hard. I hope that will improve soon.

To quote myself:

So my ideal #functional #language #programminglanguage would be a pure functional language with traits/interfaces, ergonomics like #ruby or #elm or #elixir, performance like #rust because it compiles to binary with #llvm, with the “platform” approach #roc #roclang currently has, so one can provide minimal interfaces to the OS ...

Which would make it a perfect language for #containers and #microservices but also #CLI tooling and even websites via #wasm (if it can compile to wasm)!

... and I think roc can be that language!

Please note that roc is not released as opensource codebase at the time of writing this article, but it will be as soon as the author thinks it is time. I wrote “roc” in lowercase letters in this article because – and only because – I think that's how it is intended.

Some people might have noticed that I like to go hiking from time to time. During my hikes, I normally listen to music, techno or trance most of the time. That kind of music gives me a certain push to walk faster or keep walking, but also gives me enough “free space” in my head (is not too distracting for me like for example metal is). That's perfect for thinking about topics that concern my life at the moment.

Most of the things I am day-dreaming about are not too serious. This article is about one of them.

From a normal daydream...

My normal daydreams start off at my current situation and goes from there into a future I would like to live. Normally, it is about minimalism, being able to go hiking in other countries, for example the USA or Canada, but also Iceland, Norway or sometimes Spain (I'm more a “Go-North” kind of hiker) or having a camper van and exploring countries in Europe with it, all while being able to work while being “on the road”. That's what (digital) nomadism is, but in a more “light” variant, as (digital) nomads normally do not have a home-base (as far as I know, some of them might beg to differ).

On my last hike, though, I thought about how an utopian future life would look like, how I would like to experience the future. Some of these things might be achievable, but most of them are probably not.

And of course, all thoughts were ...

... starting with minimalism

The concept of minimalism is not only an idea that improves your life on a psychological level, but also (and maybe even more so) on a practical one, of course. If you have less things, less things can brake, can go missing or have to be taken care of.

That's of course nothing new.

But what if you have so few things that you can enable a whole new lifestyle? I wrote about “extremist minimalists” before, and maybe that's the direction these thoughts are going. Having only 100 things is most certainly complete overkill and maybe not even possible in European culture. But having, say, less than one thousand things, enables you to just pack everything you have into a (rental) car and just drive away from your current location, leaving everything behind.

On the realistic side, though, it is not that easy, is it? One must cancel their rent, must de-register their water supply, power supply, one probably must change their contact settings in their bank account, several insurance accounts. Ones employer must know about their whereabouts, even if it is only for taxes. People are not allowed to be unregistered in Germany (or even in Europe?), so they must notify the Citizens Registration Office somehow about where they are... which might not even be possible if there is no address (think of living in a camper)!

So being a minimalist is the one thing, but being able to move is a whole other story, save moving ones things around.

Being able to just move away

Being able to just hit the road and drive to another country never has been so easy in Europe. The Schengen-Abkommen made it possible for millions of Europeans to just sit in their car and drive to their neighbor country for vacation, all without actually having to go through a tedious process at the border! Crossing the border in Europe is the same as crossing from your kitchen to your living-room! Accepting a job in another country is easy in Europe (AFAIK, IANAL). One just has to accept an offer, get a flat nearby (or not, if its a remote position) and that's basically it.

Or is it? What about insurance? Will my German insurance pay if I fall down the stairs in my Paris apartment? Will my doctor in Vienna be payed by my insurance if I have to visit them? Who pays if I hit a car with my bicycle in Madrid? What if my flat in Bergen burns down, does my german insurance cover that? Probably not!

I don't know the answers to any of these questions, and although they are hypothetical, they bug me whenever I think about (digital) nomadism.

But the general idea is amazing to me. Having the option to move to Norway for a summer, to southern Spain for a winter, just because you want to is really an awesome idea and I hope I can pursue that idea at some point, maybe with a camper or maybe even without one.

From time to time (read: daily), I get messages from recruiters on platforms like LinkedIn or Xing. 99% of them do not even care to read my profile. I don't know whether this is just because they're bots, or because every recruiter uses the shotgun-approach and just sends out invitations like crazy because they actually do not care.

So here is a bullet point list for you, dear recruiters:

  • If you can't pay what my profile says, leave me alone!
  • If you cannot even read what technologies I'm interested in, leave me alone!
  • If you don't want to “hire me, but win me for your team”, leave me alone!
  • If you cannot provide a 100% remote work position, leave me alone!
  • If you think that “new opportunities with Microsoft insert any MS product here” would be interesting for me, leave me alone!

Also: If you read this in 2021 or 2022, leave me alone as well! I'm perfectly happy right now!

I've been playing with thoughts about kubernetes a lot lately. Today I finally found the courage and motivation to just try out to write some services and deploy them.

The idea was to write some simple “hello-world” style application, deploy it on some kubernetes and serve them locally on my machine – just to get the hang of the ecosystem and how it all works.

And because I'm running NixOS of course, I wanted to leverage the power of the nix package manager to ease my deployment mechanisms as far as possible.

Building docker images can be done by nixpkgs, so that's not an issue at all. There's also the great kubenix project, which can be used to generate kubernetes deployment configuration files using nix. Plus we're using kind, which is used to spawn a full kubernetes cluster inside a docker container on my notebook – that's really nice for development!

But first, we need to implement the


Writing the service(s) was rather simple (because Rust, yay)! I decided to make it not completely trivial, and to write three services:

  1. A service that serves “Hello”
  2. A service that serves “World”
  3. A service that uses the other two services and joins the strings they serve together and serve the result

The implementation of these services are rather simple and don't need any explanation for the experienced Rustacean. And because I'm assuming a fair bit of Rust knowledge here, I'm not quoting the source here.

The “echo-style” services are implemented using actix-web in version 3, the “joiner” service is implemented using it in version 4 (beta 9), because version 3 does not support calling the tokio runtime and I need to do that to be able to query the other services asyncronously without too much hassle.

All services expect a HOST and PORT environment variable to be set, which they use to bind to. The “joiner” service also expects HELLO_SERVICE and WORLD_SERVICE, which should point to the services serving the “Hello” and “World” strings respectively.

All three binaries are built using the most simple nix expression:

{ pkgs ? import <nixpkgs> {} }:

with pkgs.stdenv;
with pkgs.lib;

pkgs.rustPlatform.buildRustPackage rec {
  name = "hello-service";
  src  = pkgs.nix-gitignore.gitignoreSourcePure "target\n" ./.;

  cargoSha256 = "sha256:0nam3yr99gg0lajdha0s9pijqwblgwggqi94mg7d3wz7vfhj8c31";

  nativeBuildInputs = with pkgs; [ pkg-config makeWrapper ];
  buildInputs       = with pkgs; [ openssl ];

(the other default.nix files look similar)


I started learning about how to write the deployment following the great article from – Configuring and Testing Kuberentes Clusters with kubenix and kind.

That article is truly the main resource I used and you should definitively read it if you want to reproduce what I did here. It explains some details way better than I could!

One minor inconveniance though, is that kubenix does only support kuberentes 1.18, but I was using kubernetes 1.22 for this example service. It worked, but my implementation might stop working with kubernetes 1.23!

That said, kind can use older kubernetes versions with the --image flag when creating the cluster, which might work to get a kuberentes 1.18 up and running!

The layout of the repository is as follows:


As you can see, the service implementation is just a subdirectory. The individual services can be build using nix-build ./service-hello/ for example.

The deployment gets generated by configuration.nix, whereas default.nix is used to orchestrate the whole thing and build some neat helpers.

Building docker images

Nix has awesome tooling in nixpkgs for building docker images. We can use that to build docker images with our binaries without actually pulling in too much:

  helloImage = pkgs.dockerTools.buildLayeredImage {
    name = "hello-service";
    tag = "latest";
    config.Cmd = [ "${helloService}/bin/service-hello" ];

That goes into our default.nix.

These images are later loaded into the kind cluster (automatically, thanks to nix) when starting the cluster.

Generating the deployment

Lets have a look at the configuration.nix! The first few lines of that file are simple definitions about the services. We define their name (label), which port they run on, how much CPU the pods may use they are running in and their environment:

  helloApp = rec {
    label = "hello";
    port  = 3000;

    cpu = if type == "dev"
    then "100m"
    else "1000m";

    imagePolicy = if type == "dev"
    then "Never"
    else "IfNotPresent";

    env = [
      { name = "HOST"; value = ""; }
      { name = "PORT"; value = "${toString port}"; }

These values are later used to write the deployment of the individual services. The neat thing is: The “joiner” service needs to know (for example) which ports the other services run on. But we don't need to duplicate that data, because we can re-use it from the definition of said services:

  joinerApp = rec {
    label = "joiner";
    # ...
    env = [
      # ...
      { name = "HELLO_SERVICE"; value = "${helloApp.label}:${toString helloApp.port}"; }
      { name = "WORLD_SERVICE"; value = "${worldApp.label}:${toString worldApp.port}"; }

Using the values, we can then implement the deployments of each of the apps with all the bells and whistles as well as implementing the services in the cluster.

Last, but not least, we need to add an ingress to route traffic from outside the cluster to the “joiner” service.


That's all nice and dandy, but we also need some mechanism to deploy the whole thing, you mean?

That's where nix comes in handy! What we can do is, let nix write a script that handles all the deployment steps for us. That script gets the images we just built using docker as input, and copies them into the kind cluster when run. It also gets the generated configuration for the cluster, which it applies automatically as soon as the cluster is created (it also prints it as JSON for discoverability). Lastly, it ensures that an ingress controller is available in the cluster, which is needed for routing the incoming traffic to our “joiner” service.

Putting it all together

Finally, the default.nix file puts it all together. There are even some more possibilities than the file implements (I never actually tried to run the deploy-and-test shell).

I simply used the shell implemented by the file and ran deploy-to-kind to start the kind instance and deploy everything inside.

Wrapping up

It took me one whole day to figure out all the details, but finally I got it working. This has been a really nice experience and although kubenix seems to be unmaintained as of two years, it worked and was not too complex to use for that simple usecase.

As always, nix is a pleasure to work with, as is Rust! I hope to be able to use both professionally at some point – lets see what the future brings ;–)

“Unlocked” is a 2017 British-American action thriller movie starring Noomi Rapace and Orlando Bloom.

I had this movie on my watch list for a rather long time. Too long, to be honest. But first, let me lose some words about the


As always, I am giving away only a bare minimum of the plot so that I do not spoiler you.

CIA officer Alice works undercover at a community center in London. She passes on intel to the security services. The CIA and MI5 learn that radical imam Yazid Khaleel plans a biological attack on an American target on British soil in collaboration with American-born Islamic convert David Mercer.

That's boiled down from the plot on wikipedia.


On rottentomatoes the movie only has a rating of 4.31/10:

Unlocked strands an all-star cast in a spy thriller whose embrace of old-school formula might be refreshing if it weren't bogged down in genre clichés and a predictable plot.

I can only partly understand that. Of course the plot is a bit foreseeable, still, I was really well entertained. I did not yet see many movies with Orlando Bloom (safe Lord of the Rings and Pirates of the Caribbean of course) and he has a really nice role in this movie.

I would rate this movie with a solid 7/10!

“Thoughts” is (will be) a weekly roll-up of my mastodon feed with some notable thoughts collected into a long-form blog post. “Long form” is relative here, as I will only expand a little on some selected subjects, not write screens and screens of text on each of these subjects.

If you think I toot too much to follow, this is an alternative to follow some of my thoughts.

This week (2021-07-24 – 2021-07-30) I experienced, once again, how awesome git is. Plus, how awesome is git-annex!
Besides that, nothing interesting happened this week.

git bisect ftw

I had to merge a bunch of branches this week and although the merge itself worked, it resulted in a failing build. This was almost a no-brainer, though, because of the awesome git-bisect.

I nothing more to do than

git bisect start
git bisect bad HEAD
git bisect good old-master
git bisect run cargo check

and then go back to do something else. After a few minutes, the commit that introduced the issue was found and I was able to fix it within a few minutes.

That's how awesome git is.

git-annex is awesome, too!

Did I tell you that git is awesome? Yes. But git-annex is awesome, too!

Though, I had the issue that I wanted to diff a pdf file against its own version. Turns out, that's easily possible with some git configuration, too!

“Suicide Squad” is a 2016 American action hero movie based on DC comics.


As always, just a short teaser from wikipedia here:

In the film, a secret government agency [...] recruits imprisoned supervillains to execute dangerous black ops missions and save the world from a powerful threat in exchange for reduced sentences.

So it is basically the default super-hero installment one already knows from Marvel or DC. Nothing special.


On rottentomatoes, the movie scored only 4.9/10. I rather like these kind of action hero movies where one does not have too much to think. The movie was not dumb, with some nice action-scenes and a few funny dialogues. So I would rate it with a 6/10.

“War of the Worlds” from 2005 is a Science-Fiction action movie directed by Steven Spielberg. It features, most prominently, Tom Cruise and Dakota Fanning. The movie is based on the 1897 novel by H. G. Wells and some might know about the radio show that most dramatically broadcasted live in 1938

causing panic among its listening audience, though the scale of panic is disputed



Well, the general plot is nothing new. Aliens invade the earth and want to kill all humans. That's about it, without giving too much away. Though the plot is rather trivial, the execution of it is really good.

The movie is really exciting, featuring some really nice and thrilling scenes where one could really chew fingernails! At the end it shifts a bit towards a war-movie.


rottentomatoes ranks the movie with a solid 7/10. Tom Cruise is a really good actor and I would even say a 8/10 would be legit for this movie.

I watched it three or four times now and I will most certainly rewatch it again!

It is a bit gory though, so maybe not the best fit for an evening with your children around! Definitively not with small children.

“Thoughts” is (will be) a weekly roll-up of my mastodon feed with some notable thoughts collected into a long-form blog post. “Long form” is relative here, as I will only expand a little on some selected subjects, not write screens and screens of text on each of these subjects.

If you think I toot too much to follow, this is an alternative to follow some of my thoughts.

This week (2021-07-17– 2021-07-23) I executed more steps toward minimalism and created a profile on a website I do not like.

More minimalism

This week I donated some clothes I don't need anymore (and haven't used for ... a rather long time). I also removed some boxes from my apartment as well, which was also a good feeling.

I also experienced, and I guess that's the same feeling as with the minimalism by removing stuff you don't need, a nice feeling about my removal of github from my everyday websites.


This week, I also created a linkedIn profile.

I was always against these kind of data-silo services, but I have to admit that LinkedIn can provide value for ones life and I am now trying it out. Lets see where the journey goes.

Building a backup solution

I am building a simple (“off-shore”) backup solution with a RaspberryPi 4B and some external drives. This week I ordered all the parts, and managed to order the wrong SD card. But besides that, everything is going as planned. Of course I ordered a new one right away.

“The old Guard” is a 2020 superhero action movie that really got me.


The plot is rather simple overall: four secret super heros that are immortal are being hunted for something (I'm not telling because that'd be a spoiler already). Suddenly, something strange happens.


According to wikipedia, the movie has only a weak 6.5/10 on rottentomatoes. That's really bad, because I would rate it with at least 8.5 or more.

The movie features great action scenes, is not themed with the clean and sleek (marvelesque) Super-Hero style and has some tension to it. I really liked it and can recommend it!