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

docker-slim: init at 1.26.1 #75564

Closed
wants to merge 1 commit into from
Closed

Conversation

@Br1ght0ne
Copy link
Contributor

@Br1ght0ne Br1ght0ne commented Dec 12, 2019

Motivation for this change

https://github.com/docker-slim/docker-slim/releases/tag/1.26.1

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nix-review --run "nix-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

This change is Reviewable

@Br1ght0ne Br1ght0ne force-pushed the Br1ght0ne:docker-slim-1.26.1 branch from bc9edfd to e2ea94f Dec 12, 2019
@Br1ght0ne
Copy link
Contributor Author

@Br1ght0ne Br1ght0ne commented Dec 12, 2019

@GrahamcOfBorg build docker-slim

@Br1ght0ne
Copy link
Contributor Author

@Br1ght0ne Br1ght0ne commented Dec 12, 2019

Why does the x86_64-darwin build get different hashes for the source derivation? Weird.

@@ -0,0 +1,29 @@
{ buildGoModule, fetchFromGitHub, stdenv, docker }:

buildGoModule rec {

This comment has been minimized.

@marsam

marsam Dec 13, 2019
Contributor

please use buildGoPackage, because upstream vendorizes its dependencies

This comment has been minimized.

@Br1ght0ne

Br1ght0ne Dec 13, 2019
Author Contributor

Sure, thanks. Can you please tell me how to recognize that myself so I can be better in the future?

This comment has been minimized.

@Ma27

Ma27 Dec 14, 2019
Member

Sure, thanks. Can you please tell me how to recognize that myself so I can be better in the future?

If upstream has its dependencies in a vendor/ directory, it's fine to use buildGoPackage, if go.mod is used, buildGoModule can be used :)

This comment has been minimized.

@marsam

marsam Dec 16, 2019
Contributor

sorry for the delay

Can you please tell me how to recognize that myself so I can be better in the future?

The main difference between both, is that buildGoModule abuses fixed-output derivations which may not be preferable; because introduces impurities, such as network access NixOS/nix#2270

As @Ma27 mentioned, we should buildGoPackage when a package vendorizes its dependencies (vendor/ directory), since it's a regular expression and we don’t have to maintain a deps.nix
In the rest of the cases, the maintainer can choose which function to use

homepage = "https://github.com/docker-slim/docker-slim";
license = licenses.asl20;
maintainers = with maintainers; [ filalex77 ];
platforms = docker.meta.platforms;

This comment has been minimized.

@marsam

marsam Dec 13, 2019
Contributor

just curious, does it depend on docker?

This comment has been minimized.

@Br1ght0ne

Br1ght0ne Dec 13, 2019
Author Contributor

It takes images by name, so I assume it asks Docker for them.

@mbrgm
Copy link
Member

@mbrgm mbrgm commented Jan 2, 2020

@filalex77 Did you get a chance to make the requested changes? I also started packaging this module and found your PR on the way.

@Br1ght0ne
Copy link
Contributor Author

@Br1ght0ne Br1ght0ne commented Jan 2, 2020

@mbrgm I ran into some issues with the proposed changes, and didn't have the time to figure it out. You're more than welcome to submit your PR, just let me know - and I'll close this one. Thanks!

@mbrgm mbrgm mentioned this pull request Jan 2, 2020
6 of 10 tasks complete
@mbrgm
Copy link
Member

@mbrgm mbrgm commented Jan 2, 2020

@filalex77 See #76831. Feel free to review the new PR.

@Br1ght0ne
Copy link
Contributor Author

@Br1ght0ne Br1ght0ne commented Jan 3, 2020

Closing in favor of #76831.

@Br1ght0ne Br1ght0ne closed this Jan 3, 2020
@Br1ght0ne Br1ght0ne deleted the Br1ght0ne:docker-slim-1.26.1 branch Jan 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

4 participants
You can’t perform that action at this time.