/ DevOps

The Ephemeral Immutable App

Historically we have built our servers to fit the shape of our applications. There is an unending way to install and configure a running application, to size the memory and disk, and so forth. This has changed dramatically with the advent of simple to use containers. Instead, the world is changing so that applications must fit the shape of the container, and this is a good thing.

When containers are used properly, they offer significant savings in management and costs, through the very fact that they are uniform. All too often, however, it is easy to forget the value-proposition of a container, and to try to reshape it to meet the needs of the application.

For a container to be effective, the application must be configured as a 12-factor app, and additionally it must be an ephemeral application--or effectively the running container must be so stateless that it can be destroyed and reloaded at any point in time without losing any application stability. Ephemeral execution is what the 12-factor application rules are building towards.

This is not just a story about making a highly scalable application. The ephemeral application container must also be stateless in its own concepts of environments or stages. The same container image should be able to be deployed in a testing environment, staging environment, and production environment, and it only learns how it should behave at run-time as the state is introduced when it is launched, and it is never updated during its lifecycle.

The difference between containers and virtualized servers, is that virtualized servers simply extended the concept of a server into being able to be stacked. We still have to update the server images, whether they are virtual or physical, and server automation, while it has progressed by leaps and bounds, is still a very expensive proposition.

To explain it simply: an Ephemeral App container is never updated from the point it is launched, even for code or hot fixes. If a change is needed, a new container is built and deployed. This is somewhat different from how containers are currently used.

When applications containers are built in this manner, everything becomes a simple building block where all blocks can be easily manipulated and stacked. Next time you are involved in working on containers, keep the concept of an ephemeral app in mind. If you are trying to make your container look like a server, or if you want to update your running container, you might have missed the purpose of having a container.

Brandon Gillespie

Brandon Gillespie

Brandon loves Tech and has a breadth of experience including hands-on Implementation and Leadership Roles across many companies including small startups, enterprises, and the USAF.

Read More