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
@ -14,11 +14,22 @@ buildGoModule rec {
|
|||||||
|
|
||||||
nativeBuildInputs = [ go-bindata ];
|
nativeBuildInputs = [ go-bindata ];
|
||||||
|
|
||||||
|
# Bundle charts
|
||||||
preBuild = ''
|
preBuild = ''
|
||||||
patchShebangs operator/scripts
|
patchShebangs operator/scripts
|
||||||
operator/scripts/create_assets_gen.sh
|
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" ];
|
subPackages = [ "istioctl/cmd/istioctl" ];
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user