Container runs systemd, what's the easiest way to execute a script that uses systemd?
1
vote
1
answer
360
views
I have a container that runs systemd, the setup instructions followed can be found at
* [*Dockerfile for systemd base image*](https://hub.docker.com/_/centos)
Now I have a script
install.sh
which I need to run in the build phase over the base image created above. The problem is that the install.sh
is systemd aware.
So what is the easiest way to have systemd's init run that install.sh
, what I want is something like
buildah run $ctr -- sh /tmp/install.sh
But this will **not** run install.sh
under systemd, as I require.
Asked by Evan Carroll
(34663 rep)
Nov 13, 2020, 08:18 PM
Last activity: Nov 14, 2020, 08:20 PM
Last activity: Nov 14, 2020, 08:20 PM