elvainch
elvainch

Reputation: 1385

Google cloud build : .availableSecrets: unused

I am trying to run a step using cloud build and using secret manager but I get an error.

My cloudbuild.yaml is:

steps:
- name: 'gcr.io/myproject/image:latest'
  args:
  - '-arg1=blablabla'
  - '-mysysttem.login=$$LOGIN'
  - '-arg3=blablabla'
  - '-arg4=blabla'
  secretEnv: ['LOGIN'] 
availableSecrets:
  secretManager:
  - versionName: projects/myproject/secrets/mysecret/versions/latest
    env: 'LOGIN'

and when executing: gcloud builds submit --config cloudbuild.yaml

I get the following error

ERROR: (gcloud.builds.submit) interpreting cloudbuild.yaml as build config: .availableSecrets: unused

Couldnt find anything related to it when searching for this error

Upvotes: 0

Views: 748

Answers (1)

elvainch
elvainch

Reputation: 1385

So after I investigating more I figured I had an old gcloud cli version installed on my computer. The command to run the update is:

gcloud components update

This fixed my error

Upvotes: 1

Related Questions