Skip to content

Commit 5e3e2a8

Browse files
committed
[werft] add configcat key env into workspace template
1 parent d70b54d commit 5e3e2a8

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

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

+4-1
Original file line numberDiff line numberDiff line change
@@ -247,10 +247,13 @@ EOF`);
247247

248248
private configureConfigCat(slice: string) {
249249
// This key is not a secret, it is a unique identifier of our ConfigCat application
250+
const configcatKey = "WBLaCPtkjkqKHlHedziE9g/LEAOCNkbuUKiqUZAcVg7dw";
250251
exec(
251-
`yq w -i ${this.options.installerConfigPath} experimental.webapp.configcatKey "WBLaCPtkjkqKHlHedziE9g/LEAOCNkbuUKiqUZAcVg7dw"`,
252+
`yq w -i ${this.options.installerConfigPath} experimental.webapp.configcatKey "${configcatKey}"`,
252253
{ slice: slice },
253254
);
255+
exec(`yq w -i ${this.options.installerConfigPath} 'workspace.templates.default.spec.containers.(name==workspace).env[+].name' GITPOD_CONFIGCAT_SDK_KEY`);
256+
exec(`yq w -i ${this.options.installerConfigPath} 'workspace.templates.default.spec.containers.(name==workspace).env.(name==GITPOD_CONFIGCAT_SDK_KEY).value' "${configcatKey}"`);
254257
}
255258

256259
private includeAnalytics(slice: string): void {

0 commit comments

Comments
 (0)