Ubuntu 22.04 LTS Docker container with systemd, useful for tests with ansible
especially with molecule
22.04
,jammy
,latest
on main branch20.04
,focal
on main branch18.04
,bionic
on 18.04 branch16.04
,bionic
on 16.04 branch
- Verify if Docker is installed.
- Run on main branch:
docker build -t docker-ubuntu-systemd:22.04 -t docker-ubuntu-systemd:latest .
- Run on 20.04 branch:
docker build -t docker-ubuntu-systemd:20.04 -t docker-ubuntu-systemd:focal .
- Run on 18.04 branch:
docker build -t docker-ubuntu-systemd:18.04 -t docker-ubuntu-systemd:bionic .
- Run on 16.04 branch:
docker build -t docker-ubuntu-systemd:16.04 -t docker-ubuntu-systemd:xenial .
- Verify image:
docker images
docker pull eniocarboni/docker-ubuntu-systemd:latest
(or use the image you built earlier).docker run --detach --privileged --volume=/sys/fs/cgroup:/sys/fs/cgroup:ro eniocarboni/docker-ubuntu-systemd:latest
View the run container with
docker ps
Enter in the container with:
docker exec -it <container_id> bash
Kill container with:
docker kill <container_id>
Remove container with:
docker image rm -f <container_id>
Created in 2022 by Enio Carboni
GNU GENERAL PUBLIC LICENSE (see LICENSE file)