Skip to content

docker-compose: fix rm command argument #392853

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

Merged
merged 1 commit into from
Mar 25, 2025

Conversation

leoperegrino
Copy link
Contributor

This PR aims to fix a minor argument error in the docker compose derivation. Also discussed here #196654 (comment).

As you can see in the compose file tree here for this tag e2e package is actually under the pkg directory, meaning: pkg/e2e.

Using rm -rf e2e/ is a silent error: the code will try to remove a nonexistent directory. In this case the build only passes because doCheck = false even though there is a directory pkg/e2e. If one wants to perform the tests and set it to true this will fail due to the e2e package.

To test:

  1. set doCheck = true
  2. build and fail
  3. set rm -rf pkg/e2e/ in postPatch
  4. build and succeed

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 25.05 Release Notes (or backporting 24.11 and 25.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

`e2e` package is actually under the `pkg` directory
@github-actions github-actions bot added the 6.topic: docker tools Open-source software for deploying and running of containerized applications label Mar 24, 2025
@NixOSInfra NixOSInfra added the 12.first-time contribution This PR is the author's first one; please be gentle! label Mar 24, 2025
@github-actions github-actions bot added 10.rebuild-darwin: 11-100 This PR causes between 11 and 100 packages to rebuild on Darwin. 10.rebuild-linux: 11-100 This PR causes between 11 and 100 packages to rebuild on Linux. labels Mar 24, 2025
Copy link
Contributor

@drupol drupol left a comment

Choose a reason for hiding this comment

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

Hello,

Thanks for your first PR against the Nixpkgs repository !

The diff LGTM, going to approve this now.

Keep PRs coming :)

@drupol drupol merged commit 7ebe5f0 into NixOS:master Mar 25, 2025
29 of 30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.topic: docker tools Open-source software for deploying and running of containerized applications 10.rebuild-darwin: 11-100 This PR causes between 11 and 100 packages to rebuild on Darwin. 10.rebuild-linux: 11-100 This PR causes between 11 and 100 packages to rebuild on Linux. 12.first-time contribution This PR is the author's first one; please be gentle!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants