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

helm3: init at 3.0.0 (help wanted) #73916

Open
wants to merge 1 commit into
base: master
from

Conversation

@novoxudonoser
Copy link
Member

@novoxudonoser novoxudonoser commented Nov 22, 2019

Motivation for this change

Add helm3 version. This version is made as a separate package because helm of version 3 is completely different from version 2 (no tiller, different templates and logic, different go dependencies ). From the user view, there is a need for both versions at the same time, cause most of Kubernetes clusters work with helm2, and new ones with helm3 at the same time. The default.nix is copied from the original helm package with modifications.

Help wanted with rename output binary to helm3. I am new to nixpkgs (its my 2nd package, 1st isn't even merged yet). As said upper - both packages helm in nixpkgs (verions2) and helm3 needed. But with this default.nix this package produces executable output as 'helm' what conflicts with old helm package. I tried to rename output in different hooks like fixupPhase, and overriding installPhase but with no success. I think its quite simple to do, but I can't google anything or find in mans.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • 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.

P.S. This is my first package build and first pr to nixpkgs, sorry if something wrong.

@rlupton20
Copy link
Contributor

@rlupton20 rlupton20 commented Dec 1, 2019

From the looks of the buildGoPackage implementation

https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/go-packages/generic/default.nix

you might want to try implementing a preInstall hook. I'm not terribly familiar with the infrastructure around building Go packages, so I might be a ways off!

'';

meta = with stdenv.lib; {
homepage = https://github.com/kubernetes/helm;

This comment has been minimized.

@doronbehar

doronbehar May 23, 2020
Contributor

NixOS/rfcs#45

Please quote the url.

sha256 = "0gx5gmj1470q3gj8v043dmm31skf83p1ckzdcfzx8wdjlglsljrj";
};

modSha256 = "06599w4rvipb669vc5rj62k2kjakz2vmpp270carf204qbm5grk8";

This comment has been minimized.

@doronbehar

doronbehar May 23, 2020
Contributor

Rebase on top of latest master and switch to vendorSha256.


modSha256 = "06599w4rvipb669vc5rj62k2kjakz2vmpp270carf204qbm5grk8";

goPackagePath = "helm.sh/helm/v3";

This comment has been minimized.

@doronbehar

doronbehar May 23, 2020
Contributor

I think this is not needed.

goPackagePath = "helm.sh/helm/v3";
subPackages = [ "cmd/helm"];

#goDeps = ./deps.nix;

This comment has been minimized.

@doronbehar

doronbehar May 23, 2020
Contributor

Remove.

@doronbehar
Copy link
Contributor

@doronbehar doronbehar commented May 23, 2020

Help wanted with rename output binary to helm3. I am new to nixpkgs (its my 2nd package, 1st isn't even merged yet). As said upper - both packages helm in nixpkgs (verions2) and helm3 needed. But with this default.nix this package produces executable output as 'helm' what conflicts with old helm package. I tried to rename output in different hooks like fixupPhase, and overriding installPhase but with no success. I think its quite simple to do, but I can't google anything or find in mans.

Yea it's a bit hard to explain why this failed, and it's definitely not ideal that you've had this experience - it shouldn't be that hard and not intuitive + undocumented. However, I once saw this working for someone:

https://github.com/NixOS/nixpkgs/pull/86927/files#diff-2663ae5d05323a4fc069b6f0f3e664fbR20

Question: If:

From the user view, there is a need for both versions at the same time, cause most of Kubernetes clusters work with helm2, and new ones with helm3 at the same time.

Then what's so wrong about having it colliding with the helm2 ?

@teto
Copy link
Contributor

@teto teto commented Aug 28, 2020

dont we have already kubernetes-helm in the repo ? should we close this ?

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.