diff options
-rw-r--r-- | .cirrus.yml | 4 | ||||
-rwxr-xr-x | contrib/cirrus/runner.sh | 10 | ||||
-rw-r--r-- | docs/tutorials/rootless_tutorial.md | 6 | ||||
-rw-r--r-- | test/e2e/build/Containerfile.with-platform | 1 |
4 files changed, 18 insertions, 3 deletions
diff --git a/.cirrus.yml b/.cirrus.yml index 81bbe7c8f..14d3540c1 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -167,14 +167,18 @@ build_task: VM_IMAGE_NAME: ${FEDORA_CACHE_IMAGE_NAME} CTR_FQIN: ${FEDORA_CONTAINER_FQIN} # ID for re-use of build output + CI_DESIRED_RUNTIME: crun - env: &priorfedora_envvars DISTRO_NV: ${PRIOR_FEDORA_NAME} VM_IMAGE_NAME: ${PRIOR_FEDORA_CACHE_IMAGE_NAME} CTR_FQIN: ${PRIOR_FEDORA_CONTAINER_FQIN} + CI_DESIRED_RUNTIME: crun - env: &ubuntu_envvars DISTRO_NV: ${UBUNTU_NAME} VM_IMAGE_NAME: ${UBUNTU_CACHE_IMAGE_NAME} CTR_FQIN: ${UBUNTU_CONTAINER_FQIN} + # FIXME 2022-07-12: change to runc once #14833 is fixed! + CI_DESIRED_RUNTIME: crun env: TEST_FLAVOR: build clone_script: *full_clone diff --git a/contrib/cirrus/runner.sh b/contrib/cirrus/runner.sh index 762a3b501..32f66bac2 100755 --- a/contrib/cirrus/runner.sh +++ b/contrib/cirrus/runner.sh @@ -236,6 +236,16 @@ function _run_build() { make clean make vendor make podman-release # includes podman, podman-remote, and docs + + # Last-minute confirmation that we're testing the desired runtime. + # This Can't Possibly Failâ„¢ in regular CI; only when updating VMs. + # $CI_DESIRED_RUNTIME must be defined in .cirrus.yml. + req_env_vars CI_DESIRED_RUNTIME + runtime=$(bin/podman info --format '{{.Host.OCIRuntime.Name}}') + # shellcheck disable=SC2154 + if [[ "$runtime" != "$CI_DESIRED_RUNTIME" ]]; then + die "Built podman is using '$runtime'; this CI environment requires $CI_DESIRED_RUNTIME" + fi } function _run_altbuild() { diff --git a/docs/tutorials/rootless_tutorial.md b/docs/tutorials/rootless_tutorial.md index 981916806..d9cf68a20 100644 --- a/docs/tutorials/rootless_tutorial.md +++ b/docs/tutorials/rootless_tutorial.md @@ -186,10 +186,10 @@ We do recognize that this doesn't really match how many people intend to use roo It is also helpful to distinguish between running Podman as a rootless user, and a container which is built to run rootless. If the container you're trying to run has a `USER` which is not root, then when mounting volumes you **must** use `--userns=keep-id`. This is because the container user would not be able to become `root` and access the mounted volumes. -Other considerations in regards to volumes: +Another consideration in regards to volumes: -- You should always give the full path to the volume you'd like to mount -- The mount point must exist in the container +- When providing the path of a directory you'd like to bind-mount, the path needs to be provided as an absolute path + or a relative path that starts with `.` (a dot), otherwise the string will be interpreted as the name of a named volume. ## More information diff --git a/test/e2e/build/Containerfile.with-platform b/test/e2e/build/Containerfile.with-platform index 3bb585a0a..0b030d13c 100644 --- a/test/e2e/build/Containerfile.with-platform +++ b/test/e2e/build/Containerfile.with-platform @@ -1 +1,2 @@ +ARG TARGETPLATFORM FROM --platform=$TARGETPLATFORM alpine |