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
aws-iam-authenticator: 0.4.0 -> 0.5.2 #109015
Conversation
9daabef
to
0bb2064
Compare
0bb2064
to
3826201
Compare
did not invest much time into this for now: builder for '/nix/store/d8haqdf4av9dg4wjpz0lzapz9zs61yn1-aws-iam-authenticator-0.5.2.drv' failed with exit code 1; last 10 log lines:
/nix/store/v76kr0rbcghcc6vx70k6xdd2ifqid98c-go-1.15.6/share/go/src/sigs.k8s.io/aws-iam-authenticator/pkg/mapper (from $GOROOT)
/build/go/src/sigs.k8s.io/aws-iam-authenticator/pkg/mapper (from $GOPATH)
go/src/github.com/kubernetes-sigs/aws-iam-authenticator/cmd/aws-iam-authenticator/server.go:26:2: cannot find package "sigs.k8s.io/aws-iam-authenticator/pkg/server" in any of:
/build/go/src/github.com/kubernetes-sigs/aws-iam-authenticator/vendor/sigs.k8s.io/aws-iam-authenticator/pkg/server (vendor tree)
/nix/store/v76kr0rbcghcc6vx70k6xdd2ifqid98c-go-1.15.6/share/go/src/sigs.k8s.io/aws-iam-authenticator/pkg/server (from $GOROOT)
/build/go/src/sigs.k8s.io/aws-iam-authenticator/pkg/server (from $GOPATH)
go/src/github.com/kubernetes-sigs/aws-iam-authenticator/cmd/aws-iam-authenticator/token.go:23:2: cannot find package "sigs.k8s.io/aws-iam-authenticator/pkg/token" in any of:
/build/go/src/github.com/kubernetes-sigs/aws-iam-authenticator/vendor/sigs.k8s.io/aws-iam-authenticator/pkg/token (vendor tree)
/nix/store/v76kr0rbcghcc6vx70k6xdd2ifqid98c-go-1.15.6/share/go/src/sigs.k8s.io/aws-iam-authenticator/pkg/token (from $GOROOT)
/build/go/src/sigs.k8s.io/aws-iam-authenticator/pkg/token (from $GOPATH)
cannot build derivation '/nix/store/2a4h1nhn2baf4qijrmsy644qc159gw3g-env.drv': 1 dependencies couldn't be built will get back. |
I started work on this before I saw this PR - I did get a build working if you want to steal my code NelsonJeppesen@edc923a I'm brand new to Nix, but it was recomened to me to switch to |
Hey @NelsonJeppesen, as you say, if you didn't raise a pr we probably could do it here, to minimize actions. 1 package built:
aws-iam-authenticator |
93d3d4f
to
1ffdcd9
Compare
ecadca3
to
fd95098
Compare
fd95098
to
56feb82
Compare
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: |
@GrahamcOfBorg build aws-iam-authenticator |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please set ldflags to -s -w
at the minimum to shrink the size of the binary (look for examples in nixpkgs). I recommend also looking upstream if they support embedding a version in the binary.
@ivankovnatsky I'm afk, could please double check that the version is reported correctly by the binary? Also, your last commit is removing stdenv that you added in the first commit, please squash those two commits so you end up with two commits one for the update and the other for ldflags. |
Co-authored-by: Nelson Jeppesen <50854675+NelsonJeppesen@users.noreply.github.com>
16f855b
to
941dfbe
Compare
941dfbe
to
7d1f55f
Compare
@kalbasit good catch, thanks. i'm not a big expert in go software packaging, so i took it from here: https://github.com/kubernetes-sigs/aws-iam-authenticator/blob/master/.goreleaser.yaml#L16. but i still could not get the version running the cli (sorry i didn't respond earlier, will create new pr no problem): tools/security/aws-iam-authenticator on patch-10 ❯ nix-build -E 'with import <nixpkgs> {} ; callPackage ./default.nix {}';
/nix/store/b6q5pb3wdxvl21n5vzwhy9prf929m9a7-aws-iam-authenticator-0.5.2
tools/security/aws-iam-authenticator on patch-10 ❯ ./result/bin/aws-iam-authenticator version
{"Version":"unversioned"}
tools/security/aws-iam-authenticator on patch-10 ❯ am i doing it wrong? |
@ivankovnatsky no worries I pushed ab987e2 to fix it. The version variable used to be called differently in version 0.5.2 as you can see here. |
@kalbasit, good catch, thanks. |
Motivation for this change
Things done
sandbox
innix.conf
on non-NixOS linux)nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
./result/bin/
)nix path-info -S
before and after)