@@ -106,6 +106,7 @@ async function build(context, version) {
106
106
const withInstaller = "with-installer" in buildConfig || masterBuild ;
107
107
const noPreview = "no-preview" in buildConfig || publishRelease ;
108
108
const registryFacadeHandover = "registry-facade-handover" in buildConfig ;
109
+ const gcpStorage = "gcp-storage" in buildConfig ;
109
110
werft . log ( "job config" , JSON . stringify ( {
110
111
buildConfig,
111
112
version,
@@ -117,6 +118,7 @@ async function build(context, version) {
117
118
dynamicCPULimits,
118
119
noPreview,
119
120
registryFacadeHandover,
121
+ gcpStorage,
120
122
} ) ) ;
121
123
122
124
/**
@@ -161,15 +163,15 @@ async function build(context, version) {
161
163
werft . phase ( "deploy" , "not deploying" ) ;
162
164
console . log ( "no-preview or publish-release is set" ) ;
163
165
} else {
164
- await deployToDev ( version , workspaceFeatureFlags , dynamicCPULimits , registryFacadeHandover ) ;
166
+ await deployToDev ( version , workspaceFeatureFlags , dynamicCPULimits , registryFacadeHandover , gcpStorage ) ;
165
167
}
166
168
}
167
169
168
170
169
171
/**
170
172
* Deploy dev
171
173
*/
172
- async function deployToDev ( version , workspaceFeatureFlags , dynamicCPULimits , registryFacadeHandover ) {
174
+ async function deployToDev ( version , workspaceFeatureFlags , dynamicCPULimits , registryFacadeHandover , gcpStorage ) {
173
175
werft . phase ( "deploy" , "deploying to dev" ) ;
174
176
const destname = version . split ( "." ) [ 0 ] ;
175
177
const namespace = `staging-${ destname } ` ;
@@ -284,6 +286,12 @@ async function deployToDev(version, workspaceFeatureFlags, dynamicCPULimits, reg
284
286
try {
285
287
shell . cd ( "chart" ) ;
286
288
werft . log ( 'helm' , 'installing Gitpod' ) ;
289
+
290
+ if ( gcpStorage ) {
291
+ flags += ` -f ../.werft/values.dev.gcp-storage.yaml`
292
+ // Here we could also add the secret 'remote-storage-gcloud' to access the GCP bucket.
293
+ // For now, one had to create the secret with `kubectl apply ...` by hand after deployment.
294
+ }
287
295
288
296
exec ( `helm dependencies up` ) ;
289
297
exec ( `/usr/local/bin/helm3 upgrade --install --timeout 10m -f ../.werft/values.dev.yaml ${ flags } gitpod .` ) ;
0 commit comments