Paradiesvogel7
Paradiesvogel7

Reputation: 1

Can't push container image into google cloud registry

I created a Project in the Google-Cloud-Console and created a container registry. Unfortunately i get this error message when pushing:

denied: Token exchange failed for project 'myProject'. Caller does not have permission 'storage.buckets.get'. 
To configure permissions, follow instructions at: https://cloud.google.com/container-registry/docs/access-control

The user i use is the owner of the project and also has the role storage admin in the IAM. I tried the same with a service account but got the same error.

Upvotes: -1

Views: 96

Answers (1)

shady ahemd
shady ahemd

Reputation: 13

I don't know what project is it I assume it's node.js ???

I tried many ways but the one worked for me is uploading project on private repo on github with a DockerFile

FROM  node:18.15.0

WORKDIR /server
EXPOSE 3000
COPY . .

RUN npm install --omit=dev

CMD ["npm", "run", "start"]

and just use github option , authenticate, check docker, after that gc should create your container. you should see google build for any errors edit: assuming u want to use cloud run. XD

Upvotes: 0

Related Questions