Ancestors

Toot

Written by Gerard Braad on 2025-01-12 at 15:26

Finally got around to running #systemd on #GitHub Codespaces

https://github.com/gbraad-devenv/fedora-systemd/

Here using #Fedora and my personalized developer images. But I added a summary that shows it is two commands that are essential:

    "overrideCommand": false,
    "privileged": true

and making sure:

USER root
ENTRYPOINT [ "/sbin/init" ]

is set for the container.

=> View attached media

=> More informations about this toot | More toots from gbraad@mastodon.social

Descendants

Written by Gerard Braad on 2025-01-12 at 15:45

This is mostly in response to the following message: https://github.com/orgs/community/discussions/68954#discussioncomment-9850884

=> View attached media

=> More informations about this toot | More toots from gbraad@mastodon.social

Written by Gerard Braad on 2025-01-13 at 05:04

Try it yourself:

https://codespaces.new/gbraad-devenv/fedora-systemd

=> More informations about this toot | More toots from gbraad@mastodon.social

Written by Scott Small on 2025-01-14 at 06:01

@gbraad I've been doing this at work for a while. Not GitHub codespaces specifically, but running systemd under Docker.

One thing I had to add was:

STOPSIGNAL SIGRTMIN+3

as without that, I'm unable to gracefully shut down any systemd container and have to forcibly kill it. This is with CentOS 7 and Oracle Linux 8.

=> More informations about this toot | More toots from smallsco@oldbytes.space

Written by Gerard Braad on 2025-01-14 at 06:32

@smallsco

I have not had this issue for podman on my workstation, but on github actions it does not shutdown/halt either. so maybe this is related.

=> More informations about this toot | More toots from gbraad@mastodon.social

Written by Scott Small on 2025-01-14 at 06:36

@gbraad Yeah, that's almost certainly it. I run systemd containers through GitHub actions regularly for work, and without setting the correct stopsignal they will hang until killed by the runner.

=> More informations about this toot | More toots from smallsco@oldbytes.space

Written by Gerard Braad on 2025-01-14 at 06:40

@smallsco Tried to use external monitoring: https://github.com/gbraad-devenv/countdown-test

so you can also gracefully stop the container from inside by informing the outside. Found it too cumbersome for general implementation.

=> More informations about this toot | More toots from gbraad@mastodon.social

Written by Gerard Braad on 2025-01-14 at 07:03

@smallsco don't want to make a docker specific Containerfile, so will run a test with --stop-signal=RTMIN+3.

=> More informations about this toot | More toots from gbraad@mastodon.social

Proxy Information
Original URL
gemini://mastogem.picasoft.net/thread/113816083666983884
Status Code
Success (20)
Meta
text/gemini
Capsule Response Time
331.833158 milliseconds
Gemini-to-HTML Time
1.128584 milliseconds

This content has been proxied by September (ba2dc).