Expand description
Enables the Google Compute Engine Shared VPC feature for a project, assigning it as a Shared VPC service project associated with a given host project.
For more information, see, the Project API documentation, where the Shared VPC feature is referred to by its former name “XPN”.
Note: If Shared VPC Admin role is set at the folder level, use the google-beta provider. The google provider only supports this permission at project or organizational level currently. [0]
§Example Usage
use pulumi_wasm_rust::Output;
use pulumi_wasm_rust::{add_export, pulumi_main};
#[pulumi_main]
fn test_main() -> Result<(), Error> {
let service1 = shared_vpc_service_project::create(
"service1",
SharedVpcServiceProjectArgs::builder()
.host_project("host-project-id")
.service_project("service-project-id-1")
.build_struct(),
);
}
For a complete Shared VPC example with both host and service projects, see
gcp.compute.SharedVPCHostProject
.
§Import
Google Compute Engine Shared VPC service project feature can be imported using the host_project
and service_project
, e.g.
{{host_project}/{{service_project}}
When using the pulumi import
command, Google Compute Engine Shared VPC service project can be imported using one of the formats above. For example:
$ pulumi import gcp:compute/sharedVPCServiceProject:SharedVPCServiceProject default {{host_project}/{{service_project}}
Structs§
- Use builder syntax to set the inputs and finish with
build_struct()
.
Functions§
- Registers a new resource with the given unique name and arguments