Embedded systems are small clouds

Let’s look at embedded Linux as a set of services.

Due to security, we cannot allow applications to do anything they want, even if the application is part of the core system.

We write rules that constrain what they can access. We define users and groups to express ownership and the ability to read. Using security frameworks, we define even more detailed access rules.

That sounds pretty similar to what access management services do in the cloud.

There are more similarities. Linux provides us with even more services, including one that actually manages services.

We do not need to reinvent the logging system — Linux has one that works pretty much out of the box.

For networking rules, we have firewall services and packet filtering services. We can choose an implementation of a container service, as well as a key-value datastore.

For SQL in embedded systems, there is one king, readily available.

On the other hand, embedded systems do not scale. We will not be able to add more CPU or memory when we need it, so some optimizations need to be considered. We do not have infrastructure-as-code tools like the ones for the cloud, we do not have a nice API, or web access. It all makes it a little harder to start seeing it like this, but I think it is worth it.

The reason I am writing this is to show you that embedded applications do not have to be monolithic and do everything by themselves. There are reliable options in Linux that can save you a lot of code. Also, many design patterns are applicable for embedded systems. I think there is nothing wrong with microservices, if applied in the right place.

Embedded Linux can be fun.