File tree Expand file tree Collapse file tree 2 files changed +30
-14
lines changed
ci-operator/templates/openshift/installer Expand file tree Collapse file tree 2 files changed +30
-14
lines changed Original file line number Diff line number Diff line change @@ -347,8 +347,6 @@ objects:
347
347
env :
348
348
- name : AWS_SHARED_CREDENTIALS_FILE
349
349
value : /etc/openshift-installer/.awscred
350
- - name : AWS_REGION
351
- value : us-east-1
352
350
- name : AZURE_AUTH_LOCATION
353
351
value : /etc/openshift-installer/osServicePrincipal.json
354
352
- name : GCP_REGION
@@ -442,6 +440,16 @@ objects:
442
440
elif has_variant "large"; then
443
441
master_type=m5.4xlarge
444
442
fi
443
+ case $((RANDOM % 4)) in
444
+ 0) AWS_REGION=us-east-1
445
+ ZONE_1=us-east-1b
446
+ ZONE_2=us-east-1c;;
447
+ 1) AWS_REGION=us-east-2;;
448
+ 2) AWS_REGION=us-west-1;;
449
+ 3) AWS_REGION=us-west-2;;
450
+ *) echo >&2 "invalid AWS region index"; exit 1;;
451
+ esac
452
+ echo "AWS region: ${AWS_REGION} (zones: ${ZONE_1:-${AWS_REGION}a} ${ZONE_2:-${AWS_REGION}b})"
445
453
subnets="[]"
446
454
if has_variant "shared-vpc"; then
447
455
case $((RANDOM % 4)) in
@@ -465,20 +473,20 @@ objects:
465
473
aws:
466
474
type: ${master_type}
467
475
zones:
468
- - us-east-1a
469
- - us-east-1b
476
+ - ${ZONE_1:-${AWS_REGION}a}
477
+ - ${ZONE_2:-${AWS_REGION}b}
470
478
compute:
471
479
- name: worker
472
480
replicas: ${workers}
473
481
platform:
474
482
aws:
475
483
type: m4.xlarge
476
484
zones:
477
- - us-east-1a
478
- - us-east-1b
485
+ - ${ZONE_1:-${AWS_REGION}a}
486
+ - ${ZONE_2:-${AWS_REGION}b}
479
487
platform:
480
488
aws:
481
- region: ${AWS_REGION}
489
+ region: ${AWS_REGION}
482
490
userTags:
483
491
expirationDate: ${EXPIRATION_DATE}
484
492
subnets: ${subnets}
Original file line number Diff line number Diff line change @@ -205,8 +205,6 @@ objects:
205
205
env :
206
206
- name : AWS_SHARED_CREDENTIALS_FILE
207
207
value : /etc/openshift-installer/.awscred
208
- - name : AWS_REGION
209
- value : us-east-1
210
208
- name : AZURE_AUTH_LOCATION
211
209
value : /etc/openshift-installer/osServicePrincipal.json
212
210
- name : GCP_REGION
@@ -292,6 +290,16 @@ objects:
292
290
elif [[ "${CLUSTER_VARIANT}" =~ "large" ]]; then
293
291
master_type=m5.4xlarge
294
292
fi
293
+ case $((RANDOM % 4)) in
294
+ 0) AWS_REGION=us-east-1
295
+ ZONE_1=us-east-1b
296
+ ZONE_2=us-east-1c;;
297
+ 1) AWS_REGION=us-east-2;;
298
+ 2) AWS_REGION=us-west-1;;
299
+ 3) AWS_REGION=us-west-2;;
300
+ *) echo >&2 "invalid AWS region index"; exit 1;;
301
+ esac
302
+ echo "AWS region: ${AWS_REGION} (zones: ${ZONE_1:-${AWS_REGION}a} ${ZONE_2:-${AWS_REGION}b})"
295
303
subnets="[]"
296
304
if [[ "${CLUSTER_VARIANT}" =~ "shared-vpc" ]]; then
297
305
case $((RANDOM % 4)) in
@@ -315,20 +323,20 @@ objects:
315
323
aws:
316
324
type: ${master_type}
317
325
zones:
318
- - us-east-1a
319
- - us-east-1b
326
+ - ${ZONE_1:-${AWS_REGION}a}
327
+ - ${ZONE_2:-${AWS_REGION}b}
320
328
compute:
321
329
- name: worker
322
330
replicas: ${workers}
323
331
platform:
324
332
aws:
325
333
type: m4.xlarge
326
334
zones:
327
- - us-east-1a
328
- - us-east-1b
335
+ - ${ZONE_1:-${AWS_REGION}a}
336
+ - ${ZONE_2:-${AWS_REGION}b}
329
337
platform:
330
338
aws:
331
- region: ${AWS_REGION}
339
+ region: ${AWS_REGION}
332
340
userTags:
333
341
expirationDate: ${EXPIRATION_DATE}
334
342
subnets: ${subnets}
You can’t perform that action at this time.
0 commit comments