File tree Expand file tree Collapse file tree 3 files changed +5
-5
lines changed Expand file tree Collapse file tree 3 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -341,5 +341,5 @@ ENV PRE_COMMIT_HOME=/workspace/.pre-commit
341341
342342# Setting the environment variable here so that it will be accessible to all tasks and
343343# terminal sessions in Gitpod workspaces.
344- ENV PREVIEW_ENV_DEV_SA_KEY_PATH=
344+ ENV PREVIEW_ENV_DEV_SA_KEY_PATH=/root/.config/gcloud/sa.json
345345ENV GOOGLE_EXTERNAL_ACCOUNT_ALLOW_EXECUTABLES=1
Original file line number Diff line number Diff line change @@ -8,15 +8,15 @@ const getIDToken = async () => {
88 const config = JSON . parse ( fs . readFileSync ( configPath , "utf8" ) ) ;
99
1010 const controlPlaneApiEndpoint = config . controlPlaneApiEndpoint ;
11- const workspaceToken = config . workspaceToken ;
11+ const environmentToken = config . environmentToken ;
1212
1313 const url = new URL ( controlPlaneApiEndpoint ) ;
1414 const client = http2 . connect ( url . origin ) ;
1515
1616 const req = client . request ( {
1717 ":method" : "POST" ,
1818 "content-type" : "application/json" ,
19- authorization : `Bearer ${ workspaceToken } ` ,
19+ authorization : `Bearer ${ environmentToken } ` ,
2020 ":path" : `${ url . pathname } /gitpod.v1.IdentityService/GetIDToken` ,
2121 } ) ;
2222
Original file line number Diff line number Diff line change 2020
2121if [ -f " /usr/local/gitpod/config/initial-spec.json" ]; then
2222 gcloud iam workload-identity-pools create-cred-config \
23- projects/184212049955/locations/global/workloadIdentityPools/gitpod-next /providers/gitpod-next -provider \
23+ projects/184212049955/locations/global/workloadIdentityPools/gitpod-flex /providers/gitpod-flex -provider \
2424 --service-account=preview-environmnet-dev@gitpod-dev-preview.iam.gserviceaccount.com \
2525 --service-account-token-lifetime-seconds=1h \
2626 --output-file=" ${PREVIEW_ENV_DEV_SA_KEY_PATH} " \
27- --executable-command=' node /workspace/gitpod/dev/next -oidc/oidc.js' \
27+ --executable-command=' node /workspace/gitpod/dev/flex -oidc/oidc.js' \
2828 --executable-timeout-millis=5000
2929elif [[ -n " ${PREVIEW_ENV_DEV_CRED:- } " ]]; then
3030 echo " ${PREVIEW_ENV_DEV_CRED} " > " ${PREVIEW_ENV_DEV_SA_KEY_PATH} "
You can’t perform that action at this time.
0 commit comments