Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove cpanm cache to fix uid issue when using rootless container #5385

Merged
merged 1 commit into from
Mar 22, 2024

Conversation

ioanrogers
Copy link
Contributor

@ioanrogers ioanrogers commented Mar 14, 2024

This is similar to #3785 except in this case the high uid is for a file that does not need to be in the super-linter image as it is just build cache.

Pulling v6.3.0 is failing when using docker with user uid remapping:

failed to register layer: Container ID 197609 cannot be mapped to a host ID

Trying to pull with rootless podman show a more useful:

Error: copying system image from manifest list: writing blob: adding layer with blob "sha256:98088679e87a1114d3dafa114c911c1d8e5d33fffe624cfdd43b589a136a5f0f": ApplyLayer stdout:  stderr: potentially insufficient UIDs or GIDs available in user namespace (requested 197609:197609 for /root/.cpanm/work/1708379740.11/PPI-1.277): Check /etc/subuid and /etc/subgid if configured locally and run podman-system-migrate: lchown /root/.cpanm/work/1708379740.11/PPI-1.277: invalid argument exit status 1

Proposed changes

Remove the cpanm work dir.

Readiness checklist

In order to have this pull request merged, complete the following tasks.

Pull request author tasks

  • I included all the needed documentation for this change.
  • I provided the necessary tests.
  • I squashed all the commits into a single commit.
  • I followed the Conventional Commit v1.0.0 spec.
  • I wrote the necessary upgrade instructions in the upgrade guide.
  • If this pull request is about and existing issue,
    I added the Fix #ISSUE_NUMBER label to the description of the pull request.

Super-linter maintainer tasks

  • Label as breaking if this change breaks compatibility with the previous released version.
  • Label as either: automation, bug, documentation, enhancement, infrastructure.

@ioanrogers ioanrogers marked this pull request as draft March 14, 2024 22:45
@ioanrogers ioanrogers marked this pull request as ready for review March 15, 2024 19:45
Pulling v6.3.0 is failing when using docker with user uid remapping:
```
failed to register layer: Container ID 197609 cannot be mapped to a host ID
```

Trying to pull with rootless podman show a more useful:

```
Error: copying system image from manifest list: writing blob: adding layer with
blob "sha256:98088679e87a1114d3dafa114c911c1d8e5d33fffe624cfdd43b589a136a5f0f":
ApplyLayer stdout:  stderr: potentially insufficient UIDs or GIDs available in
user namespace (requested 197609:197609 for /root/.cpanm/work/1708379740.11/PPI-1.277):
Check /etc/subuid and /etc/subgid if configured locally and run podman-system-migrate:
lchown /root/.cpanm/work/1708379740.11/PPI-1.277: invalid argument exit status 1
```

The `/root/.cpanm` is just a build cache and can be safely removed.
@ferrarimarco ferrarimarco added this pull request to the merge queue Mar 22, 2024
Merged via the queue into super-linter:main with commit b00466d Mar 22, 2024
44 of 45 checks passed
@ioanrogers ioanrogers deleted the fix-uid branch April 9, 2024 14:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants