Skip to content

Commit 8ff03b0

Browse files
Andrew Farriesroboquat
authored andcommitted
Remove shortname from preview installations
Use `yq -m` to merge an inline config rather than `yq -w` because the old version of `yq` we have installed does not support setting fields to the empty string literal.
1 parent 50692e5 commit 8ff03b0

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

.werft/jobs/build/installer/installer.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ export class Installer {
5858
this.options.werft.log(slice, "Adding extra configuration");
5959
try {
6060
this.getDevCustomValues(slice)
61+
this.configureMetadata(slice)
6162
this.configureContainerRegistry(slice)
6263
this.configureDomain(slice)
6364
this.configureWorkspaces(slice)
@@ -94,6 +95,14 @@ export class Installer {
9495
exec(`yq m -i ${this.options.installerConfigPath} ${WORKSPACE_SIZE_CONFIG_PATH}`, { slice: slice });
9596
}
9697

98+
private configureMetadata(slice: string): void {
99+
exec(`cat <<EOF > shortname.yaml
100+
metadata:
101+
shortname: ""
102+
EOF`)
103+
exec(`yq m -ix ${this.options.installerConfigPath} shortname.yaml`, { slice: slice });
104+
}
105+
97106
private configureContainerRegistry(slice: string): void {
98107
exec(`yq w -i ${this.options.installerConfigPath} certificate.name ${this.options.proxySecretName}`, { slice: slice });
99108
exec(`yq w -i ${this.options.installerConfigPath} containerRegistry.inCluster false`, { slice: slice });

0 commit comments

Comments
 (0)