gcloud beta projects move some-project-id --organi

2019-07-12 17:56发布

问题:

We created a project in the Google Cloud Console and it added it to an organization. We need to move this project to another organization where our other projects are.

We are trying to move it with this gcloud command but we get an error.

$ gcloud beta projects move some-project-id --organization=0

ERROR: (gcloud.beta.projects.move) INVALID_ARGUMENT: field [Project.parent] has issue [Project parent cannot be empty.] - '@type': type.googleapis.com/google.rpc.BadRequest fieldViolations: - description: Project parent cannot be empty. field: Project.parent

https://cloud.google.com/sdk/gcloud/reference/beta/projects/move

回答1:

From the docs for the move command:

This command can fail for the following reasons: -... - the given project is already in an organization.

Indeed, from the migration docs:

Project migration isn't reversible. After a project is associated with an organization, you can't change it back to "no organization" or move it to another organization on your own. To change the organization a project is associated with, you'll need to be a G Suite or Cloud Premium customer with a support package.