linux - systemd support

This commit is contained in:
bunkerity
2021-08-16 15:21:44 +02:00
parent 57e4247eab
commit 2b3b4a5c3f
8 changed files with 64 additions and 19 deletions

3
tests/Dockerfile-debian Normal file
View File

@@ -0,0 +1,3 @@
FROM debian:buster-slim
RUN apt update && apt install -y systemd

3
tests/Dockerfile-fedora Normal file
View File

@@ -0,0 +1,3 @@
FROM fedora:34
RUN dnf install -y systemd

3
tests/Dockerfile-ubuntu Normal file
View File

@@ -0,0 +1,3 @@
FROM ubuntu:focal
RUN apt update && apt install -y systemd

View File

@@ -12,7 +12,7 @@ if [ "$3" == "no" ] ; then
fi
echo "[*] Run $image"
id="$(docker run --rm -d -it -p 80:80 -p 443:443 --name "$name" "$image")"
id="$(docker run --rm -d -p 80:80 -p 443:443 --privileged=true --name "$name" "$image" /sbin/init)"
if [ $? -ne 0 ] ; then
echo "[!] docker run failed"
cleanup "$name"