Skip to content

Update component template to support Podman out of the box#432

Merged
mhutter merged 1 commit into
masterfrom
podman
Mar 29, 2022
Merged

Update component template to support Podman out of the box#432
mhutter merged 1 commit into
masterfrom
podman

Conversation

@mhutter

@mhutter mhutter commented Mar 29, 2022

Copy link
Copy Markdown
Contributor

While it was already possible to use podman by setting the DOCKER_CMD
env var, this was not enough for most commands.

This commit adds support for Podman out of the box. If Docker is
installed, it will be preferred over Podman to stay
backwards-compatible.

The --userns=keep-id flag is required on Podman to ensure that 1.) the
process in the container can write to the mounted workdirs, and 2.)
ensure files created by processes in the container have the correct owner
and group IDs: The ones from the user running the Make tasks.

Checklist

  • Keep pull requests small so they can be easily reviewed.
  • Update the documentation.
  • Update tests.
  • Categorize the PR by setting a good title and adding one of the labels:
    bug, enhancement, documentation, change, breaking, dependency
    as they show up in the changelog
  • Link this PR to related issues.

@mhutter mhutter self-assigned this Mar 29, 2022
@mhutter mhutter added the change PR with a minor change which affects users label Mar 29, 2022
@mhutter mhutter requested a review from simu March 29, 2022 13:30

@simu simu left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Strictly speaking this should probably be 2 PRs:

  1. "Update component template to support Podman out of the box" (enhancement)
  2. "Update Commodore Makefile to support Podman out of the box" (change)

While it was already possible to use podman by setting the DOCKER_CMD
env var, this was not enough for most commands.

This commit adds support for Podman out of the box. If Docker is
installed, it will be preferred over Podman to stay
backwards-compatible.

The `--userns=keep-id` flag is required on Podman to ensure that 1.) the
process in the container can write to the mounted workdirs, and 2.)
ensure files created by processes in the container have the correct
owner and group IDs: The ones from the user running the Make tasks.

Signed-off-by: Manuel Hutter <manuel@hutter.io>
@mhutter mhutter changed the title Support Podman out of the box Update component template to support Podman out of the box Mar 29, 2022
@mhutter mhutter added enhancement New feature or request and removed change PR with a minor change which affects users labels Mar 29, 2022
@mhutter mhutter merged commit 11949f6 into master Mar 29, 2022
@mhutter mhutter deleted the podman branch March 29, 2022 14:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants