Imagine a virtual machine... but so lightweight you can instantly launch 10s of them on your laptop.
Plus you can configure what's installed on that machine with an intuitive language (Dockerfile).
Plus you can download ready machines with e.g. mysql/Nginx/Python/whatever readily installed
# build your own Docker image ("lightweight VM")
docker build -f my.Dockerfile -t foobar . docker run foobar
# or, use ready stuff: docker run nginx docker run postgres # etc.
FROM ubuntu:20.04 SHELL ["/bin/bash", "-e", "-o", "pipefail", "-u", "-x", "-c"] ENV DEBIAN_FRONTEND=noninteractive ENV APT_GET_FLAGS="-y -q -o=Dpkg::Use-Pty=0" # Let's move the instructions that do NOT depend on Python version to the top, for the sake of better use of build cache RUN apt-get update $APT_GET_FLAGS RUN apt-get install $APT_GET_FLAGS gnupg wget RUN . /etc/os-release && echo "deb https://apt.repos.neuron.amazonaws.com ${VERSION_CODENAME} main" > /etc/apt/sources.list.d/neuron.list RUN wget -qO- https://apt.repos.neuron.amazonaws.com/GPG-PUB-KEY-AMAZON-AWS-NEURON.PUB | apt-key add - RUN apt-get update $APT_GET_FLAGS RUN apt-get install $APT_GET_FLAGS aws-neuron-tools ENV PATH=$PATH:/opt/aws/neuron/bin RUN groupadd --gid=1000 cinnaroll RUN useradd --create-home --gid=1000 --uid=1000 --no-log-init foobar
"simple build tool" xD
In fact relatively (over)complicated, compared to Gradle
Still a better choice for building Scala than Gradle,
due to abundance of well-maintained plugins
and first-class support for Scala
sbt <module>/Docker/publish
There needs to be quite a loooot of Docker containers in a modern app (think: backend, frontend, sometimes worker services, sometimes database(s))
Plus it would be nice to systematically define things like how many replicas are needed, what are the networking rules etc.
One of the most useful resources: Deployment
Specify number of replicas R,
and Deployment strives to always have R replicas of the given set of Docker containers ("Pod") around.
Binding between cluster nodes and Kubernetes pods
Making sure that the new cluster and old cluster are kept separate during a rollout of new version