Reputation: 3167
When I run gcloud services enable service:container.googleapis.com
, I get the following error:
ERROR: (gcloud.services.enable) PERMISSION_DENIED: Not found or permission denied for service(s): service:container.googleapis.com.
- '@type': type.googleapis.com/google.rpc.PreconditionFailure
violations:
- subject: ?error_code=220002&services=service:container.googleapis.com
type: googleapis.com
- '@type': type.googleapis.com/google.rpc.ErrorInfo
domain: serviceusage.googleapis.com
metadata:
services: service:container.googleapis.com
reason: SERVICE_CONFIG_NOT_FOUND_OR_PERMISSION_DENIED
What permission am I missing that's causing this error?
Upvotes: 6
Views: 15217
Reputation: 1
Based on the two responses above to omit 'service' and to end at 'container' (without adding .googleapis.com
) I made variations of the command. This one worked: gcloud services enable serviceusage.googleapis.com
.
C:\NewApp\CourierApp>gcloud services enable serviceusage.googleapis.com
Operation "operations/acat.p2-####72866531-5309f688-fea1-446d-&&&&-f545c9a5e1f6"
finished successfully. Of course I had made various API 'Roles', 'Admin management' modifications on the google.console to no avail. Perhaps this passed after one of those server updates.
Other prompts I tried:
gcloud services enable maps.googleapis.com
gcloud services enable:container
gcloud services enable:container.googleapis.com
Upvotes: -1
Reputation: 1
I used below and it worked. I just used CONTAINER as service name rather than using container.googleapis.com
gcloud services enable container
Operation "operations/acf.p2-768261041254-0cc69e23-b9e8-449f" finished successfully.
Upvotes: 0
Reputation: 3766
According to this document, it should be like this :
gcloud services enable [SERVICE_NAME]
or
gcloud services enable container.googleapis.com
You can also see the list of available services for a project, run:
gcloud services list --available
and To list the services the current project has enabled, run:
gcloud services list --enabled
Upvotes: 1