data_henrik
data_henrik

Reputation: 17118

IBM Cloud: Error trying to create Code Engine project

I am trying to create a new IBM Cloud Code Engine project on the command line, but am running into errors.

$ ibmcloud coligo proj create -n HLTest

Creating project 'HLTest'...
FAILED
Cannot target project HLTest

Listing my projects with ibmcloud coligo proj list succeeds.

Upvotes: 0

Views: 481

Answers (2)

data_henrik
data_henrik

Reputation: 17118

After tracing the command using IBMCLOUD_TRACE=true I found an error indicating that my currently set cloud region is not enabled. Setting ibmcloud target -r us-south and then executing the above ibmcloud coligo proj create -n HLTest succeeded.

Lessons learned: Listing projects is global, creating a project only works when a supported cloud region has been targeted before.

From @vidya's answer: Also set the resource group using ibmcloud target -g RG with RG being the resource group. Each account has a default resource group.

Upvotes: 2

Vidyasagar Machupalli
Vidyasagar Machupalli

Reputation: 2865

Another best practice is to set the resource group before creating a Code Engine project with the command below

ibmcloud target -g Default

Default is the default resource group automatically created when you create an IBM Cloud account

Upvotes: 1

Related Questions