Problem
In the service project, you are unable to access a newly added subnet from a Virtual Private Cloud of the host project.
Environment
- Shared Virtual Private Cloud
- Subnets of the host project that were previously shared with service projects.
Solution
You must share a new subnet by performing the steps listed below:
- Open the host project and go to Shared Virtual Private Cloud.
- Check if subnet-level permissions are enabled. Under Individual subnet permissions (subnet-level permissions) find a subnet that is already shared with the service project.
- Click the X users value under the Shared with column. Copy the service account addresses that belong to your service project.
- Open a new window and under Individual subnet permissions (subnet-level permissions) find the subnet you want to share.
- Click the X users value under the Shared with column. Give Compute Network User permissions to service account addresses found at Step 3.
Cause
A shared Virtual Private Cloud Admin can either share all current and future subnets in Virtual Private Cloud networks of the host project or choose to selectively share subnets from Virtual Private Cloud networks of the host project with service projects and service Project Admins.