Bug 1695860

Summary: Remove static name parameters from the AWS CloudFormation templates
Product: OpenShift Container Platform Reporter: Kathryn Alexander <kalexand>
Component: InstallerAssignee: Stephen Cuppett <scuppett>
Installer sub component: openshift-installer QA Contact: Johnny Liu <jialiu>
Status: CLOSED ERRATA Docs Contact:
Severity: urgent    
Priority: high CC: scuppett
Version: 4.1.0   
Target Milestone: ---   
Target Release: 4.1.0   
Hardware: x86_64   
OS: Other   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-06-04 10:47:03 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Kathryn Alexander 2019-04-03 19:56:48 UTC
Description of problem: Several of the objects in the 02_cluster_infra.yaml template contain static name parameters that make it impossible to deploy another stack without modifying the template.


How reproducible:

Steps to Reproduce:
1. Deploy the infra template.
2. Deploy the infra template again to a different stack.

Actual results:
Stack deployment fails and is rolled back because the InternalServiceTargetGroup already exists:


            "StackId": "arn:aws:cloudformation:us-east-1:269733383066:stack/kalexanddns1/36628930-563a-11e9-8556-0ee7d31f28a0",
            "EventId": "InternalServiceTargetGroup-CREATE_FAILED-2019-04-03T17:59:28.072Z",
            "StackName": "kalexanddns1",
            "LogicalResourceId": "InternalServiceTargetGroup",
            "PhysicalResourceId": "",
            "ResourceType": "AWS::ElasticLoadBalancingV2::TargetGroup",
            "Timestamp": "2019-04-03T17:59:28.072Z",
            "ResourceStatus": "CREATE_FAILED",
            "ResourceStatusReason": "InternalServiceTargetGroup already exists in stack arn:aws:cloudformation:us-east-1:269733383066:stack/KatherineClusterInfra/aec15820-4a4b-11e9-afb3-0e7f598ae3ee",
            "ResourceProperties": "{\"VpcId\":\"vpc-005b5b485342f7bba\",\"Port\":\"22623\",\"TargetType\":\"ip\",\"TargetGroupAttributes\":[{\"Value\":\"60\",\"Key\":\"deregistration_delay.timeout_seconds\"}],\"Protocol\":\"TCP\",\"Name\":\"InternalServiceTargetGroup\"}"


Stephen has a fix for the template.

Comment 1 Stephen Cuppett 2019-04-03 20:12:45 UTC
https://github.com/openshift/installer/pull/1527

Comment 2 Johnny Liu 2019-04-04 08:21:07 UTC
The PR is merged, so move this bug to ON_QA.

Comment 3 Johnny Liu 2019-04-04 08:24:27 UTC
Verified this bug with latest template, and passed.

Now target group are created with some random string in their name, when I am using 'jialiuuuuu2' as cluster name, those target group would something like:
jiali-Exter-R8T1T135WFIA
jiali-Inter-1J81P3GSGHXLM
jiali-Inter-1SGXWMUVV1F0Q

Comment 5 errata-xmlrpc 2019-06-04 10:47:03 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2019:0758