:_mod-docs-content-type: ASSEMBLY
[id="rosa-shared-vpc-config"]
= Configuring a shared VPC for ROSA clusters
include::_attributes/attributes-openshift-dedicated.adoc[]
:context: rosa-shared-vpc-config

toc::[]

[role="_abstract"]
You can create {product-title} clusters in shared, centrally-managed AWS virtual private clouds (VPCs).

include::snippets/snip_install-cluster-in-vpc.adoc[]

[NOTE]
====
This process requires *two separate* AWS accounts that belong to the same AWS organization. One account functions as the VPC-owning AWS account (*VPC Owner*), while the other account creates the cluster in the cluster-creating AWS account (*Cluster Creator*).
====

image::372_OpenShift_on_AWS_persona_worflows_0923_all.png[]

== Prerequisites for the VPC Owner

* You have an AWS account with the proper permissions to create roles and share resources.
* The *Cluster Creator's* AWS account is separate from the *VPC Owner's* AWS account.
* Both AWS accounts belong to the same AWS organization.
* You enabled resource sharing from the management account for your organization.
* You have access to the link:https://signin.aws.amazon.com[AWS console].

== Prerequisites for the Cluster Creator

* You installed the link:https://console.redhat.com/openshift/downloads#tool-rosa[ROSA CLI (`rosa`)] 1.2.26 or later.
* You created all of the required
ifdef::openshift-rosa[]
xref:../rosa_install_access_delete_clusters/rosa-sts-creating-a-cluster-quickly.adoc#rosa-sts-creating-account-wide-sts-roles-and-policies_rosa-sts-creating-a-cluster-quickly[account-wide roles and policies]
endif::openshift-rosa[]
ifdef::openshift-rosa-hcp[]
* xref:../rosa_hcp/rosa-hcp-sts-creating-a-cluster-quickly.adoc#rosa-sts-creating-account-wide-sts-roles-and-policies_rosa-hcp-sts-creating-a-cluster-quickly[account-wide roles and policies]
endif::openshift-rosa-hcp[]
for creating a cluster.
* You have created your `ocm-role` resource.
* The *Cluster Creator's* AWS account is separate from the *VPC Owner's* AWS account.
* Both AWS accounts belong to the same AWS organization.

[NOTE]
====
Installing a cluster in a shared VPC is supported only for OpenShift 4.12.34 and later, 4.13.10 and later, and all future 4.y-streams.
====

include::modules/rosa-sharing-vpc-creation-and-sharing.adoc[leveloffset=+1]

[role="_additional-resources"]
[id="additional-resources_shared-vpc_vpc-creation"]
== Additional resources
* link:https://docs.aws.amazon.com/vpc/latest/userguide/vpc-sharing.html[AWS documentation on sharing your AWS resources]

include::modules/rosa-sharing-vpc-dns-and-roles.adoc[leveloffset=+1]
include::modules/rosa-sharing-vpc-hosted-zones.adoc[leveloffset=+1]
include::modules/rosa-sharing-vpc-cluster-creation.adoc[leveloffset=+1]