Skip to content

Commit b8620a2

Browse files
authored
Enable --init for podman container
We had some issues with signals/killing child processes, which was fixed by running sshd in a loop. However, using /bin/sh as PID1 is not ideal, as it might not reap dead processes or handle signal forwarding, so it's better to use a small init process, as we're running full-fledged long-term environment in a container, and not simple well-known service from the image itself.
1 parent 53d431f commit b8620a2

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

bob/mkosi.extra/usr/bin/init-container.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ SEARCHER_INPUT_CHANNEL=27017
1212
echo "Starting $NAME..."
1313
su -s /bin/sh searcher -c "cd ~ && podman run -d \
1414
--name $NAME --replace \
15+
--init \
1516
-p ${SEARCHER_SSH_PORT}:22 \
1617
-p ${ENGINE_API_PORT}:${ENGINE_API_PORT} \
1718
-p ${EL_P2P_PORT}:${EL_P2P_PORT} \
@@ -82,4 +83,4 @@ su -s /bin/sh searcher -c "podman exec $NAME /bin/sh -c '
8283
echo \"18.221.59.61 backruns.tee-searcher.flashbots.net\" >> /etc/hosts &&
8384
echo \"3.15.88.156 backruns.tee-searcher.flashbots.net\" >> /etc/hosts &&
8485
echo \"52.207.17.217 fbtee.titanbuilder.xyz\" >> /etc/hosts
85-
'"
86+
'"

0 commit comments

Comments
 (0)