msys2 / msys2/msys2-docker

potential for zombie processes if not running docker with `--init` option

Open
#5 8 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Dockerfile
Stars
39
Forks
11
PR merge metrics
No merged PRs in 30d

Description

In GHA, at least when using tmate action, it seems that PID 1 (serving the role init should) is filled by an instance of tail. Obviously, that does not reap unparented child processes like init is supposed to, and wine appears to use the double-fork trick to avoid having to wait on child processes, which means that PID 1 then has to. The workaround seems to be to specify the --init option to docker:
https://docs.github.com/en/actions/using-jobs/running-jobs-in-a-container#setting-container-resource-options
https://docs.docker.com/reference/cli/docker/container/create/#options

jobs:
  main:
    runs-on: ubuntu-latest
    container:
      image: ghcr.io/msys2/msys2-docker-experimental:latest
      options: --init
    steps:
      - name: tmate
        uses: mxschmitt/action-tmate@v3

I think this is something that just needs to be documented, I don't know if there's anything that can be done to the image to solve this. Then again, I'm no docker expert...

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the linked GitHub Actions container options and Docker container-create documentation, focusing on the --init option and the example workflow in the issue. Document the workaround and why it prevents zombie processes when using this image, with guidance that is complete enough for users to apply it.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, github-actions
Domain
devops
Issue type
Documentation
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.