You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Follow this workshop to deploy a sample {product-title}(ROSA) cluster. You can then use your cluster in other learning workshops.
14
+
Follow this workshop to deploy a sample {product-title}(ROSA) cluster. You can then use your cluster in the next workshops.
14
15
15
-
== Prerequisites
16
+
.Workshop objectives
16
17
17
-
Before deploying a ROSA cluster, you must have the following resources:
18
+
* Learn to create your cluster prerequisites:
19
+
** Create a sample virtual private cloud (VPC)
20
+
** Create sample OpenID Connect (OIDC) resources
21
+
* Create sample environment variables
22
+
* Deploy a sample ROSA cluster
18
23
19
-
* VPC - This is a bring-your-own VPC model, also referred to as BYO-VPC.
20
-
* OIDC - OIDC configuration and an OIDC provider with that specific configuration.
21
-
* ROSA version 1.2.31 or higher
24
+
.Prerequisites
22
25
23
-
In this tutorial, we will create these resources first. We will also set up some environment variables so that it is easier to run the command to create the {hcp-title} cluster.
26
+
* ROSA version 1.2.31 or later
27
+
* Amazon Web Service (AWS) command line interface (CLI)
28
+
* ROSA CLI (`rosa`)
29
+
30
+
== Creating your cluster prerequisites
31
+
32
+
Before deploying a ROSA cluster, you must have both a VPC and OIDC resources. We will create these resources first. ROSA uses the bring your own VPC (BYO-VPC) model.
24
33
25
34
=== Creating a VPC
26
-
. First, ensure that your AWS CLI (`aws`) is configured to use a region where {hcp-title} is available. To find out which regions are supported run the following command:
35
+
. Make sure your AWS CLI (`aws`) is configured to use a region where ROSA is available. See the regions supported by the AWS CLI by running the following command:
27
36
+
28
37
[source,terminal]
29
38
----
30
-
rosa list regions --hosted-cp
39
+
$ rosa list regions --hosted-cp
31
40
----
32
41
33
-
. Create the VPC. For this tutorial, the following link:https://github.com/openshift-cs/rosaworkshop/blob/master/rosa-workshop/rosa/resources/setup-vpc.sh[script] creates the VPC and its required components for you. It uses the region configured for the `aws` CLI.
42
+
. Create the VPC. For this workshop, the following link:https://github.com/openshift-cs/rosaworkshop/blob/master/rosa-workshop/rosa/resources/setup-vpc.sh[script] creates the VPC and its required components. It uses the region configured in your `aws` CLI.
For more about VPC requirements, see the xref:../../../rosa_planning/rosa-sts-aws-prereqs.adoc#rosa-vpc_rosa-sts-aws-prereqs[VPC documentation].
153
+
[role="_additional-resources"]
154
+
.Additional resources
155
+
* For more about VPC requirements, see the xref:../../../rosa_planning/rosa-sts-aws-prereqs.adoc#rosa-vpc_rosa-sts-aws-prereqs[VPC documentation].
145
156
146
-
. The above script outputs two commands. Set the commands as environment variables to make running the `create cluster` command easier. Copy them from the output and run them as shown:
157
+
. The script outputs commands. Set the commands as environment variables to store the subnet IDs for later use. Copy and run the commands:
147
158
+
148
159
[source,terminal]
149
160
----
150
-
export PUBLIC_SUBNET_ID=<public subnet id here>
151
-
export PRIVATE_SUBNET_ID=<private subnet id here>
161
+
$ export PUBLIC_SUBNET_ID=$PUBLIC_SUBNET_ID
162
+
$ export PRIVATE_SUBNET_ID=$PRIVATE_SUBNET_ID
152
163
----
153
164
154
-
. Confirm that the environment variables are set by running the following command:
165
+
. Confirm your environment variables by running the following command:
In this workshop, we will use the automatic mode when creating the OIDC configuration. We will also store the OIDC ID as an environment variable for later use. The command uses the ROSA CLI to create your cluster's unique OIDC configuration.
170
182
171
-
In this tutorial, we will use the automatic mode when creating the OIDC configuration. We will also store the OIDC ID as an environment variable for later use. The command uses the ROSA CLI to create your cluster's unique OIDC configuration.
172
-
173
-
* To create the OIDC configuration for this tutorial, run the following command:
183
+
* Create the OIDC configuration by running the following command:
* Run the following command to set up some environment variables so that it is easier to run the command to create the {hcp-title} cluster:
192
+
* Run the following command to set up environment variables. These variables make it easier to run the command to create a ROSA cluster:
183
193
+
184
194
[source,terminal]
185
195
----
186
-
export CLUSTER_NAME=<enter cluster name>
187
-
export REGION=<region VPC was created in>
196
+
$ export CLUSTER_NAME=<cluster_name>
197
+
$ export REGION=<VPC_region>
188
198
----
189
199
+
190
200
[TIP]
191
201
====
192
202
Run `rosa whoami` to find the VPC region.
193
203
====
194
204
195
-
== Creating the cluster
196
-
If this is the _first time_ you are deploying ROSA in this account and you have _not_ yet created the account roles, create the account-wide roles and policies, including the Operator policies. Since ROSA uses AWS Security Token Service (STS), this step creates the AWS IAM roles and policies that are needed for ROSA to interact with your account.
205
+
== Creating a cluster
197
206
198
-
. Run the following command to create the account-wide roles:
207
+
. *Optional:* Run the following command to create the account-wide roles and policies, including the Operator policies and the AWS IAM roles and policies:
208
+
+
209
+
[IMPORTANT]
210
+
====
211
+
Only complete this step if this is the _first time_ you are deploying ROSA in this account and you have _not_ yet created your account roles and policies.
212
+
====
199
213
+
200
214
[source,terminal]
201
215
----
202
-
rosa create account-roles --mode auto --yes
216
+
$ rosa create account-roles --mode auto --yes
203
217
----
204
218
205
219
. Run the following command to create the cluster:
206
220
+
207
221
[source,terminal]
208
222
----
209
-
rosa create cluster --cluster-name $CLUSTER_NAME \
The cluster is ready and completely usable after about 10 minutes. The cluster will have a control plane across three AWS availability zones in your selected region and create two worker nodes in your AWS account.
231
+
The cluster is ready after about 10 minutes. The cluster will have a control plane across three AWS availability zones in your selected region and create two worker nodes in your AWS account.
218
232
219
233
== Checking the installation status
220
234
. Run one of the following commands to check the status of the cluster:
@@ -223,21 +237,21 @@ The cluster is ready and completely usable after about 10 minutes. The cluster w
223
237
+
224
238
[source,terminal]
225
239
----
226
-
rosa describe cluster --cluster $CLUSTER_NAME
240
+
$ rosa describe cluster --cluster $CLUSTER_NAME
227
241
----
228
242
+
229
243
* For an abridged view of the cluster status, run:
230
244
+
231
245
[source,terminal]
232
246
----
233
-
rosa list clusters
247
+
$ rosa list clusters
234
248
----
235
249
+
236
250
* To watch the log as it progresses, run:
237
251
+
238
252
[source,terminal]
239
253
----
240
-
rosa logs install --cluster $CLUSTER_NAME --watch
254
+
$ rosa logs install --cluster $CLUSTER_NAME --watch
241
255
----
242
256
243
257
. Once the state changes to “ready” your cluster is installed. It might take a few more minutes for the worker nodes to come online.
0 commit comments