From 2e5d819ceda27b60eeaaa44afee51397636581c2 Mon Sep 17 00:00:00 2001 From: Rajalakshmi Ramasubramanian Date: Fri, 10 Jul 2020 07:40:33 +0000 Subject: [PATCH 1/2] Update Ingress gateway walkthrough to use appmesh prod cli --- walkthroughs/howto-ingress-gateway/README.md | 9 +-------- .../infrastructure/ecs-service.yaml | 12 +----------- walkthroughs/howto-ingress-gateway/mesh/mesh.sh | 4 ++-- 3 files changed, 4 insertions(+), 21 deletions(-) diff --git a/walkthroughs/howto-ingress-gateway/README.md b/walkthroughs/howto-ingress-gateway/README.md index 52bbab65..5d5b4a73 100644 --- a/walkthroughs/howto-ingress-gateway/README.md +++ b/walkthroughs/howto-ingress-gateway/README.md @@ -89,14 +89,7 @@ Internet --> (terminate TLS) NLB (originate TLS) --> (terminate TLS) Gateway (or ## Step 1: Prerequisites -You will need the latest version of the App Mesh Preview CLI for this walkthrough. You can download and use the latest version using the command below. - -```bash -aws configure add-model \ - --service-name appmesh-preview \ - --service-model https://raw.githubusercontent.com/aws/aws-app-mesh-roadmap/master/appmesh-preview/service-model.json -``` -You'll also need a keypair stored in AWS to access a bastion host. You can create a keypair using the command below if you don't have one. See [Amazon EC2 Key Pairs](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-key-pairs.html). +You'll need a keypair stored in AWS to access a bastion host. You can create a keypair using the command below if you don't have one. See [Amazon EC2 Key Pairs](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-key-pairs.html). ```bash aws ec2 create-key-pair --key-name color-app | jq -r .KeyMaterial > ~/.ssh/color-app.pem diff --git a/walkthroughs/howto-ingress-gateway/infrastructure/ecs-service.yaml b/walkthroughs/howto-ingress-gateway/infrastructure/ecs-service.yaml index ae8e13ec..40e1fb6a 100644 --- a/walkthroughs/howto-ingress-gateway/infrastructure/ecs-service.yaml +++ b/walkthroughs/howto-ingress-gateway/infrastructure/ecs-service.yaml @@ -128,8 +128,6 @@ Resources: Environment: - Name: 'APPMESH_VIRTUAL_NODE_NAME' Value: !Sub 'mesh/${AppMeshMeshName}/virtualNode/colorteller-white-vn' - - Name: 'APPMESH_PREVIEW' - Value: '1' ColorTellerWhiteService: Type: 'AWS::ECS::Service' @@ -249,8 +247,6 @@ Resources: Environment: - Name: 'APPMESH_VIRTUAL_NODE_NAME' Value: !Sub 'mesh/${AppMeshMeshName}/virtualNode/colorteller-black-vn' - - Name: 'APPMESH_PREVIEW' - Value: '1' ColorTellerBlackService: Type: 'AWS::ECS::Service' @@ -370,8 +366,6 @@ Resources: Environment: - Name: 'APPMESH_VIRTUAL_NODE_NAME' Value: !Sub 'mesh/${AppMeshMeshName}/virtualNode/colorteller-blue-vn' - - Name: 'APPMESH_PREVIEW' - Value: '1' ColorTellerBlueService: Type: 'AWS::ECS::Service' @@ -491,8 +485,6 @@ Resources: Environment: - Name: 'APPMESH_VIRTUAL_NODE_NAME' Value: !Sub 'mesh/${AppMeshMeshName}/virtualNode/colorteller-red-vn' - - Name: 'APPMESH_PREVIEW' - Value: '1' ColorTellerRedService: Type: 'AWS::ECS::Service' @@ -561,7 +553,7 @@ Resources: Command: - 'CMD-SHELL' - 'curl -s http://localhost:9901/server_info | grep state | grep -q LIVE' - Interval: 5 + Interval: 30 Timeout: 2 Retries: 3 LogConfiguration: @@ -574,8 +566,6 @@ Resources: Environment: - Name: 'APPMESH_VIRTUAL_NODE_NAME' Value: !Sub 'mesh/${AppMeshMeshName}/virtualGateway/colorgateway-vg' - - Name: 'APPMESH_PREVIEW' - Value: '1' - Name: 'ENABLE_ENVOY_STATS_TAGS' Value: '1' - Name: 'ENABLE_ENVOY_DOG_STATSD' diff --git a/walkthroughs/howto-ingress-gateway/mesh/mesh.sh b/walkthroughs/howto-ingress-gateway/mesh/mesh.sh index ff1db529..43a5491f 100755 --- a/walkthroughs/howto-ingress-gateway/mesh/mesh.sh +++ b/walkthroughs/howto-ingress-gateway/mesh/mesh.sh @@ -22,7 +22,7 @@ sanity_check() { fi } -appmesh_cmd="aws appmesh-preview" +appmesh_cmd="aws appmesh" create_mesh() { spec_file=$1 @@ -302,4 +302,4 @@ main() { esac } -main $@ \ No newline at end of file +main $@ From 08e2500b360d57083563eb7669eaa3f1db8b4541 Mon Sep 17 00:00:00 2001 From: Rajalakshmi Ramasubramanian Date: Mon, 13 Jul 2020 22:56:50 +0000 Subject: [PATCH 2/2] Setting Healthcheck StartPeriod as 60s --- .../howto-ingress-gateway/infrastructure/ecs-service.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/walkthroughs/howto-ingress-gateway/infrastructure/ecs-service.yaml b/walkthroughs/howto-ingress-gateway/infrastructure/ecs-service.yaml index 40e1fb6a..d7e8f998 100644 --- a/walkthroughs/howto-ingress-gateway/infrastructure/ecs-service.yaml +++ b/walkthroughs/howto-ingress-gateway/infrastructure/ecs-service.yaml @@ -553,9 +553,10 @@ Resources: Command: - 'CMD-SHELL' - 'curl -s http://localhost:9901/server_info | grep state | grep -q LIVE' - Interval: 30 + Interval: 5 Timeout: 2 Retries: 3 + StartPeriod: 60 LogConfiguration: LogDriver: 'awslogs' Options: