istioctl: bundle release metadata
This is required for `istioctl version` to return the correct info, and for `istioctl install` to default to the correct Docker images.
This commit is contained in:
parent
0f23e0b661
commit
76856fc333
1 changed files with 11 additions and 0 deletions
|
@ -14,11 +14,22 @@ buildGoModule rec {
|
|||
|
||||
nativeBuildInputs = [ go-bindata ];
|
||||
|
||||
# Bundle charts
|
||||
preBuild = ''
|
||||
patchShebangs operator/scripts
|
||||
operator/scripts/create_assets_gen.sh
|
||||
'';
|
||||
|
||||
# Bundle release metadata
|
||||
buildFlagsArray = let
|
||||
attrs = [
|
||||
"istio.io/pkg/version.buildVersion=${version}"
|
||||
"istio.io/pkg/version.buildStatus=Nix"
|
||||
"istio.io/pkg/version.buildTag=${version}"
|
||||
"istio.io/pkg/version.buildHub=docker.io/istio"
|
||||
];
|
||||
in ["-ldflags=${lib.concatMapStringsSep " " (attr: "-X ${attr}") attrs}"];
|
||||
|
||||
subPackages = [ "istioctl/cmd/istioctl" ];
|
||||
|
||||
meta = with lib; {
|
||||
|
|
Loading…
Reference in a new issue