├── .github
├── ISSUE_TEMPLATE
│ └── bug_report.md
└── PULL_REQUEST_TEMPLATE.md
├── .gitignore
├── CODEOWNERS
├── CODE_OF_CONDUCT.md
├── CONTRIBUTING.md
├── FAQ.md
├── LICENSE
├── NOTICE
├── README.md
├── blogs
├── cert-manager-tls
│ ├── README.md
│ ├── ca-issuer.yaml
│ ├── yelb-base.yaml
│ ├── yelb-cert.yaml
│ ├── yelb-deployment-secretMounts.yaml
│ ├── yelb-gw.yaml
│ └── yelb-virtualnode-tls.yaml
├── ecs-canary-deployments-pipeline
│ ├── Makefile
│ ├── README.md
│ ├── pipeline_stack
│ │ └── pipeline_cloudformation.yml
│ ├── requirements.txt
│ ├── setup
│ │ ├── scripts
│ │ │ ├── create_ecs_mesh.sh
│ │ │ ├── create_prometheus_env.sh
│ │ │ ├── create_sample_microservice_pipeline_stack.sh
│ │ │ ├── create_shared_cloudformation_stack.sh
│ │ │ ├── create_vpc.sh
│ │ │ ├── delete_blog_contents.py
│ │ │ └── export_environment_variables.sh
│ │ └── templates
│ │ │ ├── create-prometheus-env.yaml
│ │ │ ├── ecs-mesh.yaml
│ │ │ └── vpc.yaml
│ └── shared_stack
│ │ ├── lambda_functions
│ │ ├── check_deployment_version
│ │ │ └── main.py
│ │ ├── deploy_canary_infrastructure
│ │ │ └── main.py
│ │ ├── gather_healthcheck_status
│ │ │ └── main.py
│ │ ├── remove_previous_canary_components
│ │ │ └── main.py
│ │ ├── rollbackto_previous_canary
│ │ │ └── main.py
│ │ ├── start_canary
│ │ │ └── main.py
│ │ └── update_deployment_version
│ │ │ └── main.py
│ │ ├── state_machine_definition.yml
│ │ └── stepfunctions_cloudformation.yml
├── ecs-cross-account
│ ├── account_backend
│ │ ├── appmesh_resources.yml
│ │ ├── infra.yml
│ │ ├── redis_and_database.yml
│ │ └── share_resources.yml
│ ├── account_frontend
│ │ ├── app_and_frontend.yml
│ │ ├── appmesh_resources.yml
│ │ └── infra.yml
│ └── cleanup.sh
├── ecs-ec2-crossvpc-with-tls
│ ├── acm.yml
│ ├── appmesh-baseline.yml
│ ├── appmesh-nodejs.yml
│ ├── cleanup.sh
│ ├── frontend-envoy.sh
│ └── mesh.yml
├── ecs-service-connectivity
│ ├── README.md
│ └── yelb
│ │ ├── deployments
│ │ └── platformdeployment
│ │ │ └── AWS
│ │ │ └── ECS
│ │ │ ├── deploy_db.sh
│ │ │ ├── deploy_yelb.sh
│ │ │ ├── mesh
│ │ │ ├── delete-mesh-components.sh
│ │ │ ├── yelb-app-gateway-route.json
│ │ │ ├── yelb-app-vn.json
│ │ │ ├── yelb-app-vs.json
│ │ │ ├── yelb-appmesh-appserver.sh
│ │ │ ├── yelb-appmesh-db.sh
│ │ │ ├── yelb-appmesh-gateway.sh
│ │ │ ├── yelb-appmesh-recipe.sh
│ │ │ ├── yelb-appmesh-redis.sh
│ │ │ ├── yelb-appmesh-ui.sh
│ │ │ ├── yelb-db-vn.json
│ │ │ ├── yelb-db-vs.json
│ │ │ ├── yelb-recipe-vn.json
│ │ │ ├── yelb-recipe-vs.json
│ │ │ ├── yelb-redis-vn.json
│ │ │ ├── yelb-redis-vs.json
│ │ │ ├── yelb-ui-gateway-route.json
│ │ │ ├── yelb-ui-vn.json
│ │ │ ├── yelb-ui-vs.json
│ │ │ └── yelb-vg.json
│ │ │ ├── sample.settings
│ │ │ ├── startup.sh
│ │ │ └── yelb-cloudformation-ECS-AppMesh-deployment.yaml
│ │ ├── yelb-appserver
│ │ ├── Dockerfile
│ │ ├── Gemfile
│ │ ├── README.md
│ │ ├── getrecipe_adapter.rb
│ │ ├── getstats_adapter.rb
│ │ ├── getvotes_adapter.rb
│ │ ├── hostname_adapter.rb
│ │ ├── modules
│ │ │ ├── getrecipe.rb
│ │ │ ├── getrecipe_dontchange.rb
│ │ │ ├── getstats.rb
│ │ │ ├── getvotes.rb
│ │ │ ├── hostname.rb
│ │ │ ├── pageviews.rb
│ │ │ ├── restaurant.rb
│ │ │ ├── restaurantsdbread.rb
│ │ │ └── restaurantsdbupdate.rb
│ │ ├── pageviews_adapter.rb
│ │ ├── restaurant_adapter.rb
│ │ ├── startup.sh
│ │ ├── yelb-appserve_dontchanger.rb
│ │ └── yelb-appserver.rb
│ │ └── yelb-ui
│ │ ├── Dockerfile
│ │ ├── README.md
│ │ ├── clarity-seed-newfiles
│ │ ├── angular-cli.json
│ │ ├── package.json
│ │ └── src
│ │ │ ├── app
│ │ │ ├── app.component.html
│ │ │ ├── app.component.scss
│ │ │ ├── app.component.spec.ts
│ │ │ ├── app.component.ts
│ │ │ ├── app.module.ts
│ │ │ ├── app.routing.ts
│ │ │ ├── env.service.provider.ts
│ │ │ ├── env.service.spec.ts
│ │ │ └── env.service.ts
│ │ │ ├── env.js
│ │ │ ├── environments
│ │ │ ├── environment.custom.ts
│ │ │ ├── environment.prod.ts
│ │ │ ├── environment.test.ts
│ │ │ └── environment.ts
│ │ │ ├── index.html
│ │ │ └── styles.css
│ │ └── startup.sh
├── eks-appmesh-connectivity
│ ├── deployments
│ │ ├── infrastructure
│ │ │ ├── cleanup.sh
│ │ │ ├── setup-elasticache.sh
│ │ │ └── setup-rds.sh
│ │ └── yaml
│ │ │ ├── README.md
│ │ │ ├── mesh
│ │ │ └── appmesh
│ │ │ │ ├── yelb-appserver-mesh.yaml
│ │ │ │ ├── yelb-cache-mesh.yaml
│ │ │ │ ├── yelb-db-mesh.yaml
│ │ │ │ ├── yelb-es-mesh.yaml
│ │ │ │ ├── yelb-gateway.yaml
│ │ │ │ ├── yelb-rds-mesh.yaml
│ │ │ │ ├── yelb-recipepuppy-mesh.yaml
│ │ │ │ └── yelb-ui-mesh.yaml
│ │ │ └── yelb-k8s-loadbalancer.yaml
│ └── images
│ │ └── yelb-eks-load-balancer.png
├── eks-bulkhead-pattern-circuit-breaker
│ ├── .gitignore
│ ├── README.md
│ ├── cleanup.sh
│ ├── deploy.sh
│ ├── manifests
│ │ ├── base.template.yaml
│ │ └── update.template.yaml
│ ├── price-app
│ │ ├── .gitignore
│ │ ├── Dockerfile
│ │ ├── go.mod
│ │ ├── go.sum
│ │ └── main.go
│ └── update.sh
├── eks-canary-deployments-pipeline
│ ├── .gitignore
│ ├── cleanup
│ │ └── cleanup_env.sh
│ ├── microservices
│ │ ├── redis-server
│ │ │ ├── Dockerfile
│ │ │ └── specfiles
│ │ │ │ ├── build.yml
│ │ │ │ ├── deploy.json
│ │ │ │ └── kubernetes_template.yml
│ │ ├── yelb-appserver
│ │ │ └── specfiles
│ │ │ │ ├── build.yml
│ │ │ │ ├── deploy.json
│ │ │ │ └── kubernetes_template.yml
│ │ ├── yelb-db
│ │ │ └── specfiles
│ │ │ │ ├── build.yml
│ │ │ │ ├── deploy.json
│ │ │ │ └── kubernetes_template.yml
│ │ └── yelb-ui
│ │ │ └── specfiles
│ │ │ ├── build.yml
│ │ │ ├── deploy.json
│ │ │ └── kubernetes_template.yml
│ ├── pipeline_stack
│ │ └── pipeline_cloudformation.yml
│ ├── setup
│ │ ├── add_iam_role_to_rbac.sh
│ │ ├── aws_lambda_layer.sh
│ │ ├── create_eks_cluster.sh
│ │ ├── create_microservice_pipeline_stack.sh
│ │ ├── create_shared_cloudformation_stack.sh
│ │ ├── export_environment_variables.sh
│ │ ├── install_appmesh_controller.sh
│ │ ├── install_cloudwatch_container_insights.sh
│ │ ├── install_dependencies.sh
│ │ └── namespace_and_mesh.yml
│ └── shared_stack
│ │ ├── lambda_functions
│ │ ├── check_deployment_version
│ │ │ └── main.py
│ │ ├── deploy_and_switch_traffic
│ │ │ ├── bootstrap
│ │ │ └── main.sh
│ │ ├── gather_healthcheck_status
│ │ │ └── main.py
│ │ ├── rollback_or_finish_upgrade
│ │ │ ├── bootstrap
│ │ │ └── main.sh
│ │ └── update_deployment_version
│ │ │ └── main.py
│ │ ├── state_machine_definition.yml
│ │ └── stepfuntions_cloudformation.yml
├── eks-multi-account-spire
│ ├── .gitignore
│ ├── Dockerfile
│ ├── LICENSE
│ ├── README.md
│ ├── appmesh-spire-agent
│ │ ├── Chart.yaml
│ │ ├── README.md
│ │ ├── templates
│ │ │ ├── NOTES.txt
│ │ │ ├── _helpers.tpl
│ │ │ ├── account.yaml
│ │ │ ├── deployment.yaml
│ │ │ ├── rbac.yaml
│ │ │ └── spire-agent-cfg.yaml
│ │ └── values.yaml
│ ├── appmesh-spire-server
│ │ ├── Chart.yaml
│ │ ├── README.md
│ │ ├── templates
│ │ │ ├── NOTES.txt
│ │ │ ├── _helpers.tpl
│ │ │ ├── account.yaml
│ │ │ ├── deployment.yaml
│ │ │ ├── rbac.yaml
│ │ │ ├── service.yaml
│ │ │ ├── spire-bundle-cfg.yaml
│ │ │ └── spire-server-cfg.yaml
│ │ └── values.yaml
│ ├── cf-templates
│ │ ├── backend-template.json
│ │ ├── frontend-template.json
│ │ └── shared-services-template.json
│ ├── helper-scripts
│ │ ├── app_mesh_setup.sh
│ │ ├── cleanup.sh
│ │ ├── ebs_for_spire_server.sh
│ │ ├── kubeconfig.sh
│ │ ├── register_server_entries.sh
│ │ └── replace_vs_arn.sh
│ ├── images
│ │ ├── multi-account-mtls-arch.png
│ │ └── yelb-ui.png
│ ├── mesh
│ │ ├── yelb-appserver.yaml
│ │ ├── yelb-db.yaml
│ │ ├── yelb-redis.yaml
│ │ └── yelb-ui.yaml
│ └── yelb
│ │ ├── resources_backend.yaml
│ │ └── resources_frontend.yaml
├── envoy-cw-dashboards
│ ├── README.md
│ ├── cw-dashboard.yaml.template
│ └── deploy-dash.sh
├── http-headers-and-priority
│ ├── README.md
│ ├── appmeshview.jpg
│ └── colorappservicesview.jpg
└── http-retry-policy
│ ├── README.md
│ ├── appmeshview.jpeg
│ ├── colorappserviceview.jpeg
│ └── retries.png
├── examples
├── README.md
├── apps
│ ├── colorapp
│ │ ├── README.md
│ │ ├── ecs
│ │ │ ├── colorgateway-base-task-def.json
│ │ │ ├── colorteller-base-task-def.json
│ │ │ ├── create-task-defs.sh
│ │ │ ├── ecs-colorapp.sh
│ │ │ ├── ecs-colorapp.yaml
│ │ │ ├── envoy-container.json
│ │ │ └── xray-container.json
│ │ ├── img
│ │ │ ├── appmesh-color-app-demo-1.png
│ │ │ ├── appmesh-color-app-demo-2.png
│ │ │ ├── appmesh-color-app-demo-3.png
│ │ │ ├── appmesh-color-app-detail.png
│ │ │ ├── appmesh-colorteller-route-1.png
│ │ │ ├── appmesh-colorteller-route-2.png
│ │ │ ├── appmesh-colorteller-route-3.png
│ │ │ ├── appmesh-colorteller-route-4.png
│ │ │ ├── appmesh-console-cloudformation-demo-stacks.png
│ │ │ ├── appmesh-weighted-routes.png
│ │ │ ├── appmesh-xray-create-group-1.png
│ │ │ ├── appmesh-xray-create-group-2.png
│ │ │ ├── appmesh-xray-service-map-1.png
│ │ │ ├── appmesh-xray-service-map-2.png
│ │ │ ├── appmesh-xray-tracing-1.png
│ │ │ └── appmesh-xray-tracing-2.png
│ │ ├── kubernetes
│ │ │ ├── .gitignore
│ │ │ └── generate-templates.sh
│ │ ├── servicemesh
│ │ │ ├── .region-config.sh
│ │ │ ├── appmesh-colorapp.sh
│ │ │ ├── appmesh-colorapp.yaml
│ │ │ ├── config
│ │ │ │ └── update_routes
│ │ │ │ │ ├── colorteller-route-black-100.json
│ │ │ │ │ ├── colorteller-route-black-80-blue-20.json
│ │ │ │ │ ├── colorteller-route-blue-100.json
│ │ │ │ │ ├── colorteller-route-blue-80-red-20.json
│ │ │ │ │ └── colorteller-route-red-100.json
│ │ │ └── route_canary.sh
│ │ └── src
│ │ │ ├── colorteller
│ │ │ ├── .gitignore
│ │ │ ├── Dockerfile
│ │ │ ├── deploy.sh
│ │ │ ├── go.mod
│ │ │ ├── go.sum
│ │ │ └── main.go
│ │ │ └── gateway
│ │ │ ├── .gitignore
│ │ │ ├── Dockerfile
│ │ │ ├── deploy.sh
│ │ │ ├── go.mod
│ │ │ ├── go.sum
│ │ │ └── main.go
│ ├── djapp
│ │ ├── 1_base_application
│ │ │ └── base_app.yaml
│ │ ├── 2_meshed_application
│ │ │ └── meshed_app.yaml
│ │ ├── 3_canary_new_version
│ │ │ └── v2_app.yaml
│ │ ├── README.md
│ │ ├── img
│ │ │ ├── 125-v1-no-mesh.png
│ │ │ └── 155-v2-with-mesh-and-cp.png
│ │ └── legacy
│ │ │ ├── 1_create_the_initial_architecture
│ │ │ ├── 1_initial_architecture_deployment.yaml
│ │ │ ├── 1_initial_architecture_services.yaml
│ │ │ └── 1_prod_ns.yaml
│ │ │ ├── 2_create_injector
│ │ │ ├── appmesh-ns.yaml
│ │ │ ├── ca-bundle.sh
│ │ │ ├── create.sh
│ │ │ ├── delete.sh
│ │ │ ├── gen-cert.sh
│ │ │ ├── inject.yaml
│ │ │ └── inject.yaml.template
│ │ │ ├── 3_add_crds
│ │ │ ├── controller-deployment.yaml
│ │ │ ├── mesh-definition.yaml
│ │ │ ├── virtual-node-definition.yaml
│ │ │ └── virtual-service-definition.yaml
│ │ │ ├── 4_create_initial_mesh_components
│ │ │ ├── mesh.yaml
│ │ │ ├── metal_and_jazz_placeholder_services.yaml
│ │ │ ├── nodes_representing_physical_services.yaml
│ │ │ ├── nodes_representing_virtual_services.yaml
│ │ │ └── virtual-services.yaml
│ │ │ ├── 5_canary
│ │ │ ├── jazz_service_update.yaml
│ │ │ ├── jazz_v2.yaml
│ │ │ ├── metal_service_update.yaml
│ │ │ └── metal_v2.yaml
│ │ │ ├── amctl.sh
│ │ │ ├── awscli.yaml
│ │ │ ├── cleanup.sh
│ │ │ ├── create.sh
│ │ │ └── ranCon.sh
│ └── voteapp
│ │ └── README.md
└── infrastructure
│ ├── appmesh-mesh.sh
│ ├── appmesh-mesh.yaml
│ ├── ecs-cluster.sh
│ ├── ecs-cluster.yaml
│ ├── eks-cluster.sh
│ ├── eks-cluster.yaml
│ ├── vpc.sh
│ ├── vpc.yaml
│ └── wipe_out_mesh.sh
└── walkthroughs
├── README.md
├── common
└── tools
│ └── vegeta-trafficgen
│ ├── Dockerfile
│ └── build.sh
├── eks-app-mesh-cross-account-acm
├── cleanup.sh
├── eks
│ └── setup.sh
├── infrastructure
│ ├── backend_vpc_peering_routes.yaml
│ ├── frontend_vpc_peering_routes.yaml
│ ├── infrastructure_backend.yaml
│ ├── infrastructure_frontend.yaml
│ └── setup.sh
├── mesh
│ ├── Config
│ ├── apply_tls_on_yelb_nodes.sh
│ ├── appserver_update.yaml
│ ├── ca_config.txt
│ ├── create_mesh.sh
│ ├── redis_update.yaml
│ ├── revoke_config.txt
│ ├── yelb-appserver.yaml
│ ├── yelb-db.yaml
│ ├── yelb-redis.yaml
│ ├── yelb-ui.yaml
│ ├── yelb_db_update.yaml
│ └── yelb_ui_update.yaml
├── readme.md
├── shared_resources
│ └── shared_mesh.yaml
└── yelb
│ ├── resources_backend.yaml
│ └── resources_frontend.yaml
├── eks-app-mesh-multi-account
├── cleanup.sh
├── eks
│ └── setup.sh
├── infrastructure
│ ├── backend_vpc_peering_routes.yaml
│ ├── frontend_vpc_peering_routes.yaml
│ ├── infrastructure_backend.yaml
│ ├── infrastructure_frontend.yaml
│ └── setup.sh
├── mesh
│ ├── create_mesh.sh
│ ├── yelb-appserver.yaml
│ ├── yelb-db.yaml
│ ├── yelb-redis.yaml
│ └── yelb-ui.yaml
├── readme.md
├── shared_resources
│ └── shared_mesh.yaml
└── yelb
│ ├── resources_backend.yaml
│ └── resources_frontend.yaml
├── eks-getting-started
├── .gitignore
├── baseline.sh
├── build-appserver-v2.sh
├── cloud9-startup.sh
├── infrastructure
│ ├── appmesh_templates
│ │ ├── appmesh-virtual-router-appserver-v1-v2.yaml
│ │ ├── appmesh-virtual-router-appserver-v2.yaml
│ │ ├── appmesh-yelb-appserver-v2.yaml
│ │ ├── appmesh-yelb-appserver.yaml
│ │ ├── appmesh-yelb-db.yaml
│ │ ├── appmesh-yelb-redis.yaml
│ │ └── appmesh-yelb-ui.yaml
│ ├── cleanup.sh
│ ├── create_eks.sh
│ ├── vpc_infrastructure.yaml
│ ├── yelb_appserver_v2_deployment.yaml
│ └── yelb_initial_deployment.yaml
└── yelb-appserver-v2
│ ├── Dockerfile
│ ├── Gemfile
│ ├── README.md
│ ├── modules
│ ├── getstats.rb
│ ├── getvotes.rb
│ ├── hostname.rb
│ ├── pageviews.rb
│ ├── restaurant.rb
│ ├── restaurantsdbread.rb
│ └── restaurantsdbupdate.rb
│ ├── startup.sh
│ └── yelb-appserver.rb
├── eks
├── README.md
├── appmesh-log-0.png
├── appmesh-log-1.png
├── base.md
├── cloudwatch.png
├── fluentd.yaml
├── grafana-dashboard-0.png
├── grafana-dashboard-1.png
├── jaeger-traces-0.png
├── jaeger-traces-1.png
├── logs-policy.json
├── o11y-cloudwatch.md
├── o11y-grafana.md
├── o11y-jaeger.md
├── o11y-prometheus.md
├── o11y-xray.md
├── prometheus-metrics-0.png
├── volumeMounts-sidecarEnv.md
├── xray-service-map.png
├── xray-traces-0.png
└── xray-traces-1.png
├── fargate
├── README.md
├── appmesh-colorapp.sh
├── appmesh-colorapp.yaml
├── envoy-container.json
├── fargate-colorteller-task-def.json
├── fargate-colorteller-task-def.sh
├── fargate-colorteller.sh
├── fargate-colorteller.yaml
├── img
│ ├── appmesh-fargate-colorapp-demo-1.png
│ ├── appmesh-fargate-colorapp-demo-2.png
│ ├── appmesh-fargate-colorapp-demo-3.png
│ ├── appmesh-fargate-routing-blue-green-1.png
│ ├── appmesh-fargate-routing-blue-green-2.png
│ └── appmesh-fargate-xray-blue-green.png
└── xray-container.json
├── howto-alb
├── README.md
├── app.yaml
├── colorapp
│ ├── Dockerfile
│ ├── app.py
│ ├── config.py
│ └── requirements.txt
├── deploy.sh
├── feapp
│ ├── Dockerfile
│ ├── app.py
│ ├── config.py
│ └── requirements.txt
├── howto-alb.png
└── infra.yaml
├── howto-circuit-breakers
├── README.md
├── howto-circuit-breakers.png
├── infrastructure
│ ├── ecr-repositories.sh
│ ├── ecr-repositories.yaml
│ ├── ecs-cluster.sh
│ ├── ecs-cluster.yaml
│ ├── ecs-service.sh
│ ├── ecs-service.yaml
│ ├── vpc.sh
│ └── vpc.yaml
├── mesh
│ ├── colorgateway-route-1.json
│ ├── colorgateway-route-2.json
│ ├── colorgateway-vg-update.json
│ ├── colorgateway-vg.json
│ ├── colorteller-black-vn-update.json
│ ├── colorteller-black-vn.json
│ ├── colorteller-route-1.json
│ ├── colorteller-route-2.json
│ ├── colorteller-vr-1.json
│ ├── colorteller-vr-2.json
│ ├── colorteller-vs-1.json
│ ├── colorteller-vs-2.json
│ ├── colorteller-white-vn-update.json
│ ├── colorteller-white-vn.json
│ ├── mesh.json
│ └── mesh.sh
├── src
│ ├── colorteller
│ │ ├── .gitignore
│ │ ├── Dockerfile
│ │ ├── deploy.sh
│ │ ├── go.mod
│ │ ├── go.sum
│ │ └── main.go
│ └── wrktool
│ │ ├── Dockerfile
│ │ ├── deploy.sh
│ │ └── wrk.py
└── vars.env
├── howto-cross-account
├── CrossAccount.png
├── README.md
├── deploy.sh
├── primary-account
│ ├── app.yaml
│ ├── deploy.sh
│ ├── infra.yaml
│ ├── mesh.yaml
│ └── share-resources.yaml
├── secondary-account
│ ├── app.yaml
│ ├── deploy.sh
│ ├── infra.yaml
│ └── mesh.yaml
├── updated-route.json
└── vars.env
├── howto-ecs-basics
├── .gitignore
├── README.md
├── deploy-cw-dashboards.sh
├── deploy.sh
├── deploy
│ ├── 0-prelude.yaml
│ ├── 1-servicediscovery.yaml
│ ├── 2-meshify.yaml
│ ├── 3-routing.yaml
│ └── cw-dashboard.yaml.template
├── images
│ ├── 0-prelude-app.png
│ ├── 0-prelude-xray-map.png
│ ├── 1-servicediscovery-app.png
│ ├── 1-servicediscovery-xray-map.png
│ ├── 2-meshify-app.png
│ ├── 2-meshify-xray-map.png
│ ├── 3-routing-app.png
│ └── 3-routing-xray-map.png
└── src
│ ├── colorapp
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
│ ├── cwagent
│ └── Dockerfile
│ └── feapp
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── howto-external-traffic
├── .gitignore
├── README.md
├── images
│ └── 2-meshify-app.png
├── infrastructure
│ ├── ecr-repositories.sh
│ ├── ecr-repositories.yaml
│ ├── ecs-cluster.sh
│ ├── ecs-cluster.yaml
│ ├── ecs-service.sh
│ ├── ecs-service.yaml
│ ├── vpc.sh
│ └── vpc.yaml
├── mesh
│ ├── mesh.sh
│ └── mesh.yaml
└── src
│ └── colorteller_with_external_traffic
│ ├── .gitignore
│ ├── Dockerfile
│ ├── deploy.sh
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── howto-grpc-ingress-gateway
├── Dockerfile
├── README.md
├── app.yaml
├── color.proto
├── color_server
│ ├── .gitignore
│ ├── Dockerfile
│ ├── color
│ │ └── color.pb.go
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── deploy.sh
├── generate_protos.sh
├── howto-grpc-ingress-gateway.png
├── infra.yaml
└── mesh.yaml
├── howto-grpc
├── README.md
├── app.yaml
├── color.proto
├── color_client
│ ├── .gitignore
│ ├── Dockerfile
│ ├── color
│ │ └── color.pb.go
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── color_server
│ ├── .gitignore
│ ├── Dockerfile
│ ├── color
│ │ └── color.pb.go
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── deploy.sh
├── generate_protos.sh
├── howto-grpc.png
├── infra.yaml
├── mesh.yaml
└── mesh
│ ├── route-all-methods.json
│ └── route-retries.json
├── howto-http-headers
├── README.md
├── app.yaml
├── color-route.json
├── colorapp
│ ├── Dockerfile
│ └── serve.py
├── deploy.sh
├── feapp
│ ├── Dockerfile
│ └── serve.py
└── infra.yaml
├── howto-http-retries
├── README.md
├── app.yaml
├── blue-route-no-retry.json
├── blue-route.json
├── colorapp
│ ├── Dockerfile
│ └── serve.py
├── components
│ └── retries.png
├── deploy.sh
├── feapp
│ ├── Dockerfile
│ └── serve.py
└── infra.yaml
├── howto-http2
├── README.md
├── app.yaml
├── color_client
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── color_server
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── deploy.sh
├── howto-http2.png
├── infra.yaml
├── mesh.yaml
└── mesh
│ ├── route-blue.json
│ ├── route-red-blue-green.json
│ ├── route-red-blue.json
│ ├── route-red-retries.json
│ └── route-red.json
├── howto-ingress-gateway
├── README.md
├── howto-ingress-gateway.png
├── infrastructure
│ ├── ecr-repositories.sh
│ ├── ecr-repositories.yaml
│ ├── ecs-cluster.sh
│ ├── ecs-cluster.yaml
│ ├── ecs-service.sh
│ ├── ecs-service.yaml
│ ├── vpc.sh
│ └── vpc.yaml
├── mesh
│ ├── colorgateway-route-1.json
│ ├── colorgateway-route-2.json
│ ├── colorgateway-vg-backendDefaults.json
│ ├── colorgateway-vg.json
│ ├── colorteller-black-vn-tls.json
│ ├── colorteller-black-vn.json
│ ├── colorteller-blue-vn-tls.json
│ ├── colorteller-blue-vn.json
│ ├── colorteller-red-vn-tls.json
│ ├── colorteller-red-vn.json
│ ├── colorteller-route-1.json
│ ├── colorteller-route-2.json
│ ├── colorteller-vr-1.json
│ ├── colorteller-vr-2.json
│ ├── colorteller-vs-1.json
│ ├── colorteller-vs-2.json
│ ├── colorteller-white-vn-tls.json
│ ├── colorteller-white-vn.json
│ ├── mesh.json
│ └── mesh.sh
└── src
│ └── colorteller
│ ├── .gitignore
│ ├── Dockerfile
│ ├── Gopkg.lock
│ ├── Gopkg.toml
│ ├── deploy.sh
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── howto-ipv6
├── README.md
├── cloud
│ ├── ecs-service.yaml
│ └── mesh
│ │ ├── custom-preference.yaml
│ │ ├── mesh-v4-only.yaml
│ │ ├── mesh-v4-preferred.yaml
│ │ ├── mesh-v6-only.yaml
│ │ ├── mesh-v6-preferred.yaml
│ │ └── override-mesh-preference.yaml
├── color_client
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── color_server_dual
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── color_server_v4
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── color_server_v6
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── deploy.sh
├── dns
│ ├── ecs-service.yaml
│ └── mesh
│ │ ├── custom-preference.yaml
│ │ ├── mesh-v4-only.yaml
│ │ ├── mesh-v4-preferred.yaml
│ │ ├── mesh-v6-only.yaml
│ │ ├── mesh-v6-preferred.yaml
│ │ └── override-mesh-preference.yaml
├── infra
│ ├── ecs-cluster.yaml
│ └── vpc.yaml
├── setup_graph.png
└── vars.env
├── howto-k8s-alb
├── .gitignore
├── README.md
├── colorapp
│ ├── Dockerfile
│ └── serve.py
├── deploy.sh
├── feapp
│ ├── Dockerfile
│ └── serve.py
├── howto-k8s-alb.png
├── v1beta1
│ └── manifest.yaml.template
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-cloudmap
├── .gitignore
├── README.md
├── colorapp
│ ├── Dockerfile
│ ├── app.py
│ ├── config.py
│ └── requirements.txt
├── deploy.sh
├── feapp
│ ├── Dockerfile
│ ├── app.py
│ ├── config.py
│ └── requirements.txt
├── v1beta1
│ └── manifest.yaml.template
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-connection-pools
├── .gitignore
├── README.md
├── colorapp
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── deploy.sh
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-cross-cluster
├── README.md
├── colorapp
│ ├── Dockerfile
│ ├── app.py
│ ├── config.py
│ └── requirements.txt
├── deploy.sh
├── feapp
│ ├── Dockerfile
│ ├── app.py
│ ├── config.py
│ └── requirements.txt
├── v1beta1
│ ├── cluster1.yaml.template
│ └── cluster2.yaml.template
└── v1beta2
│ ├── cluster1.yaml.template
│ └── cluster2.yaml.template
├── howto-k8s-egress
├── .gitignore
├── README.md
├── colorapp
│ ├── Dockerfile
│ └── serve.py
├── deploy.sh
├── feapp
│ ├── Dockerfile
│ └── serve.py
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-envoy-logging-custom-format
├── README.md
├── colorapp
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── deploy.sh
├── feapp
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
└── manifest.yaml.template
├── howto-k8s-fargate
├── .gitignore
├── README.md
├── deploy.sh
├── src
│ ├── colorapp
│ │ ├── .gitignore
│ │ ├── Dockerfile
│ │ ├── go.mod
│ │ ├── go.sum
│ │ └── main.go
│ └── feapp
│ │ ├── .gitignore
│ │ ├── Dockerfile
│ │ ├── go.mod
│ │ ├── go.sum
│ │ └── main.go
├── v1beta1
│ ├── clusterconfig.yaml
│ └── manifest.yaml.template
└── v1beta2
│ ├── clusterconfig.yaml
│ └── manifest.yaml.template
├── howto-k8s-grpc-ingress-v2
├── Dockerfile
├── README.md
├── deploy.sh
├── greeter
│ ├── .gitignore
│ ├── Dockerfile
│ ├── cmd
│ │ └── main.go
│ ├── go.mod
│ ├── go.sum
│ ├── input
│ │ ├── input.pb.go
│ │ └── input.proto
│ └── server
│ │ └── greeting.go
├── images
│ └── grpc.png
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-grpc
├── .gitignore
├── README.md
├── color.proto
├── color_client
│ ├── .gitignore
│ ├── Dockerfile
│ ├── color
│ │ └── color.pb.go
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── color_server
│ ├── .gitignore
│ ├── Dockerfile
│ ├── color
│ │ └── color.pb.go
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── deploy.sh
├── generate_protos.sh
├── v1beta1
│ └── manifest.yaml.template
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-http-headers
├── .gitignore
├── README.md
├── colorapp
│ ├── Dockerfile
│ └── serve.py
├── deploy.sh
├── feapp
│ ├── Dockerfile
│ └── serve.py
├── v1beta1
│ └── manifest.yaml.template
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-http-ingress-v2
├── README.md
├── colorapp
│ ├── Dockerfile
│ └── serve.py
├── deploy.sh
├── gwroute_setup.sh
├── images
│ └── basic_setup.png
└── v1beta2
│ ├── gatewayroutes
│ ├── header-match.yaml.template
│ ├── method-match.yaml.template
│ ├── path-match.yaml.template
│ ├── prefix-match.yaml.template
│ ├── query-match.yaml.template
│ ├── rewrite-path.yaml.template
│ └── rewrite-prefix.yaml.template
│ └── manifest.yaml.template
├── howto-k8s-http2
├── .gitignore
├── README.md
├── color_client
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── color_server
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── deploy.sh
├── v1beta1
│ └── manifest.yaml.template
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-ingress-gateway
├── .gitignore
├── README.md
├── colorapp
│ ├── Dockerfile
│ └── serve.py
├── deploy.sh
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-ipv6
├── .gitignore
├── README.md
├── color_client
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── color_server
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── deploy.sh
├── ipv6-cluster.yaml
└── v1beta2
│ ├── cloud
│ └── manifest.yaml.template
│ └── dns
│ └── manifest.yaml.template
├── howto-k8s-metrics-extension
├── README.md
├── deploy
│ ├── cluster.yaml.template
│ ├── djapp-v1.yaml.template
│ ├── djapp-v2.yaml.template
│ ├── djapp-v3.yaml.template
│ ├── djapp-v4.yaml.template
│ ├── djapp-v5.yaml.template
│ └── namespace.yaml.template
├── fill.sh
├── images.sh
├── images
│ ├── djapp-v1-cloudwatch-metric-dimensions.png
│ ├── djapp-v1-cloudwatch-upstream-rq.png
│ ├── djapp-v2-cloudwatch-metrics.png
│ └── djapp.png
└── metric.sh
├── howto-k8s-mtls-file-based
├── .gitignore
├── README.md
├── colorapp
│ ├── Dockerfile
│ └── serve.py
├── feapp
│ ├── Dockerfile
│ └── serve.py
├── mesh.sh
├── mtls
│ ├── ca_1_cert.cfg
│ ├── ca_2_cert.cfg
│ ├── certs.sh
│ ├── cleanup.sh
│ ├── colorapp-blue_cert.cfg
│ ├── colorapp-green_cert.cfg
│ ├── deploy.sh
│ └── front_cert.cfg
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-mtls-sds-based
├── .gitignore
├── README.md
├── cleanup.sh
├── colorapp
│ ├── Dockerfile
│ └── serve.py
├── deploy_app.sh
├── deploy_spire.sh
├── feapp
│ ├── Dockerfile
│ └── serve.py
├── spire
│ ├── register_server_entries.sh
│ └── spire_setup.yaml
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-multi-region
├── .gitignore
├── README.md
├── colorapp
│ ├── Dockerfile
│ └── serve.py
├── ec2_cfn.yaml
├── eks-multi-region-appMeshController.sh
├── eks-multi-region-configureRoute53.sh
├── eks-multi-region-deploy.sh
├── eks-multi-region-eksCluster.sh
├── envoy-iam-policy.json
├── images
│ ├── Architecture.png
│ ├── route53HealthCheck.png
│ ├── route53HealthCheckFailure.png
│ └── route53HostedZone.png
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-multiple-listeners
├── README.md
├── app
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
└── manifest.yaml
├── howto-k8s-outlier-detection
├── .gitignore
├── README.md
├── colorapp
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── deploy.sh
├── feapp
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── results.bin
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-retry-policy
├── .gitignore
├── README.md
├── colorapp
│ ├── Dockerfile
│ └── serve.py
├── deploy.sh
├── feapp
│ ├── Dockerfile
│ └── serve.py
├── v1beta1
│ └── manifest.yaml.template
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-timeout-policy
├── .gitignore
├── README.md
├── colorapp
│ ├── Dockerfile
│ ├── app.py
│ ├── config.py
│ └── requirements.txt
├── deploy.sh
├── feapp
│ ├── Dockerfile
│ ├── app.py
│ ├── config.py
│ └── requirements.txt
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-tls-acm
├── README.md
├── colorapp
│ ├── Dockerfile
│ └── serve.py
├── feapp
│ ├── Dockerfile
│ └── serve.py
├── mesh.sh
└── v1beta2
│ └── manifest.yaml.template
├── howto-k8s-tls-file-based
├── .gitignore
├── README.md
├── colorapp
│ ├── Dockerfile
│ └── serve.py
├── feapp
│ ├── Dockerfile
│ └── serve.py
├── mesh.sh
├── tls
│ ├── ca_1_cert.cfg
│ ├── ca_2_cert.cfg
│ ├── certs.sh
│ ├── cleanup.sh
│ ├── colorapp-blue_cert.cfg
│ ├── colorapp-green_cert.cfg
│ └── deploy.sh
└── v1beta2
│ └── manifest.yaml.template
├── howto-match-and-rewrite-at-ingress
├── README.md
├── howto-match-and-rewrite-at-ingress.png
├── infrastructure
│ ├── ecr-repositories.sh
│ ├── ecr-repositories.yaml
│ ├── ecs-cluster.sh
│ ├── ecs-cluster.yaml
│ ├── ecs-service.sh
│ ├── ecs-service.yaml
│ ├── vpc.sh
│ └── vpc.yaml
├── mesh
│ ├── colorgateway-route-1.json
│ ├── colorgateway-route-2.json
│ ├── colorgateway-route-updated-disabled_rewrite.json
│ ├── colorgateway-route-updated-hostname-match.json
│ ├── colorgateway-route-updated-rewrite.json
│ ├── colorgateway-vg.json
│ ├── colorteller-red-vn.json
│ ├── colorteller-route-1.json
│ ├── colorteller-route-2.json
│ ├── colorteller-route-updated-rewrite.json
│ ├── colorteller-vr-1.json
│ ├── colorteller-vr-2.json
│ ├── colorteller-vs-1.json
│ ├── colorteller-vs-2.json
│ ├── colorteller-yellow-vn.json
│ ├── mesh.json
│ └── mesh.sh
├── src
│ └── colorteller
│ │ ├── .gitignore
│ │ ├── Dockerfile
│ │ ├── deploy.sh
│ │ ├── go.mod
│ │ ├── go.sum
│ │ └── main.go
└── vars.env
├── howto-metrics-extension-ecs
├── README.md
├── dashboard.sh
├── deploy.sh
├── deploy
│ ├── dashboard-v1.yaml
│ ├── djapp-v1.yaml
│ ├── djapp-v2.yaml
│ ├── djapp-v3.yaml
│ ├── djapp-v4.yaml
│ └── djapp-v5.yaml
├── images
│ ├── djapp-v1-cloudwatch-metric-dimensions.png
│ ├── djapp-v1-cloudwatch-upstream-rq.png
│ ├── djapp-v2-cloudwatch-metrics.png
│ ├── djapp.png
│ └── gateway-generated-dashboard.png
├── metric.sh
└── src
│ ├── cwagent
│ └── Dockerfile
│ ├── dashboard-v1
│ ├── Dockerfile
│ ├── index.js
│ ├── package-lock.json
│ └── package.json
│ └── djapp
│ ├── .gitignore
│ ├── Dockerfile
│ ├── djapp.go
│ ├── go.mod
│ └── go.sum
├── howto-multiple-listeners
├── README.md
├── howto-ml-walkthrough.drawio
├── howto-ml-walkthrough.png
├── infrastructure
│ ├── ecr-repositories.sh
│ ├── ecr-repositories.yaml
│ ├── ecs-cluster.sh
│ ├── ecs-cluster.yaml
│ ├── ecs-service.sh
│ ├── ecs-service.yaml
│ ├── vpc.sh
│ └── vpc.yaml
├── mesh
│ ├── color-gateway-route.json
│ ├── colorteller-vn.json
│ ├── colorteller-vs.json
│ ├── foodteller-vn.json
│ ├── foodteller-vr.json
│ ├── foodteller-vs.json
│ ├── fruit-gateway-route.json
│ ├── fruit-route.json
│ ├── mesh.json
│ ├── mesh.sh
│ ├── tellergateway-vg.json
│ ├── vegetable-gateway-route.json
│ └── vegetable-route.json
├── src
│ └── teller
│ │ ├── .gitignore
│ │ ├── Dockerfile
│ │ ├── deploy.sh
│ │ ├── go.mod
│ │ ├── go.sum
│ │ └── main.go
└── vars.env
├── howto-mutual-tls-file-provided-by-acm
├── README.md
├── infrastructure
│ ├── acmpca.sh
│ ├── acmpca.yaml
│ ├── deploy.sh
│ ├── deploy.yaml
│ ├── ecr-repositories.sh
│ ├── ecr-repositories.yaml
│ ├── ecs-cluster.sh
│ ├── ecs-cluster.yaml
│ ├── ecs-service.sh
│ ├── ecs-service.yaml
│ ├── mesh.sh
│ ├── mesh.yaml
│ ├── vpc.sh
│ └── vpc.yaml
└── src
│ ├── colorteller
│ ├── .gitignore
│ ├── Dockerfile
│ ├── deploy.sh
│ ├── go.mod
│ ├── go.sum
│ └── main.go
│ └── customEnvoyImage
│ ├── Dockerfile
│ ├── deploy.sh
│ └── entryPoint.sh
├── howto-mutual-tls-file-provided
├── .gitignore
├── README.md
├── infrastructure
│ ├── ecr-repositories.sh
│ ├── ecr-repositories.yaml
│ ├── ecs-cluster.sh
│ ├── ecs-cluster.yaml
│ ├── ecs-service.sh
│ ├── ecs-service.yaml
│ ├── vpc.sh
│ └── vpc.yaml
├── mesh
│ ├── colorteller-gwroute.json
│ ├── colorteller-vn.json
│ ├── colorteller-vs.json
│ ├── gateway-vgw.json
│ ├── mesh.json
│ ├── mesh.sh
│ └── updates
│ │ ├── colorteller-vn-strict-tls.json
│ │ ├── colorteller-vn-strict-validation.json
│ │ ├── gateway-vgw-client-cert.json
│ │ └── gateway-vgw-client-policy.json
└── src
│ ├── colorteller
│ ├── .gitignore
│ ├── Dockerfile
│ ├── deploy.sh
│ ├── go.mod
│ ├── go.sum
│ └── main.go
│ ├── customEnvoyImage
│ ├── Dockerfile
│ ├── deploy.sh
│ └── entryPoint.sh
│ └── tlsCertificates
│ ├── ca_cert.cfg
│ ├── certs.sh
│ ├── cleanup.sh
│ ├── colorteller_cert.cfg
│ ├── deploy.sh
│ └── gateway_cert.cfg
├── howto-outlier-detection
├── README.md
├── application.yaml
├── deploy.sh
├── infrastructure.yaml
├── mesh.sh
├── mesh
│ ├── color-vn-with-outlier-detection.json
│ ├── color-vn.json
│ ├── color-vs.json
│ ├── front-vn.json
│ └── mesh.yaml
└── src
│ ├── color-app
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
│ └── frontend-app
│ ├── .gitignore
│ ├── Dockerfile
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── howto-servicediscovery-cloudmap
├── README.md
├── app.yaml
├── deploy-images.sh
├── deploy.sh
├── mesh.yaml
└── vpc.yaml
├── howto-timeout-policy
├── README.md
├── howto-timeout-with-gateway.png
├── infrastructure
│ ├── ecr-repositories.sh
│ ├── ecr-repositories.yaml
│ ├── ecs-cluster.sh
│ ├── ecs-cluster.yaml
│ ├── ecs-service.sh
│ ├── ecs-service.yaml
│ ├── vpc.sh
│ └── vpc.yaml
├── mesh
│ ├── colorgateway-vn-timeout20s.json
│ ├── colorgateway-vn.json
│ ├── colorteller-route-timeout20s.json
│ ├── colorteller-route-timeout5s.json
│ ├── colorteller-route.json
│ ├── colorteller-route1-timeout18s.json
│ ├── colorteller-route1.json
│ ├── colorteller-route2-timeout10s.json
│ ├── colorteller-route2.json
│ ├── colorteller-vn-timeout18s.json
│ ├── colorteller-vn-timeout20s.json
│ ├── colorteller-vn.json
│ ├── colorteller-vr.json
│ ├── colorteller-vs.json
│ ├── colorteller-white-vn-timeout20s.json
│ ├── colorteller-white-vn.json
│ ├── mesh.json
│ ├── mesh.sh
│ ├── mesh.yaml
│ ├── publicgateway-route.json
│ └── publicgateway-vg.json
└── src
│ ├── colorgateway
│ ├── .gitignore
│ ├── Dockerfile
│ ├── Gopkg.lock
│ ├── Gopkg.toml
│ ├── deploy.sh
│ ├── go.mod
│ ├── go.sum
│ └── main.go
│ └── colorteller
│ ├── .gitignore
│ ├── Dockerfile
│ ├── Gopkg.lock
│ ├── Gopkg.toml
│ ├── deploy.sh
│ ├── go.mod
│ ├── go.sum
│ └── main.go
├── howto-tls-file-provided
├── .gitignore
├── README.md
├── infrastructure
│ ├── ecr-repositories.sh
│ ├── ecr-repositories.yaml
│ ├── ecs-cluster.sh
│ ├── ecs-cluster.yaml
│ ├── ecs-service.sh
│ ├── ecs-service.yaml
│ ├── vpc.sh
│ └── vpc.yaml
├── mesh
│ ├── mesh.sh
│ └── mesh.yaml
└── src
│ ├── colorteller
│ ├── .gitignore
│ ├── Dockerfile
│ ├── Gopkg.lock
│ ├── Gopkg.toml
│ ├── deploy.sh
│ ├── go.mod
│ ├── go.sum
│ └── main.go
│ ├── customEnvoyImage
│ ├── Dockerfile
│ ├── deploy.sh
│ └── entryPoint.sh
│ └── tlsCertificates
│ ├── ca_1_cert.cfg
│ ├── ca_2_cert.cfg
│ ├── certs.sh
│ ├── cleanup.sh
│ ├── colorteller_green_cert.cfg
│ ├── colorteller_white_cert.cfg
│ └── deploy.sh
└── tls-with-acm
├── .gitignore
├── README.md
├── infrastructure
├── ecr-repositories.sh
├── ecr-repositories.yaml
├── ecs-cluster.sh
├── ecs-cluster.yaml
├── ecs-service.sh
├── ecs-service.yaml
├── vpc.sh
└── vpc.yaml
├── mesh
├── mesh.sh
└── mesh.yaml
└── src
└── colorteller
├── .gitignore
├── Dockerfile
├── Gopkg.lock
├── Gopkg.toml
├── deploy.sh
├── go.mod
├── go.sum
└── main.go
/.github/PULL_REQUEST_TEMPLATE.md:
--------------------------------------------------------------------------------
1 | *Issue #, if available:*
2 |
3 | *Description of changes:*
4 |
5 |
6 | By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
7 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | .env*
2 | examples/apps/colorapp/pkg/
3 | examples/apps/colorapp/bin
4 | .DS_Store
5 | .idea
6 | .vscode
7 |
--------------------------------------------------------------------------------
/CODEOWNERS:
--------------------------------------------------------------------------------
1 | # @See https://help.github.com/articles/about-codeowners/
2 | * @aws/aws-app-mesh
3 |
--------------------------------------------------------------------------------
/CODE_OF_CONDUCT.md:
--------------------------------------------------------------------------------
1 | ## Code of Conduct
2 | This project has adopted the [Amazon Open Source Code of Conduct](https://aws.github.io/code-of-conduct).
3 | For more information see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact
4 | opensource-codeofconduct@amazon.com with any additional questions or comments.
5 |
--------------------------------------------------------------------------------
/blogs/cert-manager-tls/ca-issuer.yaml:
--------------------------------------------------------------------------------
1 | apiVersion: cert-manager.io/v1
2 | kind: Issuer
3 | metadata:
4 | name: ca-issuer
5 | namespace: yelb
6 | spec:
7 | ca:
8 | secretName: ca-key-pair
9 |
--------------------------------------------------------------------------------
/blogs/ecs-canary-deployments-pipeline/README.md:
--------------------------------------------------------------------------------
1 |
ecs-canary-deployments-pipeline
2 |
3 | A step-by-step guide to this example can be found in this blob: https://aws.amazon.com/cn/blogs/containers/create-a-pipeline-with-canary-deployments-for-amazon-ecs-using-aws-app-mesh/
4 |
5 | Note that the yelb sample app associated with the tutorial is in a separate github repo: https://github.com/tiagoReichert/yelb
6 | If you follow the steps in the blob, it will be associated correctly.
7 |
--------------------------------------------------------------------------------
/blogs/ecs-canary-deployments-pipeline/requirements.txt:
--------------------------------------------------------------------------------
1 | botocore
2 | boto3
--------------------------------------------------------------------------------
/blogs/ecs-canary-deployments-pipeline/setup/scripts/create_prometheus_env.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -e
4 |
5 | # Load environment variables
6 | source ~/.bash_profile
7 |
8 | base_path="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
9 |
10 | aws --region "${AWS_REGION}" \
11 | cloudformation deploy \
12 | --stack-name "${ENVIRONMENT_NAME}-monitoring-resources" \
13 | --capabilities CAPABILITY_NAMED_IAM \
14 | --template-file "${base_path}/../templates/create-prometheus-env.yaml" \
15 | --parameter-overrides \
16 | ECSClusterName="${ENVIRONMENT_NAME}" \
17 | CreateIAMRoles="True"
--------------------------------------------------------------------------------
/blogs/ecs-canary-deployments-pipeline/setup/scripts/create_vpc.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -e
4 |
5 | source ~/.bash_profile
6 |
7 | base_path="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
8 |
9 | aws --region "${AWS_REGION}" \
10 | cloudformation deploy \
11 | --stack-name "${ENVIRONMENT_NAME}-vpc" \
12 | --capabilities CAPABILITY_IAM \
13 | --template-file "${base_path}/../templates/vpc.yaml" \
14 | --parameter-overrides \
15 | EnvironmentName="${ENVIRONMENT_NAME}"
16 |
--------------------------------------------------------------------------------
/blogs/ecs-canary-deployments-pipeline/shared_stack/lambda_functions/update_deployment_version/main.py:
--------------------------------------------------------------------------------
1 | """ Update the Version in SSM. """
2 | import boto3
3 |
4 | #Client connections
5 | SSM_CLIENT = boto3.client('ssm')
6 |
7 | def lambda_handler(event, _context):
8 | """ Update the Version in SSM. """
9 | return SSM_CLIENT.put_parameter(
10 | Name='{}-canary-{}-version'.format(
11 | event.get('EnvironmentName'),
12 | event.get('MicroserviceName')
13 | ),
14 | Value=event.get('ContainerImage'),
15 | Type="SecureString",
16 | Overwrite=True
17 | )
18 |
--------------------------------------------------------------------------------
/blogs/ecs-ec2-crossvpc-with-tls/cleanup.sh:
--------------------------------------------------------------------------------
1 | # Delete the CF Stack
2 |
3 |
4 | aws cloudformation delete-stack --stack-name appmesh-components
5 | aws cloudformation delete-stack --stack-name appmesh-acm
6 | aws cloudformation delete-stack --stack-name appmesh-nodejs
7 | aws cloudformation delete-stack --stack-name appmesh-frontend-crystal
8 |
9 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/README.md:
--------------------------------------------------------------------------------
1 | # Service Connectivity Inside and Outside the AWS App Mesh (ECS/Fargate)
2 |
3 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/mesh/yelb-app-gateway-route.json:
--------------------------------------------------------------------------------
1 | {
2 | "gatewayRouteName" : "yelbapp-gatewayroute",
3 | "meshName" : "yelb",
4 | "spec" : {
5 | "httpRoute" : {
6 | "action" : {
7 | "target" : {
8 | "virtualService" : {
9 | "virtualServiceName" : "yelb-appserver"
10 | }
11 | }
12 | },
13 | "match" : {
14 | "prefix" : "/api"
15 | }
16 | }
17 | },
18 | "virtualGatewayName" : "yelb-gateway"
19 | }
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/mesh/yelb-app-vs.json:
--------------------------------------------------------------------------------
1 | {
2 | "meshName": "yelb",
3 | "spec": {
4 | "provider": {
5 | "virtualNode": {
6 | "virtualNodeName": "yelb-app-server"
7 | }
8 | }
9 | },
10 | "virtualServiceName": "yelb-appserver"
11 | }
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/mesh/yelb-appmesh-appserver.sh:
--------------------------------------------------------------------------------
1 | #Create Virtual Node for Yelb App Server
2 | aws appmesh create-virtual-node --mesh-name yelb --virtual-node-name yelb-app-server --cli-input-json file://yelb-app-vn.json
3 |
4 | #Create Virtual service and map it to yelb-app-server
5 | aws appmesh create-virtual-service --cli-input-json file://yelb-app-vs.json
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/mesh/yelb-appmesh-gateway.sh:
--------------------------------------------------------------------------------
1 |
2 | #Creates a Virtual Gateway
3 | aws appmesh create-virtual-gateway --cli-input-json file://yelb-vg.json
4 |
5 |
6 | #Creates Virtual Gateway Route for App
7 | aws appmesh create-gateway-route --cli-input-json file://yelb-app-gateway-route.json
8 |
9 |
10 | #Creates Virtual Gateway Route for UI
11 | aws appmesh create-gateway-route --cli-input-json file://yelb-ui-gateway-route.json
12 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/mesh/yelb-appmesh-recipe.sh:
--------------------------------------------------------------------------------
1 |
2 | #Create Virtual Node for Yelb Recipe
3 | aws appmesh create-virtual-node --mesh-name yelb --virtual-node-name yelb-recipe --cli-input-json file://yelb-recipe-vn.json
4 |
5 | #Create Virtual Service
6 | aws appmesh create-virtual-service --cli-input-json file://yelb-recipe-vs.json
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/mesh/yelb-appmesh-ui.sh:
--------------------------------------------------------------------------------
1 |
2 | #create virtual node yelb-ui
3 | aws appmesh create-virtual-node --mesh-name yelb --virtual-node-name yelb-ui --cli-input-json file://yelb-ui-vn.json
4 |
5 | #create virtual service
6 | aws appmesh create-virtual-service --cli-input-json file://yelb-ui-vs.json
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/mesh/yelb-db-vn.json:
--------------------------------------------------------------------------------
1 | {
2 | "meshName": "yelb",
3 | "spec": {
4 | "listeners": [
5 | {
6 | "portMapping": {
7 | "port": 5432,
8 | "protocol": "tcp"
9 | }
10 | }
11 | ],
12 | "serviceDiscovery": {
13 | "dns": {
14 | "hostname": $DNS_HOSTNAME
15 | }
16 | }
17 | },
18 | "virtualNodeName": "yelb-db"
19 | }
20 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/mesh/yelb-db-vs.json:
--------------------------------------------------------------------------------
1 | {
2 | "meshName": "yelb",
3 | "spec": {
4 | "provider": {
5 | "virtualNode": {
6 | "virtualNodeName": "yelb-db"
7 | }
8 | }
9 | },
10 | "virtualServiceName": "yelb-db"
11 | }
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/mesh/yelb-recipe-vn.json:
--------------------------------------------------------------------------------
1 | {
2 | "meshName": "yelb",
3 | "spec": {
4 | "listeners": [
5 | {
6 | "portMapping": {
7 | "port": 80,
8 | "protocol": "http"
9 | }
10 | }
11 | ],
12 | "serviceDiscovery": {
13 | "dns": {
14 | "hostname": "www.recipepuppy.com"
15 | }
16 | }
17 | },
18 | "virtualNodeName": "yelb-recipe"
19 | }
20 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/mesh/yelb-recipe-vs.json:
--------------------------------------------------------------------------------
1 | {
2 | "meshName": "yelb",
3 | "spec": {
4 | "provider": {
5 | "virtualNode": {
6 | "virtualNodeName": "yelb-recipe"
7 | }
8 | }
9 | },
10 | "virtualServiceName": "www.recipepuppy.com"
11 | }
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/mesh/yelb-redis-vn.json:
--------------------------------------------------------------------------------
1 | {
2 | "meshName": "yelb",
3 | "spec": {
4 | "listeners": [
5 | {
6 | "portMapping": {
7 | "port": 6379,
8 | "protocol": "tcp"
9 | }
10 | }
11 | ],
12 | "serviceDiscovery": {
13 | "dns": {
14 | "hostname": $DNS_HOSTNAME
15 | }
16 | }
17 | },
18 | "virtualNodeName": "yelb-redis-server"
19 | }
20 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/mesh/yelb-redis-vs.json:
--------------------------------------------------------------------------------
1 | {
2 | "meshName": "yelb",
3 | "spec": {
4 | "provider": {
5 | "virtualNode": {
6 | "virtualNodeName": "yelb-redis-server"
7 | }
8 | }
9 | },
10 | "virtualServiceName": "redis-server"
11 | }
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/mesh/yelb-ui-gateway-route.json:
--------------------------------------------------------------------------------
1 | {
2 | "gatewayRouteName" : "yelbui-gatewayroute",
3 | "meshName" : "yelb",
4 | "spec" : {
5 | "httpRoute" : {
6 | "action" : {
7 | "target" : {
8 | "virtualService" : {
9 | "virtualServiceName" : "yelb-ui"
10 | }
11 | }
12 | },
13 | "match" : {
14 | "prefix" : "/"
15 | }
16 | }
17 | },
18 | "virtualGatewayName" : "yelb-gateway"
19 | }
20 |
21 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/mesh/yelb-ui-vs.json:
--------------------------------------------------------------------------------
1 | {
2 | "meshName": "yelb",
3 | "spec": {
4 | "provider": {
5 | "virtualNode": {
6 | "virtualNodeName": "yelb-ui"
7 | }
8 | }
9 | },
10 | "virtualServiceName": "yelb-ui"
11 | }
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/mesh/yelb-vg.json:
--------------------------------------------------------------------------------
1 | {
2 | "meshName" : "yelb",
3 | "spec" : {
4 | "listeners" : [
5 | {
6 | "portMapping" : {
7 | "port" : 80,
8 | "protocol" : "http"
9 | }
10 | }
11 | ]
12 | },
13 | "virtualGatewayName" : "yelb-gateway"
14 | }
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/sample.settings:
--------------------------------------------------------------------------------
1 | export AWS_ACCOUNT_ID=
2 | export AWS_DEFAULT_REGION=""
3 | export ENVOY_IMAGE="public.ecr.aws/appmesh/aws-appmesh-envoy:v1.25.1.0-prod"
4 | export VPC=""
5 | export PUBLIC_SUBNET_1=""
6 | export PUBLIC_SUBNET_2=""
7 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/deployments/platformdeployment/AWS/ECS/startup.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | # Install packages
4 | sudo yum update -y
5 | sudo yum install jq moreutils -y
6 |
7 | # Upgrade pip
8 | sudo pip3 install --upgrade pip
9 | echo "export PATH=~/.local/bin:$PATH" >> ~/.bash_profile
10 | source ~/.bash_profile
11 |
12 | # Install awscli
13 | pip3 install awscli --upgrade --user
14 | source ~/.bash_profile
15 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-appserver/Gemfile:
--------------------------------------------------------------------------------
1 | source 'https://rubygems.org'
2 | gem 'pg'
3 | gem 'redis'
4 | gem install httparty
5 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-appserver/modules/getrecipe_dontchange.rb:
--------------------------------------------------------------------------------
1 |
2 | def getrecipe()
3 | #recipeurl ="https://www.allrecipes.com/recipe/60500/the-most-incredible-pancake-bites-ever/"
4 | recipeurl = '{"recipelink": "'+ $recipeendpoint + '"' + "}"
5 | return recipeurl
6 | end
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-appserver/modules/getstats.rb:
--------------------------------------------------------------------------------
1 | require_relative 'hostname'
2 | require_relative 'pageviews'
3 |
4 | def getstats()
5 | hostname = hostname()
6 | pageviews = pageviews()
7 | stats = '{"hostname": "' + hostname + '"' + ", " + '"pageviews":' + pageviews + "}"
8 | return stats
9 | end
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-appserver/modules/getvotes.rb:
--------------------------------------------------------------------------------
1 | require_relative 'restaurantsdbread'
2 | require_relative 'restaurantsdbupdate'
3 |
4 | def getvotes()
5 | outback = restaurantsdbread("outback")
6 | ihop = restaurantsdbread("ihop")
7 | bucadibeppo = restaurantsdbread("bucadibeppo")
8 | chipotle = restaurantsdbread("chipotle")
9 | votes = '[{"name": "outback", "value": ' + outback + '},' + '{"name": "bucadibeppo", "value": ' + bucadibeppo + '},' + '{"name": "ihop", "value": ' + ihop + '}, ' + '{"name": "chipotle", "value": ' + chipotle + '}]'
10 | return votes
11 | end
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-appserver/modules/hostname.rb:
--------------------------------------------------------------------------------
1 | require 'socket'
2 |
3 | def hostname()
4 | hostnamedata = Socket.gethostname
5 | return hostnamedata
6 | end
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-appserver/modules/restaurant.rb:
--------------------------------------------------------------------------------
1 | require_relative 'restaurantsdbread'
2 | require_relative 'restaurantsdbupdate'
3 |
4 | def restaurantsupdate(restaurant)
5 | restaurantsdbupdate(restaurant)
6 | restaurantcount = restaurantsdbread(restaurant)
7 | return restaurantcount
8 | end
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-appserver/startup.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | # when the variable is populated a search domain entry is added to resolv.conf at startup
4 | # this is needed for the ECS service discovery (a search domain can't be added with awsvpc mode)
5 | if [ $SEARCH_DOMAIN ]; then echo "search ${SEARCH_DOMAIN}" >> /etc/resolv.conf; fi
6 |
7 | ruby /app/yelb-appserver.rb -o 0.0.0.0
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-ui/clarity-seed-newfiles/src/app/app.routing.ts:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2016 VMware, Inc. All Rights Reserved.
3 | * This software is released under MIT license.
4 | * The full license information can be found in LICENSE in the root directory of this project.
5 | */
6 | import { ModuleWithProviders } from '@angular/core/src/metadata/ng_module';
7 | import { Routes, RouterModule } from '@angular/router';
8 |
9 | export const ROUTES: Routes = [
10 | {path: '', redirectTo: 'home', pathMatch: 'full'}
11 | ];
12 |
13 | export const ROUTING: ModuleWithProviders = RouterModule.forRoot(ROUTES);
14 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-ui/clarity-seed-newfiles/src/app/env.service.spec.ts:
--------------------------------------------------------------------------------
1 | import { TestBed, inject } from '@angular/core/testing';
2 |
3 | import { EnvService } from './env.service';
4 |
5 | describe('EnvService', () => {
6 | beforeEach(() => {
7 | TestBed.configureTestingModule({
8 | providers: [EnvService]
9 | });
10 | });
11 |
12 | it('should be created', inject([EnvService], (service: EnvService) => {
13 | expect(service).toBeTruthy();
14 | }));
15 | });
16 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-ui/clarity-seed-newfiles/src/app/env.service.ts:
--------------------------------------------------------------------------------
1 | import { Injectable } from '@angular/core';
2 |
3 | @Injectable()
4 | export class EnvService {
5 |
6 | // The values that are defined here are the default values that can
7 | // be overridden by env.js
8 |
9 | // API url
10 | public apiUrl = 'defaulturl.com';
11 |
12 | // Whether or not to enable debug mode
13 | public enableDebug = true;
14 |
15 | constructor() {
16 | }
17 |
18 | }
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-ui/clarity-seed-newfiles/src/env.js:
--------------------------------------------------------------------------------
1 | (function (window) {
2 | window.__env = window.__env || {};
3 |
4 | // API url
5 | window.__env.apiUrl = 'https://yelb-appserver-endpoint-whatever-that-is.com';
6 |
7 | // Whether or not to enable debug mode
8 | // Setting this to false will disable console output
9 | window.__env.enableDebug = true;
10 | }(this));
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-ui/clarity-seed-newfiles/src/environments/environment.custom.ts:
--------------------------------------------------------------------------------
1 | export const environment = {
2 | production: true,
3 | envName: 'custom',
4 | appserver_env: 'http://' + 'YELB_APPSERVER_ENDPOINT'
5 | };
6 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-ui/clarity-seed-newfiles/src/environments/environment.prod.ts:
--------------------------------------------------------------------------------
1 | export const environment = {
2 | production: true,
3 | envName: 'prod',
4 | appserver_env: 'http://' + window.location.host
5 | };
6 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-ui/clarity-seed-newfiles/src/environments/environment.test.ts:
--------------------------------------------------------------------------------
1 | export const environment = {
2 | production: false,
3 | envName: 'test',
4 | appserver_env: 'http://localhost:4567'
5 | };
6 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-ui/clarity-seed-newfiles/src/environments/environment.ts:
--------------------------------------------------------------------------------
1 | // The file contents for the current environment will overwrite these during build.
2 | // The build system defaults to the dev environment which uses `environment.ts`, but if you do
3 | // `ng build --env=prod` then `environment.prod.ts` will be used instead.
4 | // The list of which env maps to which file can be found in `angular-cli.json`.
5 |
6 | export const environment = {
7 | production: false,
8 | envName: 'dev',
9 | appserver_env: 'http://localhost:4567'
10 | };
11 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-ui/clarity-seed-newfiles/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | Yelb
7 |
8 |
9 |
10 |
11 |
12 | Loading...
13 |
14 |
15 |
--------------------------------------------------------------------------------
/blogs/ecs-service-connectivity/yelb/yelb-ui/clarity-seed-newfiles/src/styles.css:
--------------------------------------------------------------------------------
1 | /* You can add global styles to this file, and also import other style files */
2 |
3 |
4 | * {
5 | box-sizing: border-box;
6 | }
7 |
8 | ngx-charts-advanced-pie-chart .advanced-pie-legend .legend-items-container .legend-items .legend-item .item-value {
9 | font-size: 24px;
10 | margin-top: 0px;
11 | margin-left: 11px;
12 | overflow: inherit;
13 | }
--------------------------------------------------------------------------------
/blogs/eks-appmesh-connectivity/deployments/yaml/README.md:
--------------------------------------------------------------------------------
1 | These configurations had been tested Amazon EKS but should in theory work on any Kubernetes deployment.
2 |
3 | Some of these configurations (e.g. *alb*) is AWS specific in that it requires an ALB ingress controller.
4 |
5 | Ideally they should / could be broken into independent configurations for any given module of the app and composed properly at deployment time.
6 |
7 | The picture below shows the layout of the Kubernetes deployment (with a load balancer) on top of EKS:
8 |
9 | 
10 |
11 |
--------------------------------------------------------------------------------
/blogs/eks-appmesh-connectivity/deployments/yaml/mesh/appmesh/yelb-es-mesh.yaml:
--------------------------------------------------------------------------------
1 | apiVersion: appmesh.k8s.aws/v1beta2
2 | kind: VirtualNode
3 | metadata:
4 | name: yelb-es-node
5 | spec:
6 | awsName: yelb-es-node
7 | listeners:
8 | - portMapping:
9 | port: 6379
10 | protocol: tcp
11 | serviceDiscovery:
12 | dns:
13 | hostname: redis-server-invalid
14 |
15 |
--------------------------------------------------------------------------------
/blogs/eks-appmesh-connectivity/deployments/yaml/mesh/appmesh/yelb-rds-mesh.yaml:
--------------------------------------------------------------------------------
1 | apiVersion: appmesh.k8s.aws/v1beta2
2 | kind: VirtualNode
3 | metadata:
4 | name: yelb-rds-node
5 | spec:
6 | awsName: yelb-rds-node
7 | listeners:
8 | - portMapping:
9 | port: 5432
10 | protocol: tcp
11 | serviceDiscovery:
12 | dns:
13 | hostname: yelb-db-invalid
14 |
--------------------------------------------------------------------------------
/blogs/eks-appmesh-connectivity/images/yelb-eks-load-balancer.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/blogs/eks-appmesh-connectivity/images/yelb-eks-load-balancer.png
--------------------------------------------------------------------------------
/blogs/eks-bulkhead-pattern-circuit-breaker/.gitignore:
--------------------------------------------------------------------------------
1 | _output/
2 |
--------------------------------------------------------------------------------
/blogs/eks-bulkhead-pattern-circuit-breaker/cleanup.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -eo pipefail
4 |
5 | DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" >/dev/null && pwd)"
6 | PROJECT_NAME="bulkhead-pattern"
7 | APP_NAMESPACE=${PROJECT_NAME}
8 | APP="price-app"
9 | EXAMPLES_OUT_DIR="${DIR}/_output/"
10 |
11 | delete_ecr_repository() {
12 | aws ecr delete-repository --repository-name $PROJECT_NAME/${APP} --force
13 | }
14 |
15 | delete_kubernetes_and_mesh() {
16 | kubectl delete -f ${EXAMPLES_OUT_DIR}/base.yaml
17 | }
18 |
19 | main() {
20 | delete_ecr_repository
21 | delete_kubernetes_and_mesh
22 | }
23 |
24 | main
25 |
--------------------------------------------------------------------------------
/blogs/eks-bulkhead-pattern-circuit-breaker/price-app/.gitignore:
--------------------------------------------------------------------------------
1 | eks-bulkhead-pattern
2 |
--------------------------------------------------------------------------------
/blogs/eks-bulkhead-pattern-circuit-breaker/price-app/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM golang:1 AS builder
2 |
3 | WORKDIR /go/src/github.com/aws/aws-app-mesh-examples/price-app
4 |
5 | COPY go.mod .
6 | COPY go.sum .
7 | RUN go mod download
8 |
9 | COPY main.go .
10 | RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix nocgo -o /src/price-app .
11 |
12 | ####
13 |
14 | FROM alpine
15 | COPY --from=builder /src/price-app /usr/local/bin/price-app
16 | ENTRYPOINT price-app
17 |
--------------------------------------------------------------------------------
/blogs/eks-bulkhead-pattern-circuit-breaker/price-app/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/blog/eks-bulkhead-pattern
2 |
3 | go 1.13
4 |
5 | require (
6 | github.com/gorilla/mux v1.8.0
7 | golang.org/x/net v0.23.0
8 | )
9 |
--------------------------------------------------------------------------------
/blogs/eks-bulkhead-pattern-circuit-breaker/update.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -eo pipefail
4 |
5 | EXAMPLES_OUT_DIR="${DIR}/_output"
6 |
7 | main() {
8 | kubectl apply -f ./${EXAMPLES_OUT_DIR}/update.yaml
9 | echo "Updated successfully"
10 | }
11 |
12 | main
13 |
--------------------------------------------------------------------------------
/blogs/eks-canary-deployments-pipeline/.gitignore:
--------------------------------------------------------------------------------
1 | *.zip
--------------------------------------------------------------------------------
/blogs/eks-canary-deployments-pipeline/microservices/redis-server/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM redis:4.0.2
2 |
--------------------------------------------------------------------------------
/blogs/eks-canary-deployments-pipeline/microservices/redis-server/specfiles/deploy.json:
--------------------------------------------------------------------------------
1 | {
2 | "cluster_name": "blogpost",
3 | "microservice_name": "redis-server",
4 | "kubernetes_namespace": "yelb",
5 | "percentage_step": 25,
6 | "wait_time": 60,
7 | "failure_threshold_value": 5,
8 | "failure_threshold_time": 300
9 | }
--------------------------------------------------------------------------------
/blogs/eks-canary-deployments-pipeline/microservices/yelb-appserver/specfiles/deploy.json:
--------------------------------------------------------------------------------
1 | {
2 | "cluster_name": "blogpost",
3 | "microservice_name": "yelb-appserver",
4 | "kubernetes_namespace": "yelb",
5 | "percentage_step": 10,
6 | "wait_time": 60,
7 | "failure_threshold_value": 0,
8 | "failure_threshold_time": 300
9 | }
--------------------------------------------------------------------------------
/blogs/eks-canary-deployments-pipeline/microservices/yelb-db/specfiles/deploy.json:
--------------------------------------------------------------------------------
1 | {
2 | "cluster_name": "blogpost",
3 | "microservice_name": "yelb-db",
4 | "kubernetes_namespace": "yelb",
5 | "percentage_step": 25,
6 | "wait_time": 60,
7 | "failure_threshold_value": 5,
8 | "failure_threshold_time": 300
9 | }
--------------------------------------------------------------------------------
/blogs/eks-canary-deployments-pipeline/microservices/yelb-ui/specfiles/deploy.json:
--------------------------------------------------------------------------------
1 | {
2 | "cluster_name": "blogpost",
3 | "microservice_name": "yelb-ui",
4 | "kubernetes_namespace": "yelb",
5 | "percentage_step": 25,
6 | "wait_time": 60,
7 | "failure_threshold_value": 5,
8 | "failure_threshold_time": 300
9 | }
--------------------------------------------------------------------------------
/blogs/eks-canary-deployments-pipeline/setup/add_iam_role_to_rbac.sh:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 |
3 | # Load environment variables
4 | source ~/.bash_profile
5 |
6 | # Get the AWS Lambda role ARN
7 | STATE_MACHINE_ROLE_ARN=$(aws cloudformation describe-stacks --region $AWS_REGION --stack-name $SHARED_STACK_NAME --output json \
8 | | jq -r '.Stacks[0].Outputs[] | select(.OutputKey == "EKSAccessRole") | .OutputValue')
9 |
10 | # Add the role to Kubernetes RBAC
11 | eksctl create iamidentitymapping --region $AWS_REGION --cluster $EKS_CLUSTER_NAME --arn $STATE_MACHINE_ROLE_ARN --output json \
12 | --group system:masters --username eks_canary_stepfunctions
--------------------------------------------------------------------------------
/blogs/eks-canary-deployments-pipeline/setup/namespace_and_mesh.yml:
--------------------------------------------------------------------------------
1 | ---
2 | apiVersion: v1
3 | kind: Namespace
4 | metadata:
5 | labels:
6 | mesh: ${MESH}
7 | appmesh.k8s.aws/sidecarInjectorWebhook: enabled
8 | name: ${NAMESPACE}
9 | ---
10 | apiVersion: appmesh.k8s.aws/v1beta2
11 | kind: Mesh
12 | metadata:
13 | name: ${MESH}
14 | spec:
15 | namespaceSelector:
16 | matchLabels:
17 | mesh: ${MESH}
--------------------------------------------------------------------------------
/blogs/eks-canary-deployments-pipeline/shared_stack/lambda_functions/check_deployment_version/main.py:
--------------------------------------------------------------------------------
1 | import boto3
2 | ssm = boto3.client('ssm')
3 |
4 |
5 | def lambda_handler(event, context):
6 | try:
7 | parameter = ssm.get_parameter(Name='eks-canary-%s-version' % event.get('microservice_name'))
8 | return {"new_version": parameter['Parameter']['Version'] + 1, "current_percentage": 0}
9 | except ssm.exceptions.ParameterNotFound:
10 | return {"new_version": 1, "current_percentage": 0, "is_healthy": True}
11 |
--------------------------------------------------------------------------------
/blogs/eks-canary-deployments-pipeline/shared_stack/lambda_functions/update_deployment_version/main.py:
--------------------------------------------------------------------------------
1 | import boto3
2 | ssm = boto3.client('ssm')
3 |
4 |
5 | def lambda_handler(event, context):
6 | return ssm.put_parameter(Name='eks-canary-%s-version' % event.get('microservice_name'),
7 | Value=event.get('container_image'),
8 | Type="SecureString",
9 | Overwrite=True)
10 |
--------------------------------------------------------------------------------
/blogs/eks-multi-account-spire/.gitignore:
--------------------------------------------------------------------------------
1 | # ignore virtual node with virtual service ARN
2 | **/yelb-ui-final.yaml
3 |
4 | #ignore App mesh spec file
5 | **/app-mesh.yaml
6 |
7 | # ignore kubeconfig for frontend cluster authentication
8 | **/front_config
9 |
10 | # ignore kubeconfig for backend cluster authentication
11 | **/back_config
12 |
13 | # ignore frontend kubeconfig ConfigMap
14 | **/front_kubeconfig.yaml
15 |
16 | # ignore backend kubeconfig ConfigMap
17 | **/back_kubeconfig.yaml
18 |
19 | # ignore spire bundle
20 | **/spire-bundle.yaml
--------------------------------------------------------------------------------
/blogs/eks-multi-account-spire/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM gcr.io/spiffe-io/spire-server:1.0.1
2 | RUN apk add --update-cache python3
3 | RUN apk -Uuv add groff less python3 py-pip \
4 | && pip install awscli \
5 | && rm /var/cache/apk/*
6 | CMD []
--------------------------------------------------------------------------------
/blogs/eks-multi-account-spire/appmesh-spire-agent/Chart.yaml:
--------------------------------------------------------------------------------
1 | apiVersion: v1
2 | name: appmesh-spire-agent
3 | description: SPIRE Agent Helm chart for AppMesh mTLS support on Kubernetes
4 | version: 1.0.1
5 | appVersion: 1.0.0
6 | home: https://github.com/aws/eks-charts
7 | icon: https://raw.githubusercontent.com/aws/eks-charts/master/docs/logo/aws.png
8 | sources:
9 | - https://github.com/aws/eks-charts
10 | maintainers:
11 | - name: Apurup Chevuru
12 | url: https://github.com/achevuru
13 | keywords:
14 | - eks
15 | - appmesh
16 | - spire
17 |
18 |
--------------------------------------------------------------------------------
/blogs/eks-multi-account-spire/appmesh-spire-agent/templates/NOTES.txt:
--------------------------------------------------------------------------------
1 | SPIRE Agent installed!
--------------------------------------------------------------------------------
/blogs/eks-multi-account-spire/appmesh-spire-agent/templates/account.yaml:
--------------------------------------------------------------------------------
1 | {{- if .Values.serviceAccount.create -}}
2 | apiVersion: v1
3 | kind: ServiceAccount
4 | metadata:
5 | name: {{ include "appmesh-spire-agent.serviceAccountName" . }}
6 | namespace: {{ .Release.Namespace }}
7 | labels:
8 | {{- include "appmesh-spire-agent.labels" . | nindent 4 }}
9 | {{- with .Values.serviceAccount.annotations }}
10 | annotations:
11 | {{- toYaml . | nindent 4 }}
12 | {{- end }}
13 | {{- end -}}
--------------------------------------------------------------------------------
/blogs/eks-multi-account-spire/appmesh-spire-server/Chart.yaml:
--------------------------------------------------------------------------------
1 | apiVersion: v1
2 | name: appmesh-spire-server
3 | description: SPIRE Server Helm chart for AppMesh mTLS support on Kubernetes
4 | version: 1.0.0
5 | appVersion: 1.0.0
6 | home: https://github.com/aws/eks-charts
7 | icon: https://raw.githubusercontent.com/aws/eks-charts/master/docs/logo/aws.png
8 | sources:
9 | - https://github.com/aws/eks-charts
10 | maintainers:
11 | - name: Apurup Chevuru
12 | url: https://github.com/achevuru
13 | keywords:
14 | - eks
15 | - appmesh
16 | - spire
17 |
18 |
--------------------------------------------------------------------------------
/blogs/eks-multi-account-spire/appmesh-spire-server/templates/NOTES.txt:
--------------------------------------------------------------------------------
1 | SPIRE Server installed!
--------------------------------------------------------------------------------
/blogs/eks-multi-account-spire/appmesh-spire-server/templates/account.yaml:
--------------------------------------------------------------------------------
1 | {{- if .Values.serviceAccount.create -}}
2 | apiVersion: v1
3 | kind: ServiceAccount
4 | metadata:
5 | name: {{ include "appmesh-spire-server.serviceAccountName" . }}
6 | namespace: {{ .Release.Namespace }}
7 | labels:
8 | {{- include "appmesh-spire-server.labels" . | nindent 4 }}
9 | {{- with .Values.serviceAccount.annotations }}
10 | annotations:
11 | {{- toYaml . | nindent 4 }}
12 | {{- end }}
13 | {{- end -}}
14 |
15 |
--------------------------------------------------------------------------------
/blogs/eks-multi-account-spire/appmesh-spire-server/templates/service.yaml:
--------------------------------------------------------------------------------
1 | apiVersion: v1
2 | kind: Service
3 | metadata:
4 | name: {{ template "appmesh-spire-server.fullname" . }}
5 | spec:
6 | type: {{ .Values.service.type }}
7 | ports:
8 | - port: {{ .Values.service.port }}
9 | targetPort: {{ .Values.service.port }}
10 | protocol: TCP
11 | name: grpc
12 | selector:
13 | app.kubernetes.io/name: {{ include "appmesh-spire-server.name" . }}
--------------------------------------------------------------------------------
/blogs/eks-multi-account-spire/appmesh-spire-server/templates/spire-bundle-cfg.yaml:
--------------------------------------------------------------------------------
1 | apiVersion: v1
2 | kind: ConfigMap
3 | metadata:
4 | name: spire-bundle
5 | namespace: spire
--------------------------------------------------------------------------------
/blogs/eks-multi-account-spire/helper-scripts/replace_vs_arn.sh:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 | set -e
3 |
4 | kubectl config use-context $FRONT_CXT
5 |
6 | echo "Retrieving the ARN of the yelb-appserver virtual service from the backend cluster..."
7 | export VS_ARN=$(kubectl --context $BACK_CXT -n yelb get virtualservice yelb-appserver -o json \
8 | | jq -r '.status.virtualServiceARN')
9 |
10 | echo "Creating an update for the yelb-ui virtual node (yelb-ui-final.yaml)..."
11 | ( echo "cat < mesh/yelb-ui-final.yaml";
12 | cat mesh/yelb-ui.yaml;
13 | echo "EOF";
14 | ) > temp.sh
15 | chmod +x temp.sh
16 | ./temp.sh
17 | rm temp.sh
18 |
--------------------------------------------------------------------------------
/blogs/eks-multi-account-spire/images/multi-account-mtls-arch.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/blogs/eks-multi-account-spire/images/multi-account-mtls-arch.png
--------------------------------------------------------------------------------
/blogs/eks-multi-account-spire/images/yelb-ui.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/blogs/eks-multi-account-spire/images/yelb-ui.png
--------------------------------------------------------------------------------
/blogs/envoy-cw-dashboards/README.md:
--------------------------------------------------------------------------------
1 | # Sending Envoy metrics from AWS App Mesh to Amazon CloudWatch
2 |
3 | This code snippet is to create Amazon CloudWatch Dashboards with App Mesh/Envoy Stats. These code snippets will be referenced in our Blog Post link given below.
4 |
5 | Blog Post Link : https://aws.amazon.com/blogs/containers/sending-envoy-metrics-from-aws-app-mesh-to-amazon-cloudwatch/
--------------------------------------------------------------------------------
/blogs/http-headers-and-priority/appmeshview.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/blogs/http-headers-and-priority/appmeshview.jpg
--------------------------------------------------------------------------------
/blogs/http-headers-and-priority/colorappservicesview.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/blogs/http-headers-and-priority/colorappservicesview.jpg
--------------------------------------------------------------------------------
/blogs/http-retry-policy/appmeshview.jpeg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/blogs/http-retry-policy/appmeshview.jpeg
--------------------------------------------------------------------------------
/blogs/http-retry-policy/colorappserviceview.jpeg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/blogs/http-retry-policy/colorappserviceview.jpeg
--------------------------------------------------------------------------------
/blogs/http-retry-policy/retries.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/blogs/http-retry-policy/retries.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/ecs/xray-container.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "xray-daemon",
3 | "image": "public.ecr.aws/xray/aws-xray-daemon",
4 | "user": "1337",
5 | "essential": true,
6 | "cpu": 32,
7 | "memoryReservation": 256,
8 | "portMappings": [
9 | {
10 | "hostPort": 2000,
11 | "containerPort": 2000,
12 | "protocol": "udp"
13 | }
14 | ],
15 | "logConfiguration": {
16 | "logDriver": "awslogs",
17 | "options": {
18 | "awslogs-group": $ECS_SERVICE_LOG_GROUP,
19 | "awslogs-region": $AWS_REGION,
20 | "awslogs-stream-prefix": $AWS_LOG_STREAM_PREFIX
21 | }
22 | }
23 | }
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-color-app-demo-1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-color-app-demo-1.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-color-app-demo-2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-color-app-demo-2.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-color-app-demo-3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-color-app-demo-3.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-color-app-detail.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-color-app-detail.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-colorteller-route-1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-colorteller-route-1.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-colorteller-route-2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-colorteller-route-2.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-colorteller-route-3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-colorteller-route-3.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-colorteller-route-4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-colorteller-route-4.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-console-cloudformation-demo-stacks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-console-cloudformation-demo-stacks.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-weighted-routes.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-weighted-routes.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-xray-create-group-1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-xray-create-group-1.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-xray-create-group-2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-xray-create-group-2.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-xray-service-map-1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-xray-service-map-1.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-xray-service-map-2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-xray-service-map-2.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-xray-tracing-1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-xray-tracing-1.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/img/appmesh-xray-tracing-2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/colorapp/img/appmesh-xray-tracing-2.png
--------------------------------------------------------------------------------
/examples/apps/colorapp/kubernetes/.gitignore:
--------------------------------------------------------------------------------
1 | colorapp.yaml
2 |
--------------------------------------------------------------------------------
/examples/apps/colorapp/servicemesh/.region-config.sh:
--------------------------------------------------------------------------------
1 |
2 | regions=$(aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" --output text \
3 | ssm get-parameters-by-path \
4 | --path /aws/service/global-infrastructure/services/appmesh/regions \
5 | --query 'Parameters[].Value')
6 |
7 | # convert tab-delimited response into array
8 | SUPPORTED_REGIONS=($(echo $regions | tr '\t' ' '))
9 |
10 | DEFAULT_REGION=us-west-2
11 |
12 |
--------------------------------------------------------------------------------
/examples/apps/colorapp/servicemesh/appmesh-colorapp.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-appmesh-colorapp" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/appmesh-colorapp.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | ServicesDomain="${SERVICES_DOMAIN}" \
15 | AppMeshMeshName="${MESH_NAME}"
16 |
--------------------------------------------------------------------------------
/examples/apps/colorapp/servicemesh/config/update_routes/colorteller-route-black-100.json:
--------------------------------------------------------------------------------
1 | {
2 | "routeName": "colorteller-route",
3 | "spec": {
4 | "httpRoute": {
5 | "action": {
6 | "weightedTargets": [
7 | {
8 | "virtualNode": "colorteller-black-vn",
9 | "weight": 1
10 | }
11 | ]
12 | },
13 | "match": {
14 | "prefix": "/"
15 | }
16 | }
17 | },
18 | "virtualRouterName": "colorteller-vr"
19 | }
20 |
--------------------------------------------------------------------------------
/examples/apps/colorapp/servicemesh/config/update_routes/colorteller-route-blue-100.json:
--------------------------------------------------------------------------------
1 | {
2 | "routeName": "colorteller-route",
3 | "spec": {
4 | "httpRoute": {
5 | "action": {
6 | "weightedTargets": [
7 | {
8 | "virtualNode": "colorteller-blue-vn",
9 | "weight": 1
10 | }
11 | ]
12 | },
13 | "match": {
14 | "prefix": "/"
15 | }
16 | }
17 | },
18 | "virtualRouterName": "colorteller-vr"
19 | }
20 |
--------------------------------------------------------------------------------
/examples/apps/colorapp/servicemesh/config/update_routes/colorteller-route-red-100.json:
--------------------------------------------------------------------------------
1 | {
2 | "routeName": "colorteller-route",
3 | "spec": {
4 | "httpRoute": {
5 | "action": {
6 | "weightedTargets": [
7 | {
8 | "virtualNode": "colorteller-red-vn",
9 | "weight": 1
10 | }
11 | ]
12 | },
13 | "match": {
14 | "prefix": "/"
15 | }
16 | }
17 | },
18 | "virtualRouterName": "colorteller-vr"
19 | }
20 |
--------------------------------------------------------------------------------
/examples/apps/colorapp/src/colorteller/.gitignore:
--------------------------------------------------------------------------------
1 | teller
2 |
--------------------------------------------------------------------------------
/examples/apps/colorapp/src/colorteller/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/colorapp/teller
2 |
3 | go 1.12
4 |
5 | require (
6 | github.com/DATA-DOG/go-sqlmock v1.3.3 // indirect
7 | github.com/aws/aws-sdk-go v1.44.209 // indirect
8 | github.com/aws/aws-xray-sdk-go v0.9.4
9 | github.com/cihub/seelog v0.0.0-20151216151435-d2c6e5aa9fbf // indirect
10 | github.com/kr/pretty v0.1.0 // indirect
11 | github.com/stretchr/testify v1.8.1 // indirect
12 | golang.org/x/net v0.23.0 // indirect
13 | gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 // indirect
14 | gopkg.in/yaml.v2 v2.4.0 // indirect
15 | )
16 |
--------------------------------------------------------------------------------
/examples/apps/colorapp/src/gateway/.gitignore:
--------------------------------------------------------------------------------
1 | gateway
2 |
--------------------------------------------------------------------------------
/examples/apps/colorapp/src/gateway/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/colorapp/gateway
2 |
3 | go 1.12
4 |
5 | require (
6 | github.com/DATA-DOG/go-sqlmock v1.3.3 // indirect
7 | github.com/aws/aws-sdk-go v1.44.209 // indirect
8 | github.com/aws/aws-xray-sdk-go v0.9.4
9 | github.com/cihub/seelog v0.0.0-20151216151435-d2c6e5aa9fbf // indirect
10 | github.com/kr/pretty v0.1.0 // indirect
11 | github.com/pkg/errors v0.9.1
12 | github.com/stretchr/testify v1.8.1 // indirect
13 | golang.org/x/net v0.23.0 // indirect
14 | gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 // indirect
15 | gopkg.in/yaml.v2 v2.4.0 // indirect
16 | )
17 |
--------------------------------------------------------------------------------
/examples/apps/djapp/img/125-v1-no-mesh.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/djapp/img/125-v1-no-mesh.png
--------------------------------------------------------------------------------
/examples/apps/djapp/img/155-v2-with-mesh-and-cp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/examples/apps/djapp/img/155-v2-with-mesh-and-cp.png
--------------------------------------------------------------------------------
/examples/apps/djapp/legacy/1_create_the_initial_architecture/1_prod_ns.yaml:
--------------------------------------------------------------------------------
1 | apiVersion: v1
2 | kind: Namespace
3 | metadata:
4 | name: prod
5 |
--------------------------------------------------------------------------------
/examples/apps/djapp/legacy/2_create_injector/appmesh-ns.yaml:
--------------------------------------------------------------------------------
1 | ---
2 | apiVersion: v1
3 | kind: Namespace
4 | metadata:
5 | name: appmesh-inject
6 |
--------------------------------------------------------------------------------
/examples/apps/djapp/legacy/2_create_injector/create.sh:
--------------------------------------------------------------------------------
1 |
2 |
3 | kubectl apply -f appmesh-ns.yaml
4 | ./gen-cert.sh
5 | echo
6 | ./ca-bundle.sh
7 | echo
8 | kubectl apply -f inject.yaml
9 | echo
10 | echo Waiting for pods to come up...
11 | sleep 15
12 | echo
13 | echo App Inject Pods and Services After Install:
14 | echo
15 | kubectl get svc -nappmesh-inject
16 | kubectl get pods -nappmesh-inject
17 |
--------------------------------------------------------------------------------
/examples/apps/djapp/legacy/2_create_injector/delete.sh:
--------------------------------------------------------------------------------
1 | echo App Inject Pods and Services Before Uninstall:
2 | echo
3 | kubectl get svc -nappmesh-inject
4 | kubectl get pods -nappmesh-inject
5 | echo
6 | echo Uninstalling...
7 | echo
8 | kubectl delete deployment aws-app-mesh-inject -nappmesh-inject
9 | kubectl delete -f inject.yaml -nappmesh-inject
10 | kubectl delete -f appmesh-ns.yaml
11 | echo
12 | echo App Inject Pods and Services After Uninstall:
13 | echo
14 | kubectl get svc -nappmesh-inject
15 | kubectl get pods -nappmesh-inject
16 |
--------------------------------------------------------------------------------
/examples/apps/djapp/legacy/4_create_initial_mesh_components/mesh.yaml:
--------------------------------------------------------------------------------
1 | apiVersion: appmesh.k8s.aws/v1beta1
2 | kind: Mesh
3 | metadata:
4 | name: dj-app
5 | namespace: prod
6 | spec:
7 | cloudMapNamespaceName: dj-app
8 | serviceDiscoveryType: dns
9 |
--------------------------------------------------------------------------------
/examples/apps/djapp/legacy/4_create_initial_mesh_components/metal_and_jazz_placeholder_services.yaml:
--------------------------------------------------------------------------------
1 | apiVersion: v1
2 | kind: Service
3 | metadata:
4 | name: jazz
5 | namespace: prod
6 | labels:
7 | app: jazz
8 | spec:
9 | ports:
10 | - port: 9080
11 | name: http
12 | ---
13 | apiVersion: v1
14 | kind: Service
15 | metadata:
16 | name: metal
17 | namespace: prod
18 | labels:
19 | app: metal
20 | spec:
21 | ports:
22 | - port: 9080
23 | name: http
24 |
--------------------------------------------------------------------------------
/examples/apps/djapp/legacy/5_canary/jazz_service_update.yaml:
--------------------------------------------------------------------------------
1 | apiVersion: appmesh.k8s.aws/v1beta1
2 | kind: VirtualService
3 | metadata:
4 | name: jazz.prod.svc.cluster.local
5 | namespace: prod
6 | spec:
7 | meshName: dj-app
8 | virtualRouter:
9 | name: jazz-router
10 | routes:
11 | - name: jazz-route
12 | http:
13 | match:
14 | prefix: /
15 | action:
16 | weightedTargets:
17 | - virtualNodeName: jazz-v1
18 | weight: 90
19 | - virtualNodeName: jazz-v2
20 | weight: 10
21 |
--------------------------------------------------------------------------------
/examples/apps/djapp/legacy/5_canary/metal_service_update.yaml:
--------------------------------------------------------------------------------
1 | apiVersion: appmesh.k8s.aws/v1beta1
2 | kind: VirtualService
3 | metadata:
4 | name: metal.prod.svc.cluster.local
5 | namespace: prod
6 | spec:
7 | meshName: dj-app
8 | virtualRouter:
9 | name: metal-router
10 | routes:
11 | - name: metal-route
12 | http:
13 | match:
14 | prefix: /
15 | action:
16 | weightedTargets:
17 | - virtualNodeName: metal-v1
18 | weight: 50
19 | - virtualNodeName: metal-v2
20 | weight: 50
21 |
--------------------------------------------------------------------------------
/examples/apps/djapp/legacy/awscli.yaml:
--------------------------------------------------------------------------------
1 | apiVersion: batch/v1
2 | kind: Job
3 | metadata:
4 | name: awscli
5 | spec:
6 | template:
7 | spec:
8 | containers:
9 | - name: awscli
10 | image: 672518094988.dkr.ecr.us-west-2.amazonaws.com/awscli:v9
11 | imagePullPolicy: Always
12 | command: ["aws","appmesh","list-meshes","--region","us-west-2"]
13 | restartPolicy: Never
14 |
--------------------------------------------------------------------------------
/examples/apps/djapp/legacy/ranCon.sh:
--------------------------------------------------------------------------------
1 | target=$1
2 |
3 | echo "Execing into pod and curling http://$target.prod.svc.cluster.local:9080"
4 |
5 |
6 | thepod=$(kubectl get pods -l app=dj -o json -nprod | jq .items[0].metadata.name | sed 's/"//g')
7 | kubectl exec $thepod -nprod -t -- bash -c "while [ 1 ]; do curl -s http://{$target}.prod.svc.cluster.local:9080;echo; done"
8 |
--------------------------------------------------------------------------------
/examples/apps/voteapp/README.md:
--------------------------------------------------------------------------------
1 | # Vote App
2 |
3 | Vote App is a simple but complete cloud native application to demonstrate
4 | microservices running on AWS with a service mesh (AWS App Mesh).
5 |
6 | GitHub repo: [github.com/aws-samples/voteapp](https://github.com/aws-samples/voteapp).
7 |
--------------------------------------------------------------------------------
/examples/infrastructure/appmesh-mesh.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-appmesh-mesh" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/appmesh-mesh.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | AppMeshMeshName="${MESH_NAME}"
15 |
--------------------------------------------------------------------------------
/examples/infrastructure/appmesh-mesh.yaml:
--------------------------------------------------------------------------------
1 | ---
2 | Parameters:
3 |
4 | EnvironmentName:
5 | Description: An environment name that will be prefixed to resource names
6 | Type: String
7 |
8 | AppMeshMeshName:
9 | Type: String
10 | Description: Name of mesh
11 |
12 | Resources:
13 |
14 | Mesh:
15 | Type: AWS::AppMesh::Mesh
16 | Properties:
17 | MeshName: !Ref AppMeshMeshName
18 |
19 | Outputs:
20 |
21 | Mesh:
22 | Description: A reference to the AppMesh Mesh
23 | Value: !Ref Mesh
24 | Export:
25 | Name: !Sub "${EnvironmentName}:Mesh"
26 |
--------------------------------------------------------------------------------
/examples/infrastructure/ecs-cluster.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecs-cluster" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecs-cluster.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | KeyName="${KEY_PAIR_NAME}" \
15 | ECSServicesDomain="${SERVICES_DOMAIN}" \
16 | ClusterSize="${CLUSTER_SIZE:-5}"
17 |
--------------------------------------------------------------------------------
/examples/infrastructure/eks-cluster.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-eks-cluster" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/eks-cluster.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | KeyName="${KEY_PAIR_NAME}"
--------------------------------------------------------------------------------
/examples/infrastructure/vpc.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-vpc" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/vpc.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/common/tools/vegeta-trafficgen/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM alpine:3.10.1
2 |
3 | ENV VEGETA_VERSION 12.8.4
4 |
5 | RUN set -ex \
6 | && apk add --no-cache ca-certificates jq \
7 | && apk add --no-cache --virtual .build-deps \
8 | openssl \
9 | && wget -q "https://github.com/tsenart/vegeta/releases/download/v${VEGETA_VERSION}/vegeta_${VEGETA_VERSION}_linux_amd64.tar.gz" -O /tmp/vegeta.tar.gz \
10 | && cd bin \
11 | && tar xzf /tmp/vegeta.tar.gz \
12 | && rm /tmp/vegeta.tar.gz \
13 | && apk del .build-deps
14 |
15 | RUN apk --no-cache add curl
16 | RUN apk --no-cache add jq
17 |
18 | CMD [ "/bin/vegeta", "-help" ]
19 |
--------------------------------------------------------------------------------
/walkthroughs/common/tools/vegeta-trafficgen/build.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" >/dev/null && pwd)"
4 | ECR_URL=$1
5 |
6 | build_vegeta() {
7 | aws ecr describe-repositories --repository-name appmesh/vegeta-trafficgen >/dev/null 2>&1 || aws ecr create-repository --repository-name appmesh/vegeta-trafficgen >/dev/null
8 | docker build -t ${ECR_URL}/appmesh/vegeta-trafficgen ${DIR}/.
9 | docker push ${ECR_URL}/appmesh/vegeta-trafficgen
10 | }
11 |
12 | build_vegeta
13 |
--------------------------------------------------------------------------------
/walkthroughs/eks-app-mesh-cross-account-acm/mesh/ca_config.txt:
--------------------------------------------------------------------------------
1 | {
2 | "KeyAlgorithm":"RSA_2048",
3 | "SigningAlgorithm":"SHA256WITHRSA",
4 | "Subject":{
5 | "Country":"US",
6 | "Organization":"Example Corp",
7 | "OrganizationalUnit":"Sales",
8 | "State":"WA",
9 | "Locality":"Seattle",
10 | "CommonName":"www.example.com"
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/walkthroughs/eks-app-mesh-cross-account-acm/mesh/create_mesh.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | MESH_OWNER=$(aws --profile frontend sts get-caller-identity | jq -r .Account)
4 |
5 | cat > /tmp/app-mesh.yml <<-EKS_CONF
6 | apiVersion: appmesh.k8s.aws/v1beta2
7 | kind: Mesh
8 | metadata:
9 | name: am-multi-account-mesh
10 | spec:
11 | meshOwner: "$MESH_OWNER"
12 | namespaceSelector:
13 | matchLabels:
14 | mesh: am-multi-account-mesh
15 | EKS_CONF
16 |
17 | kubectl apply -f /tmp/app-mesh.yml
18 |
--------------------------------------------------------------------------------
/walkthroughs/eks-app-mesh-cross-account-acm/mesh/revoke_config.txt:
--------------------------------------------------------------------------------
1 | {
2 | "CrlConfiguration":{
3 | "Enabled":false,
4 | "ExpirationInDays":7,
5 | "CustomCname":"some_name.crl",
6 | "S3BucketName":"your-bucket-name"
7 | }
8 | }
9 |
--------------------------------------------------------------------------------
/walkthroughs/eks-app-mesh-cross-account-acm/shared_resources/shared_mesh.yaml:
--------------------------------------------------------------------------------
1 | Parameters:
2 | ProjectName:
3 | Type: String
4 | Description: Project name to link stacks
5 | Default: am-multi-account
6 | BackendAccountId:
7 | Type: String
8 | Description: Account Id to share resources with
9 |
10 | Resources:
11 | MeshShare:
12 | Type: AWS::RAM::ResourceShare
13 | Properties:
14 | AllowExternalPrincipals: true
15 | Name: mesh-share
16 | Principals:
17 | - !Ref BackendAccountId
18 | ResourceArns:
19 | - !Sub 'arn:aws:appmesh:${AWS::Region}:${AWS::AccountId}:mesh/${ProjectName}-mesh'
--------------------------------------------------------------------------------
/walkthroughs/eks-app-mesh-multi-account/mesh/create_mesh.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | MESH_OWNER=$(aws --profile frontend sts get-caller-identity | jq -r .Account)
4 |
5 | cat > /tmp/app-mesh.yml <<-EKS_CONF
6 | apiVersion: appmesh.k8s.aws/v1beta2
7 | kind: Mesh
8 | metadata:
9 | name: am-multi-account-mesh
10 | spec:
11 | meshOwner: "$MESH_OWNER"
12 | namespaceSelector:
13 | matchLabels:
14 | mesh: am-multi-account-mesh
15 | EKS_CONF
16 |
17 | kubectl apply -f /tmp/app-mesh.yml
18 |
--------------------------------------------------------------------------------
/walkthroughs/eks-app-mesh-multi-account/shared_resources/shared_mesh.yaml:
--------------------------------------------------------------------------------
1 | Parameters:
2 | ProjectName:
3 | Type: String
4 | Description: Project name to link stacks
5 | Default: am-multi-account
6 | BackendAccountId:
7 | Type: String
8 | Description: Account Id to share resources with
9 |
10 | Resources:
11 | MeshShare:
12 | Type: AWS::RAM::ResourceShare
13 | Properties:
14 | AllowExternalPrincipals: true
15 | Name: mesh-share
16 | Principals:
17 | - !Ref BackendAccountId
18 | ResourceArns:
19 | - !Sub 'arn:aws:appmesh:${AWS::Region}:${AWS::AccountId}:mesh/${ProjectName}-mesh'
--------------------------------------------------------------------------------
/walkthroughs/eks-getting-started/.gitignore:
--------------------------------------------------------------------------------
1 | cfn-output.json
2 |
--------------------------------------------------------------------------------
/walkthroughs/eks-getting-started/yelb-appserver-v2/Gemfile:
--------------------------------------------------------------------------------
1 | source 'https://rubygems.org'
2 | gem 'pg'
3 | gem 'redis'
4 |
--------------------------------------------------------------------------------
/walkthroughs/eks-getting-started/yelb-appserver-v2/modules/getstats.rb:
--------------------------------------------------------------------------------
1 | require_relative 'hostname'
2 | require_relative 'pageviews'
3 |
4 | def getstats()
5 | hostname = hostname()
6 | pageviews = pageviews()
7 | stats = '{"hostname": "' + hostname + '"' + ", " + '"pageviews":' + pageviews + "}"
8 | return stats
9 | end
--------------------------------------------------------------------------------
/walkthroughs/eks-getting-started/yelb-appserver-v2/modules/getvotes.rb:
--------------------------------------------------------------------------------
1 | require_relative 'restaurantsdbread'
2 | require_relative 'restaurantsdbupdate'
3 |
4 | def getvotes()
5 | outback = restaurantsdbread("outback")
6 | ihop = restaurantsdbread("ihop")
7 | bucadibeppo = restaurantsdbread("bucadibeppo")
8 | chipotle = restaurantsdbread("chipotle")
9 | votes = '[{"name": "outback", "value": ' + outback + '},' + '{"name": "bucadibeppo", "value": ' + bucadibeppo + '},' + '{"name": "ihop", "value": ' + ihop + '}, ' + '{"name": "chipotle", "value": ' + chipotle + '}]'
10 | return votes
11 | end
--------------------------------------------------------------------------------
/walkthroughs/eks-getting-started/yelb-appserver-v2/modules/hostname.rb:
--------------------------------------------------------------------------------
1 | require 'socket'
2 |
3 | def hostname()
4 | hostnamedata = 'ApplicationVersion2'
5 | return hostnamedata
6 | end
--------------------------------------------------------------------------------
/walkthroughs/eks-getting-started/yelb-appserver-v2/modules/restaurant.rb:
--------------------------------------------------------------------------------
1 | require_relative 'restaurantsdbread'
2 | require_relative 'restaurantsdbupdate'
3 |
4 | def restaurantsupdate(restaurant)
5 | restaurantsdbupdate(restaurant)
6 | restaurantcount = restaurantsdbread(restaurant)
7 | return restaurantcount
8 | end
--------------------------------------------------------------------------------
/walkthroughs/eks-getting-started/yelb-appserver-v2/startup.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | # when the variable is populated a search domain entry is added to resolv.conf at startup
4 | # this is needed for the ECS service discovery given the app works by calling host names and not FQDNs
5 | # a search domain can't be added to the container when using the awsvpc mode
6 | # and the awsvpc mode is needed for A records (bridge only supports SRV records)
7 | if [ $SEARCH_DOMAIN ]; then echo "search ${SEARCH_DOMAIN}" >> /etc/resolv.conf; fi
8 |
9 | ruby /app/yelb-appserver.rb -o 0.0.0.0
--------------------------------------------------------------------------------
/walkthroughs/eks/README.md:
--------------------------------------------------------------------------------
1 | # Walkthrough: App Mesh with EKS
2 |
3 | In this walkthrough we will be setting up AWS App Mesh with Amazon Elastic Container Service for Kubernetes (EKS) and demonstrate how to carry out day 2 ops tasks such as logging, monitoring, and distributed tracing:
4 |
5 | * [Base deployment](base.md)
6 | * Integrations:
7 | * Observability:
8 | * [CloudWatch](o11y-cloudwatch.md)
9 | * [Grafana](o11y-grafana.md)
10 | * [Prometheus](o11y-prometheus.md)
11 | * [X-Ray](o11y-xray.md)
12 | * [Jaeger](o11y-jaeger.md)
13 | * Sidecar configuration:
14 | * [volumeMounts&sidecarEnv](volumeMounts-sidecarEnv.md)
15 |
--------------------------------------------------------------------------------
/walkthroughs/eks/appmesh-log-0.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/eks/appmesh-log-0.png
--------------------------------------------------------------------------------
/walkthroughs/eks/appmesh-log-1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/eks/appmesh-log-1.png
--------------------------------------------------------------------------------
/walkthroughs/eks/cloudwatch.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/eks/cloudwatch.png
--------------------------------------------------------------------------------
/walkthroughs/eks/grafana-dashboard-0.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/eks/grafana-dashboard-0.png
--------------------------------------------------------------------------------
/walkthroughs/eks/grafana-dashboard-1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/eks/grafana-dashboard-1.png
--------------------------------------------------------------------------------
/walkthroughs/eks/jaeger-traces-0.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/eks/jaeger-traces-0.png
--------------------------------------------------------------------------------
/walkthroughs/eks/jaeger-traces-1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/eks/jaeger-traces-1.png
--------------------------------------------------------------------------------
/walkthroughs/eks/logs-policy.json:
--------------------------------------------------------------------------------
1 | {
2 | "Version": "2012-10-17",
3 | "Statement": [
4 | {
5 | "Action": [
6 | "logs:DescribeLogGroups",
7 | "logs:DescribeLogStreams",
8 | "logs:CreateLogGroup",
9 | "logs:CreateLogStream",
10 | "logs:PutLogEvents"
11 | ],
12 | "Resource": "*",
13 | "Effect": "Allow"
14 | }
15 | ]
16 | }
--------------------------------------------------------------------------------
/walkthroughs/eks/prometheus-metrics-0.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/eks/prometheus-metrics-0.png
--------------------------------------------------------------------------------
/walkthroughs/eks/xray-service-map.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/eks/xray-service-map.png
--------------------------------------------------------------------------------
/walkthroughs/eks/xray-traces-0.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/eks/xray-traces-0.png
--------------------------------------------------------------------------------
/walkthroughs/eks/xray-traces-1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/eks/xray-traces-1.png
--------------------------------------------------------------------------------
/walkthroughs/fargate/appmesh-colorapp.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-appmesh-colorapp" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/appmesh-colorapp.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | ServicesDomain="${SERVICES_DOMAIN}" \
15 | AppMeshMeshName="${MESH_NAME}"
16 |
--------------------------------------------------------------------------------
/walkthroughs/fargate/img/appmesh-fargate-colorapp-demo-1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/fargate/img/appmesh-fargate-colorapp-demo-1.png
--------------------------------------------------------------------------------
/walkthroughs/fargate/img/appmesh-fargate-colorapp-demo-2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/fargate/img/appmesh-fargate-colorapp-demo-2.png
--------------------------------------------------------------------------------
/walkthroughs/fargate/img/appmesh-fargate-colorapp-demo-3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/fargate/img/appmesh-fargate-colorapp-demo-3.png
--------------------------------------------------------------------------------
/walkthroughs/fargate/img/appmesh-fargate-routing-blue-green-1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/fargate/img/appmesh-fargate-routing-blue-green-1.png
--------------------------------------------------------------------------------
/walkthroughs/fargate/img/appmesh-fargate-routing-blue-green-2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/fargate/img/appmesh-fargate-routing-blue-green-2.png
--------------------------------------------------------------------------------
/walkthroughs/fargate/img/appmesh-fargate-xray-blue-green.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/fargate/img/appmesh-fargate-xray-blue-green.png
--------------------------------------------------------------------------------
/walkthroughs/fargate/xray-container.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "xray-daemon",
3 | "image": "public.ecr.aws/xray/aws-xray-daemon",
4 | "user": "1337",
5 | "essential": true,
6 | "cpu": 32,
7 | "memoryReservation": 256,
8 | "portMappings": [
9 | {
10 | "hostPort": 2000,
11 | "containerPort": 2000,
12 | "protocol": "udp"
13 | }
14 | ],
15 | "logConfiguration": {
16 | "logDriver": "awslogs",
17 | "options": {
18 | "awslogs-group": $ECS_SERVICE_LOG_GROUP,
19 | "awslogs-region": $AWS_REGION,
20 | "awslogs-stream-prefix": $AWS_LOG_STREAM_PREFIX_ENVOY
21 | }
22 | }
23 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-alb/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 |
3 | COPY requirements.txt ./
4 |
5 | RUN yum update -y && \
6 | yum install -y python3 && \
7 | pip3 install --no-cache-dir -r requirements.txt && \
8 | yum clean all && \
9 | rm -rf /var/cache/yum
10 |
11 | WORKDIR /usr/src/app
12 |
13 | COPY . .
14 |
15 | ENV PORT 8080
16 |
17 | CMD ["gunicorn", "app:app", "--config=config.py"]
--------------------------------------------------------------------------------
/walkthroughs/howto-alb/colorapp/config.py:
--------------------------------------------------------------------------------
1 | from os import environ as env
2 | import multiprocessing
3 |
4 | PORT = int(env.get("PORT", 8080))
5 | DEBUG_MODE = int(env.get("DEBUG_MODE", 0))
6 | XRAY_APP_NAME = env.get('XRAY_APP_NAME', 'feapp')
7 | COLOR = env.get('COLOR', 'n/a')
8 |
9 | # Gunicorn config
10 | bind = ":" + str(PORT)
11 | workers = multiprocessing.cpu_count() * 2 + 1
12 | threads = 2 * multiprocessing.cpu_count()
--------------------------------------------------------------------------------
/walkthroughs/howto-alb/colorapp/requirements.txt:
--------------------------------------------------------------------------------
1 | flask
2 | aws-xray-sdk
3 | urllib3<2
4 | gunicorn==22.0.0
5 |
--------------------------------------------------------------------------------
/walkthroughs/howto-alb/feapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 |
3 | COPY requirements.txt ./
4 |
5 | RUN yum update -y && \
6 | yum install -y python3 && \
7 | pip3 install --no-cache-dir -r requirements.txt && \
8 | yum clean all && \
9 | rm -rf /var/cache/yum
10 |
11 | WORKDIR /usr/src/app
12 |
13 | COPY . .
14 |
15 | ENV PORT 8080
16 |
17 | CMD ["gunicorn", "app:app", "--config=config.py"]
--------------------------------------------------------------------------------
/walkthroughs/howto-alb/feapp/config.py:
--------------------------------------------------------------------------------
1 | from os import environ as env
2 | import multiprocessing
3 |
4 | PORT = int(env.get("PORT", 8080))
5 | DEBUG_MODE = int(env.get("DEBUG_MODE", 0))
6 | XRAY_APP_NAME = env.get('XRAY_APP_NAME', 'feapp')
7 | COLOR_HOST = env.get('COLOR_HOST')
8 |
9 | # Gunicorn config
10 | bind = ":" + str(PORT)
11 | workers = multiprocessing.cpu_count() * 2 + 1
12 | threads = 2 * multiprocessing.cpu_count()
--------------------------------------------------------------------------------
/walkthroughs/howto-alb/feapp/requirements.txt:
--------------------------------------------------------------------------------
1 | flask
2 | requests
3 | aws-xray-sdk
4 | urllib3<2
5 | gunicorn==22.0.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-alb/howto-alb.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-alb/howto-alb.png
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/howto-circuit-breakers.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-circuit-breakers/howto-circuit-breakers.png
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/infrastructure/ecr-repositories.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecr-repositories" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecr-repositories.yaml" \
12 | --parameter-overrides \
13 | ColorTellerImageName="${COLOR_TELLER_IMAGE_NAME}" \
14 | WrkToolImageName="${WRK_TOOL_IMAGE_NAME}"
15 |
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/infrastructure/ecr-repositories.yaml:
--------------------------------------------------------------------------------
1 | Parameters:
2 |
3 | ColorTellerImageName:
4 | Description: The name for the color teller image
5 | Type: String
6 |
7 | WrkToolImageName:
8 | Description: The name for the wrk2 image
9 | Type: String
10 |
11 | Resources:
12 |
13 | ColorTellerRepository:
14 | Type: AWS::ECR::Repository
15 | Properties:
16 | RepositoryName: !Ref ColorTellerImageName
17 |
18 | WrkToolRepository:
19 | Type: AWS::ECR::Repository
20 | Properties:
21 | RepositoryName: !Ref WrkToolImageName
22 |
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/infrastructure/ecs-cluster.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecs-cluster" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecs-cluster.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | KeyName="${KEY_PAIR_NAME}" \
15 | ECSServicesDomain="${SERVICES_DOMAIN}"
16 |
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/infrastructure/vpc.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-vpc" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/vpc.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/mesh/colorgateway-route-1.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute" : {
4 | "match" : {
5 | "prefix" : "/color1"
6 | },
7 | "action" : {
8 | "target" : {
9 | "virtualService": {
10 | "virtualServiceName": $VIRTUALSERVICE_NAME
11 | }
12 | }
13 | }
14 | }
15 | }
16 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/mesh/colorgateway-route-2.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute" : {
4 | "match" : {
5 | "prefix" : "/color2"
6 | },
7 | "action" : {
8 | "target" : {
9 | "virtualService": {
10 | "virtualServiceName": $VIRTUALSERVICE_NAME
11 | }
12 | }
13 | }
14 | }
15 | }
16 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/mesh/colorgateway-vg-update.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 9080,
7 | "protocol": "http"
8 | },
9 | "connectionPool": {
10 | "http": {
11 | "maxConnections": 100,
12 | "maxPendingRequests": 10000
13 | }
14 | }
15 | }
16 | ]
17 | }
18 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/mesh/colorgateway-vg.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 9080,
7 | "protocol": "http"
8 | }
9 | }
10 | ]
11 | }
12 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/mesh/colorteller-route-1.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute": {
4 | "action": {
5 | "weightedTargets": [
6 | {
7 | "virtualNode": "colorteller-white-vn",
8 | "weight": 1
9 | }
10 | ]
11 | },
12 | "match": {
13 | "prefix": "/tell"
14 | }
15 | }
16 | }
17 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/mesh/colorteller-route-2.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "http2Route": {
4 | "action": {
5 | "weightedTargets": [
6 | {
7 | "virtualNode": "colorteller-black-vn",
8 | "weight": 1
9 | }
10 | ]
11 | },
12 | "match": {
13 | "prefix": "/tell"
14 | }
15 | }
16 | }
17 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/mesh/colorteller-vr-1.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 9080,
7 | "protocol": "http"
8 | }
9 | }
10 | ]
11 | }
12 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/mesh/colorteller-vr-2.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 9080,
7 | "protocol": "http2"
8 | }
9 | }
10 | ]
11 | }
12 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/mesh/colorteller-vs-1.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "provider": {
4 | "virtualRouter": {
5 | "virtualRouterName": "colorteller-vr-1"
6 | }
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/mesh/colorteller-vs-2.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "provider": {
4 | "virtualRouter": {
5 | "virtualRouterName": "colorteller-vr-2"
6 | }
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/mesh/mesh.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {}
3 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/src/colorteller/.gitignore:
--------------------------------------------------------------------------------
1 | color_server
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/src/colorteller/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-http2/color_server
2 |
3 | go 1.13
4 |
5 | require golang.org/x/net v0.23.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-circuit-breakers/vars.env:
--------------------------------------------------------------------------------
1 | export AWS_ACCOUNT_ID=
2 | export KEY_PAIR_NAME=
3 | export AWS_DEFAULT_REGION=us-west-2
4 | export ENVIRONMENT_NAME=CircuitBreakers
5 | export MESH_NAME=circuit-breaker-mesh
6 | export ENVOY_IMAGE=
7 | export SERVICES_DOMAIN="default.svc.cluster.local"
8 | export COLOR_TELLER_IMAGE_NAME="howto-circuit-breakers/colorteller"
9 | export WRK_TOOL_IMAGE_NAME="howto-circuit-breakers/wrktool"
10 |
--------------------------------------------------------------------------------
/walkthroughs/howto-cross-account/CrossAccount.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-cross-account/CrossAccount.png
--------------------------------------------------------------------------------
/walkthroughs/howto-cross-account/updated-route.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute": {
4 | "action": {
5 | "weightedTargets": [
6 | {
7 | "virtualNode": "backend-2-vn",
8 | "weight": 1
9 | }
10 | ]
11 | },
12 | "match": {
13 | "prefix": "/"
14 | }
15 | }
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/walkthroughs/howto-cross-account/vars.env:
--------------------------------------------------------------------------------
1 | unset AWS_ACCESS_KEY_ID
2 | unset AWS_SECRET_ACCESS_KEY
3 | export AWS_PRIMARY_ACCOUNT_ID=
4 | export AWS_SECONDARY_ACCOUNT_ID=
5 | export AWS_PRIMARY_PROFILE=primary
6 | export AWS_SECONDARY_PROFILE=secondary
7 | export PROJECT_NAME=
8 | export AWS_DEFAULT_REGION=
9 | export KEY_PAIR=
10 |
11 | export ENVOY_IMAGE=public.ecr.aws/appmesh/aws-appmesh-envoy:v1.25.1.0-prod
12 | export BACKEND_1_IMAGE=dockercloud/hello-world
13 | export BACKEND_2_IMAGE=karthequian/helloworld
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ecs-basics/.gitignore:
--------------------------------------------------------------------------------
1 | _output
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ecs-basics/images/0-prelude-app.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-ecs-basics/images/0-prelude-app.png
--------------------------------------------------------------------------------
/walkthroughs/howto-ecs-basics/images/0-prelude-xray-map.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-ecs-basics/images/0-prelude-xray-map.png
--------------------------------------------------------------------------------
/walkthroughs/howto-ecs-basics/images/1-servicediscovery-app.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-ecs-basics/images/1-servicediscovery-app.png
--------------------------------------------------------------------------------
/walkthroughs/howto-ecs-basics/images/1-servicediscovery-xray-map.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-ecs-basics/images/1-servicediscovery-xray-map.png
--------------------------------------------------------------------------------
/walkthroughs/howto-ecs-basics/images/2-meshify-app.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-ecs-basics/images/2-meshify-app.png
--------------------------------------------------------------------------------
/walkthroughs/howto-ecs-basics/images/2-meshify-xray-map.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-ecs-basics/images/2-meshify-xray-map.png
--------------------------------------------------------------------------------
/walkthroughs/howto-ecs-basics/images/3-routing-app.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-ecs-basics/images/3-routing-app.png
--------------------------------------------------------------------------------
/walkthroughs/howto-ecs-basics/images/3-routing-xray-map.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-ecs-basics/images/3-routing-xray-map.png
--------------------------------------------------------------------------------
/walkthroughs/howto-ecs-basics/src/colorapp/.gitignore:
--------------------------------------------------------------------------------
1 | teller
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ecs-basics/src/colorapp/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/colorapp/teller
2 |
3 | go 1.12
4 |
5 | require (
6 | github.com/DATA-DOG/go-sqlmock v1.3.3 // indirect
7 | github.com/aws/aws-sdk-go v1.44.209 // indirect
8 | github.com/aws/aws-xray-sdk-go v0.9.4
9 | github.com/cihub/seelog v0.0.0-20151216151435-d2c6e5aa9fbf // indirect
10 | github.com/kr/pretty v0.1.0 // indirect
11 | github.com/stretchr/testify v1.8.1 // indirect
12 | golang.org/x/net v0.23.0 // indirect
13 | gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 // indirect
14 | gopkg.in/yaml.v2 v2.4.0 // indirect
15 | )
16 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ecs-basics/src/feapp/.gitignore:
--------------------------------------------------------------------------------
1 | gateway
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-external-traffic/.gitignore:
--------------------------------------------------------------------------------
1 | *.pem
2 | *.srl
--------------------------------------------------------------------------------
/walkthroughs/howto-external-traffic/images/2-meshify-app.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-external-traffic/images/2-meshify-app.png
--------------------------------------------------------------------------------
/walkthroughs/howto-external-traffic/infrastructure/ecr-repositories.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecr-repositories" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecr-repositories.yaml" \
12 | --parameter-overrides \
13 | ColorTellerImageName="${COLOR_TELLER_IMAGE_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-external-traffic/infrastructure/ecr-repositories.yaml:
--------------------------------------------------------------------------------
1 | Parameters:
2 |
3 | ColorTellerImageName:
4 | Description: The name for the color teller image
5 | Type: String
6 |
7 |
8 | Resources:
9 |
10 | ColorTellerRepository:
11 | Type: AWS::ECR::Repository
12 | Properties:
13 | RepositoryName: !Ref ColorTellerImageName
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-external-traffic/infrastructure/ecs-cluster.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecs-cluster" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecs-cluster.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | KeyName="${KEY_PAIR_NAME}" \
15 | ECSServicesDomain="${SERVICES_DOMAIN}"
16 |
--------------------------------------------------------------------------------
/walkthroughs/howto-external-traffic/infrastructure/vpc.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-vpc" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/vpc.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-external-traffic/mesh/mesh.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-mesh" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/mesh.yaml" \
12 | --parameter-overrides \
13 | MeshName="${MESH_NAME}" \
14 | ServicesDomain="${SERVICES_DOMAIN}" \
15 | CertificateAuthorityArn="${ROOT_CA_ARN}" \
16 | CertificateArn="${CERTIFICATE_ARN}"
17 |
--------------------------------------------------------------------------------
/walkthroughs/howto-external-traffic/src/colorteller_with_external_traffic/.gitignore:
--------------------------------------------------------------------------------
1 | colorteller_with_external_traffic
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-external-traffic/src/colorteller_with_external_traffic/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/external-traffic/src/colorteller_with_external_traffic
2 |
3 | go 1.17
4 |
--------------------------------------------------------------------------------
/walkthroughs/howto-external-traffic/src/colorteller_with_external_traffic/go.sum:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-external-traffic/src/colorteller_with_external_traffic/go.sum
--------------------------------------------------------------------------------
/walkthroughs/howto-grpc-ingress-gateway/color_server/.gitignore:
--------------------------------------------------------------------------------
1 | color_server
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-grpc-ingress-gateway/color_server/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-grpc/color_server
2 |
3 | go 1.13
4 |
5 | require (
6 | github.com/golang/protobuf v1.5.3
7 | golang.org/x/net v0.23.0 // indirect
8 | google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98 // indirect
9 | google.golang.org/grpc v1.56.3
10 | )
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-grpc-ingress-gateway/generate_protos.sh:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 |
3 | set -e
4 |
5 | protoc ./color.proto --go_out=plugins=grpc:./color_server/color
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-grpc-ingress-gateway/howto-grpc-ingress-gateway.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-grpc-ingress-gateway/howto-grpc-ingress-gateway.png
--------------------------------------------------------------------------------
/walkthroughs/howto-grpc/color_client/.gitignore:
--------------------------------------------------------------------------------
1 | color_client
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-grpc/color_client/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-grpc/color_client
2 |
3 | go 1.13
4 |
5 | require (
6 | github.com/golang/protobuf v1.5.3
7 | golang.org/x/net v0.23.0 // indirect
8 | google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98 // indirect
9 | google.golang.org/grpc v1.56.3
10 | )
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-grpc/color_server/.gitignore:
--------------------------------------------------------------------------------
1 | color_server
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-grpc/color_server/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-grpc/color_server
2 |
3 | go 1.13
4 |
5 | require (
6 | github.com/golang/protobuf v1.5.3
7 | golang.org/x/net v0.23.0 // indirect
8 | google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98 // indirect
9 | google.golang.org/grpc v1.56.3
10 | )
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-grpc/generate_protos.sh:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 |
3 | set -e
4 |
5 | protoc ./color.proto --go_out=plugins=grpc:./color_client/color
6 | protoc ./color.proto --go_out=plugins=grpc:./color_server/color
7 |
--------------------------------------------------------------------------------
/walkthroughs/howto-grpc/howto-grpc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-grpc/howto-grpc.png
--------------------------------------------------------------------------------
/walkthroughs/howto-grpc/mesh/route-all-methods.json:
--------------------------------------------------------------------------------
1 | {
2 | "routeName": "route",
3 | "spec": {
4 | "grpcRoute": {
5 | "action": {
6 | "weightedTargets": [
7 | {
8 | "virtualNode": "color_server",
9 | "weight": 100
10 | }
11 | ]
12 | },
13 | "match": {
14 | "serviceName": "color.ColorService"
15 | }
16 | }
17 | },
18 | "virtualRouterName": "virtual-router"
19 | }
20 |
--------------------------------------------------------------------------------
/walkthroughs/howto-http-headers/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-http-headers/feapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-http-retries/blue-route-no-retry.json:
--------------------------------------------------------------------------------
1 | {
2 | "virtualRouterName": "color-router",
3 | "routeName": "color-route-blue",
4 | "spec": {
5 | "priority": 1,
6 | "httpRoute": {
7 | "match": {
8 | "prefix": "/"
9 | },
10 | "action": {
11 | "weightedTargets": [
12 | {
13 | "virtualNode": "blue-node",
14 | "weight": 1
15 | }
16 | ]
17 | }
18 |
19 | }
20 | }
21 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-http-retries/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-http-retries/components/retries.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-http-retries/components/retries.png
--------------------------------------------------------------------------------
/walkthroughs/howto-http-retries/feapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-http2/color_client/.gitignore:
--------------------------------------------------------------------------------
1 | color_client
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-http2/color_client/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-http2/color_client
2 |
3 | go 1.13
4 |
5 | require golang.org/x/net v0.23.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-http2/color_server/.gitignore:
--------------------------------------------------------------------------------
1 | color_server
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-http2/color_server/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-http2/color_server
2 |
3 | go 1.13
4 |
5 | require golang.org/x/net v0.23.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-http2/howto-http2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-http2/howto-http2.png
--------------------------------------------------------------------------------
/walkthroughs/howto-http2/mesh/route-blue.json:
--------------------------------------------------------------------------------
1 | {
2 | "routeName": "route",
3 | "spec": {
4 | "http2Route": {
5 | "action": {
6 | "weightedTargets": [
7 | {
8 | "virtualNode": "color_server-blue",
9 | "weight": 1
10 | }
11 | ]
12 | },
13 | "match": {
14 | "prefix": "/"
15 | }
16 | }
17 | },
18 | "virtualRouterName": "virtual-router"
19 | }
20 |
--------------------------------------------------------------------------------
/walkthroughs/howto-http2/mesh/route-red.json:
--------------------------------------------------------------------------------
1 | {
2 | "routeName": "route",
3 | "spec": {
4 | "http2Route": {
5 | "action": {
6 | "weightedTargets": [
7 | {
8 | "virtualNode": "color_server-red",
9 | "weight": 1
10 | }
11 | ]
12 | },
13 | "match": {
14 | "prefix": "/"
15 | }
16 | }
17 | },
18 | "virtualRouterName": "virtual-router"
19 | }
20 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/howto-ingress-gateway.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-ingress-gateway/howto-ingress-gateway.png
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/infrastructure/ecr-repositories.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecr-repositories" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecr-repositories.yaml" \
12 | --parameter-overrides \
13 | ColorTellerImageName="${COLOR_TELLER_IMAGE_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/infrastructure/ecr-repositories.yaml:
--------------------------------------------------------------------------------
1 | Parameters:
2 |
3 | ColorTellerImageName:
4 | Description: The name for the color teller image
5 | Type: String
6 |
7 | Resources:
8 |
9 | ColorTellerRepository:
10 | Type: AWS::ECR::Repository
11 | Properties:
12 | RepositoryName: !Ref ColorTellerImageName
13 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/infrastructure/ecs-cluster.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecs-cluster" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecs-cluster.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | KeyName="${KEY_PAIR_NAME}" \
15 | ECSServicesDomain="${SERVICES_DOMAIN}"
16 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/infrastructure/vpc.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-vpc" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/vpc.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/mesh/colorgateway-route-1.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute" : {
4 | "match" : {
5 | "prefix" : "/color1"
6 | },
7 | "action" : {
8 | "target" : {
9 | "virtualService": {
10 | "virtualServiceName": $VIRTUALSERVICE_NAME
11 | }
12 | }
13 | }
14 | }
15 | }
16 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/mesh/colorgateway-route-2.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute" : {
4 | "match" : {
5 | "prefix" : "/color2"
6 | },
7 | "action" : {
8 | "target" : {
9 | "virtualService": {
10 | "virtualServiceName": $VIRTUALSERVICE_NAME
11 | }
12 | }
13 | }
14 | }
15 | }
16 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/mesh/colorgateway-vg.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 9080,
7 | "protocol": "http"
8 | },
9 | "tls": {
10 | "mode": "STRICT",
11 | "certificate": {
12 | "acm": {
13 | "certificateArn": $CERTIFICATE_ARN
14 | }
15 | }
16 | }
17 | }
18 | ]
19 | }
20 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/mesh/colorteller-route-1.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute": {
4 | "action": {
5 | "weightedTargets": [
6 | {
7 | "virtualNode": "colorteller-white-vn",
8 | "weight": 1
9 | },
10 | {
11 | "virtualNode": "colorteller-blue-vn",
12 | "weight": 1
13 | }
14 | ]
15 | },
16 | "match": {
17 | "prefix": "/tell"
18 | }
19 | }
20 | }
21 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/mesh/colorteller-route-2.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute": {
4 | "action": {
5 | "weightedTargets": [
6 | {
7 | "virtualNode": "colorteller-black-vn",
8 | "weight": 1
9 | },
10 | {
11 | "virtualNode": "colorteller-red-vn",
12 | "weight": 1
13 | }
14 | ]
15 | },
16 | "match": {
17 | "prefix": "/tell"
18 | }
19 | }
20 | }
21 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/mesh/colorteller-vr-1.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 9080,
7 | "protocol": "http"
8 | }
9 | }
10 | ]
11 | }
12 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/mesh/colorteller-vr-2.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 9080,
7 | "protocol": "http"
8 | }
9 | }
10 | ]
11 | }
12 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/mesh/colorteller-vs-1.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "provider": {
4 | "virtualRouter": {
5 | "virtualRouterName": "colorteller-vr-1"
6 | }
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/mesh/colorteller-vs-2.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "provider": {
4 | "virtualRouter": {
5 | "virtualRouterName": "colorteller-vr-2"
6 | }
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/mesh/mesh.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {}
3 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-ingress-gateway/src/colorteller/.gitignore:
--------------------------------------------------------------------------------
1 | colorteller
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ipv6/color_client/.gitignore:
--------------------------------------------------------------------------------
1 | color_client
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ipv6/color_client/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-http2/color_client
2 |
3 | go 1.13
4 |
5 | require golang.org/x/net v0.23.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ipv6/color_server_dual/.gitignore:
--------------------------------------------------------------------------------
1 | color_server
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ipv6/color_server_dual/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-http2/color_server
2 |
3 | go 1.13
4 |
5 | require golang.org/x/net v0.23.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ipv6/color_server_v4/.gitignore:
--------------------------------------------------------------------------------
1 | color_server
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ipv6/color_server_v4/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-http2/color_server
2 |
3 | go 1.13
4 |
5 | require golang.org/x/net v0.23.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ipv6/color_server_v6/.gitignore:
--------------------------------------------------------------------------------
1 | color_server
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ipv6/color_server_v6/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-http2/color_server
2 |
3 | go 1.13
4 |
5 | require golang.org/x/net v0.23.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-ipv6/setup_graph.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-ipv6/setup_graph.png
--------------------------------------------------------------------------------
/walkthroughs/howto-ipv6/vars.env:
--------------------------------------------------------------------------------
1 | export AWS_ACCOUNT_ID=
2 | export ENVOY_IMAGE=
3 | export KEY_PAIR_NAME=
4 | export PROJECT_NAME=app-mesh-ipv6
5 | export MESH_NAME=app-mesh-ipv6
6 | export SERVICES_DOMAIN="default.svc.cluster.local"
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-alb/.gitignore:
--------------------------------------------------------------------------------
1 | _output
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-alb/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-alb/feapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-alb/howto-k8s-alb.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-alb/howto-k8s-alb.png
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-cloudmap/.gitignore:
--------------------------------------------------------------------------------
1 | _output
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-cloudmap/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 |
3 | COPY requirements.txt ./
4 |
5 | RUN yum update -y && \
6 | yum install -y python3 && \
7 | pip3 install --no-cache-dir -r requirements.txt && \
8 | yum clean all && \
9 | rm -rf /var/cache/yum
10 |
11 | WORKDIR /usr/src/app
12 |
13 | COPY . .
14 |
15 | ENV PORT 8080
16 |
17 | CMD ["gunicorn", "app:app", "--config=config.py"]
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-cloudmap/colorapp/config.py:
--------------------------------------------------------------------------------
1 | from os import environ as env
2 | import multiprocessing
3 |
4 | PORT = int(env.get("PORT", 8080))
5 | DEBUG_MODE = int(env.get("DEBUG_MODE", 0))
6 | XRAY_APP_NAME = env.get('XRAY_APP_NAME', 'feapp')
7 | COLOR = env.get('COLOR', 'n/a')
8 |
9 | # Gunicorn config
10 | bind = ":" + str(PORT)
11 | workers = multiprocessing.cpu_count() * 2 + 1
12 | threads = 2 * multiprocessing.cpu_count()
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-cloudmap/colorapp/requirements.txt:
--------------------------------------------------------------------------------
1 | flask
2 | aws-xray-sdk
3 | urllib3<2
4 | gunicorn==22.0.0
5 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-cloudmap/feapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 |
3 | COPY requirements.txt ./
4 |
5 | RUN yum update -y && \
6 | yum install -y python3 && \
7 | pip3 install --no-cache-dir -r requirements.txt && \
8 | yum clean all && \
9 | rm -rf /var/cache/yum
10 |
11 | WORKDIR /usr/src/app
12 |
13 | COPY . .
14 |
15 | ENV PORT 8080
16 |
17 | CMD ["gunicorn", "app:app", "--config=config.py"]
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-cloudmap/feapp/config.py:
--------------------------------------------------------------------------------
1 | from os import environ as env
2 | import multiprocessing
3 |
4 | PORT = int(env.get("PORT", 8080))
5 | DEBUG_MODE = int(env.get("DEBUG_MODE", 0))
6 | XRAY_APP_NAME = env.get('XRAY_APP_NAME', 'feapp')
7 | COLOR_HOST = env.get('COLOR_HOST')
8 |
9 | # Gunicorn config
10 | bind = ":" + str(PORT)
11 | workers = multiprocessing.cpu_count() * 2 + 1
12 | threads = 2 * multiprocessing.cpu_count()
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-cloudmap/feapp/requirements.txt:
--------------------------------------------------------------------------------
1 | flask
2 | requests
3 | aws-xray-sdk
4 | urllib3<2
5 | gunicorn==22.0.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-connection-pools/.gitignore:
--------------------------------------------------------------------------------
1 | _output
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-connection-pools/colorapp/.gitignore:
--------------------------------------------------------------------------------
1 | color_server
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-connection-pools/colorapp/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-http2/color_server
2 |
3 | go 1.13
4 |
5 | require golang.org/x/net v0.23.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-cross-cluster/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 |
3 | COPY requirements.txt ./
4 |
5 | RUN yum update -y && \
6 | yum install -y python3 && \
7 | pip3 install --no-cache-dir -r requirements.txt && \
8 | yum clean all && \
9 | rm -rf /var/cache/yum
10 |
11 | WORKDIR /usr/src/app
12 |
13 | COPY . .
14 |
15 | ENV PORT 8080
16 |
17 | CMD ["gunicorn", "app:app", "--config=config.py"]
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-cross-cluster/colorapp/config.py:
--------------------------------------------------------------------------------
1 | from os import environ as env
2 | import multiprocessing
3 |
4 | PORT = int(env.get("PORT", 8080))
5 | DEBUG_MODE = int(env.get("DEBUG_MODE", 0))
6 | XRAY_APP_NAME = env.get('XRAY_APP_NAME', 'feapp')
7 | COLOR = env.get('COLOR', 'n/a')
8 |
9 | # Gunicorn config
10 | bind = ":" + str(PORT)
11 | workers = multiprocessing.cpu_count() * 2 + 1
12 | threads = 2 * multiprocessing.cpu_count()
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-cross-cluster/colorapp/requirements.txt:
--------------------------------------------------------------------------------
1 | flask
2 | aws-xray-sdk
3 | urllib3<2
4 | gunicorn==22.0.0
5 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-cross-cluster/feapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 |
3 | COPY requirements.txt ./
4 |
5 | RUN yum update -y && \
6 | yum install -y python3 && \
7 | pip3 install --no-cache-dir -r requirements.txt && \
8 | yum clean all && \
9 | rm -rf /var/cache/yum
10 |
11 | WORKDIR /usr/src/app
12 |
13 | COPY . .
14 |
15 | ENV PORT 8080
16 |
17 | CMD ["gunicorn", "app:app", "--config=config.py"]
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-cross-cluster/feapp/config.py:
--------------------------------------------------------------------------------
1 | from os import environ as env
2 | import multiprocessing
3 |
4 | PORT = int(env.get("PORT", 8080))
5 | DEBUG_MODE = int(env.get("DEBUG_MODE", 0))
6 | XRAY_APP_NAME = env.get('XRAY_APP_NAME', 'feapp')
7 | COLOR_HOST = env.get('COLOR_HOST')
8 |
9 | # Gunicorn config
10 | bind = ":" + str(PORT)
11 | workers = multiprocessing.cpu_count() * 2 + 1
12 | threads = 2 * multiprocessing.cpu_count()
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-cross-cluster/feapp/requirements.txt:
--------------------------------------------------------------------------------
1 | flask
2 | requests
3 | aws-xray-sdk
4 | urllib3<2
5 | gunicorn==22.0.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-egress/.gitignore:
--------------------------------------------------------------------------------
1 | _output
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-egress/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-egress/feapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-envoy-logging-custom-format/colorapp/.gitignore:
--------------------------------------------------------------------------------
1 | colorapp
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-envoy-logging-custom-format/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM --platform=linux/amd64 golang:1.17.1 AS builder
2 | WORKDIR /workspace
3 | COPY . ./
4 | ENV GOPROXY=direct
5 | RUN go mod download
6 | RUN go build -o colorapp main.go
7 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
8 | WORKDIR /
9 | COPY --from=builder /workspace/colorapp .
10 | ENTRYPOINT ["/colorapp"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-envoy-logging-custom-format/colorapp/go.mod:
--------------------------------------------------------------------------------
1 | module colorapp
2 |
3 | go 1.18
4 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-envoy-logging-custom-format/colorapp/go.sum:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-envoy-logging-custom-format/colorapp/go.sum
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-envoy-logging-custom-format/colorapp/main.go:
--------------------------------------------------------------------------------
1 | package main
2 |
3 | import (
4 | "fmt"
5 | "log"
6 | "net/http"
7 | "os"
8 | )
9 |
10 | func main() {
11 | color, port := os.Getenv("COLOR"), os.Getenv("PORT")
12 |
13 | log.Printf("COLOR: %s", color)
14 | log.Printf("PORT: %s", port)
15 |
16 | http.HandleFunc("/ping", func(w http.ResponseWriter, r *http.Request) {})
17 | http.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) {
18 | log.Printf("Received request: %v", r)
19 | fmt.Fprintf(w, "%s", color)
20 | })
21 |
22 | log.Fatal(http.ListenAndServe(fmt.Sprintf("0.0.0.0:%s", port), nil))
23 | }
24 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-envoy-logging-custom-format/feapp/.gitignore:
--------------------------------------------------------------------------------
1 | feapp
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-envoy-logging-custom-format/feapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM --platform=linux/amd64 golang:1.17.1 AS builder
2 | WORKDIR /workspace
3 | COPY . ./
4 | ENV GOPROXY=direct
5 | RUN go mod download
6 | RUN go build -o feapp main.go
7 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
8 | WORKDIR /
9 | COPY --from=builder /workspace/feapp .
10 | ENTRYPOINT ["/feapp"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-envoy-logging-custom-format/feapp/go.mod:
--------------------------------------------------------------------------------
1 | module feapp
2 |
3 | go 1.18
4 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-envoy-logging-custom-format/feapp/go.sum:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-envoy-logging-custom-format/feapp/go.sum
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-fargate/.gitignore:
--------------------------------------------------------------------------------
1 | _output
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-fargate/src/colorapp/.gitignore:
--------------------------------------------------------------------------------
1 | teller
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-fargate/src/colorapp/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/colorapp/teller
2 |
3 | go 1.12
4 |
5 | require (
6 | github.com/DATA-DOG/go-sqlmock v1.3.3 // indirect
7 | github.com/aws/aws-sdk-go v1.44.209 // indirect
8 | github.com/aws/aws-xray-sdk-go v0.9.4
9 | github.com/cihub/seelog v0.0.0-20151216151435-d2c6e5aa9fbf // indirect
10 | github.com/kr/pretty v0.1.0 // indirect
11 | github.com/stretchr/testify v1.8.1 // indirect
12 | golang.org/x/net v0.23.0 // indirect
13 | gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 // indirect
14 | gopkg.in/yaml.v2 v2.4.0 // indirect
15 | )
16 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-fargate/src/feapp/.gitignore:
--------------------------------------------------------------------------------
1 | gateway
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-grpc-ingress-v2/greeter/.gitignore:
--------------------------------------------------------------------------------
1 | module greeter
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-grpc-ingress-v2/greeter/go.mod:
--------------------------------------------------------------------------------
1 | module greeter
2 |
3 | go 1.15
4 |
5 | require (
6 | golang.org/x/net v0.23.0 // indirect
7 | google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98 // indirect
8 | google.golang.org/grpc v1.56.3
9 | google.golang.org/protobuf v1.31.0
10 | )
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-grpc-ingress-v2/greeter/input/input.proto:
--------------------------------------------------------------------------------
1 | syntax = "proto3";
2 | option go_package = "./input";
3 |
4 | service Hello{
5 | rpc SayHello(name) returns (Result){}
6 | }
7 |
8 | message Result{
9 | string output=1;
10 | }
11 |
12 | message name{
13 | string user=1;
14 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-grpc-ingress-v2/greeter/server/greeting.go:
--------------------------------------------------------------------------------
1 | package server
2 |
3 | import (
4 | "context"
5 | "greeter/input"
6 | "log"
7 | )
8 |
9 | type HelloServer struct{}
10 |
11 | func (s *HelloServer) SayHello(ctx context.Context, name *input.Name) (*input.Result, error) {
12 | log.Printf("Received request for: %s\n", name.GetUser())
13 | return &input.Result{Output: "Hello " + name.GetUser()}, nil
14 | }
15 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-grpc-ingress-v2/images/grpc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-grpc-ingress-v2/images/grpc.png
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-grpc/.gitignore:
--------------------------------------------------------------------------------
1 | _output
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-grpc/color_client/.gitignore:
--------------------------------------------------------------------------------
1 | color_client
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-grpc/color_client/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-grpc/color_client
2 |
3 | go 1.13
4 |
5 | require (
6 | github.com/golang/protobuf v1.5.3
7 | golang.org/x/net v0.23.0 // indirect
8 | google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98 // indirect
9 | google.golang.org/grpc v1.56.3
10 | )
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-grpc/color_server/.gitignore:
--------------------------------------------------------------------------------
1 | color_server
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-grpc/color_server/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-grpc/color_server
2 |
3 | go 1.13
4 |
5 | require (
6 | github.com/golang/protobuf v1.5.3
7 | golang.org/x/net v0.23.0 // indirect
8 | google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98 // indirect
9 | google.golang.org/grpc v1.56.3
10 | )
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-grpc/generate_protos.sh:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 |
3 | set -e
4 |
5 | protoc ./color.proto --go_out=plugins=grpc:./color_client/color
6 | protoc ./color.proto --go_out=plugins=grpc:./color_server/color
7 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http-headers/.gitignore:
--------------------------------------------------------------------------------
1 | _output
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http-headers/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http-headers/feapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http-ingress-v2/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http-ingress-v2/images/basic_setup.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-http-ingress-v2/images/basic_setup.png
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http-ingress-v2/v1beta2/gatewayroutes/header-match.yaml.template:
--------------------------------------------------------------------------------
1 | apiVersion: appmesh.k8s.aws/v1beta2
2 | kind: GatewayRoute
3 | metadata:
4 | name: header-match
5 | namespace: ${APP_NAMESPACE}
6 | spec:
7 | httpRoute:
8 | match:
9 | prefix: "/"
10 | headers:
11 | - name: "color_header"
12 | match:
13 | exact: "yellow"
14 | action:
15 | target:
16 | virtualService:
17 | virtualServiceRef:
18 | name: color-yellow
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http-ingress-v2/v1beta2/gatewayroutes/method-match.yaml.template:
--------------------------------------------------------------------------------
1 | apiVersion: appmesh.k8s.aws/v1beta2
2 | kind: GatewayRoute
3 | metadata:
4 | name: method-match
5 | namespace: ${APP_NAMESPACE}
6 | spec:
7 | httpRoute:
8 | match:
9 | prefix: "/"
10 | method: GET
11 | action:
12 | target:
13 | virtualService:
14 | virtualServiceRef:
15 | name: color-white
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http-ingress-v2/v1beta2/gatewayroutes/path-match.yaml.template:
--------------------------------------------------------------------------------
1 | apiVersion: appmesh.k8s.aws/v1beta2
2 | kind: GatewayRoute
3 | metadata:
4 | name: path-match
5 | namespace: ${APP_NAMESPACE}
6 | spec:
7 | priority: 0
8 | httpRoute:
9 | match:
10 | path:
11 | exact: "/paths/green"
12 | action:
13 | target:
14 | virtualService:
15 | virtualServiceRef:
16 | name: color-green
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http-ingress-v2/v1beta2/gatewayroutes/prefix-match.yaml.template:
--------------------------------------------------------------------------------
1 | apiVersion: appmesh.k8s.aws/v1beta2
2 | kind: GatewayRoute
3 | metadata:
4 | name: prefix-match
5 | namespace: ${APP_NAMESPACE}
6 | spec:
7 | httpRoute:
8 | match:
9 | prefix: "/paths"
10 | action:
11 | target:
12 | virtualService:
13 | virtualServiceRef:
14 | name: color-paths
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http-ingress-v2/v1beta2/gatewayroutes/query-match.yaml.template:
--------------------------------------------------------------------------------
1 | apiVersion: appmesh.k8s.aws/v1beta2
2 | kind: GatewayRoute
3 | metadata:
4 | name: query-match
5 | namespace: ${APP_NAMESPACE}
6 | spec:
7 | httpRoute:
8 | match:
9 | prefix: "/query"
10 | queryParameters:
11 | - name: "color_type"
12 | match:
13 | exact: "white"
14 | action:
15 | target:
16 | virtualService:
17 | virtualServiceRef:
18 | name: color-white
19 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http-ingress-v2/v1beta2/gatewayroutes/rewrite-path.yaml.template:
--------------------------------------------------------------------------------
1 | apiVersion: appmesh.k8s.aws/v1beta2
2 | kind: GatewayRoute
3 | metadata:
4 | name: rewrite-path
5 | namespace: ${APP_NAMESPACE}
6 | spec:
7 | httpRoute:
8 | match:
9 | path:
10 | exact: "/rewrite/path/blue"
11 | action:
12 | target:
13 | virtualService:
14 | virtualServiceRef:
15 | name: color-paths
16 | rewrite:
17 | path:
18 | exact: "/blue"
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http-ingress-v2/v1beta2/gatewayroutes/rewrite-prefix.yaml.template:
--------------------------------------------------------------------------------
1 | apiVersion: appmesh.k8s.aws/v1beta2
2 | kind: GatewayRoute
3 | metadata:
4 | name: rewrite-prefix
5 | namespace: ${APP_NAMESPACE}
6 | spec:
7 | httpRoute:
8 | match:
9 | prefix: "/test/"
10 | action:
11 | target:
12 | virtualService:
13 | virtualServiceRef:
14 | name: color-paths
15 | rewrite:
16 | prefix:
17 | value: "/red/"
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http2/.gitignore:
--------------------------------------------------------------------------------
1 | _output
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http2/color_client/.gitignore:
--------------------------------------------------------------------------------
1 | color_client
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http2/color_client/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-http2/color_client
2 |
3 | go 1.13
4 |
5 | require golang.org/x/net v0.23.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http2/color_server/.gitignore:
--------------------------------------------------------------------------------
1 | color_server
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-http2/color_server/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-http2/color_server
2 |
3 | go 1.13
4 |
5 | require golang.org/x/net v0.23.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-ingress-gateway/.gitignore:
--------------------------------------------------------------------------------
1 | _output
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-ingress-gateway/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-ipv6/.gitignore:
--------------------------------------------------------------------------------
1 | _output
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-ipv6/color_client/.gitignore:
--------------------------------------------------------------------------------
1 | color_client
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-ipv6/color_client/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-http2/color_client
2 |
3 | go 1.13
4 |
5 | require golang.org/x/net v0.23.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-ipv6/color_server/.gitignore:
--------------------------------------------------------------------------------
1 | color_server
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-ipv6/color_server/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-http2/color_server
2 |
3 | go 1.13
4 |
5 | require golang.org/x/net v0.23.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-ipv6/ipv6-cluster.yaml:
--------------------------------------------------------------------------------
1 | ---
2 | apiVersion: eksctl.io/v1alpha5
3 | kind: ClusterConfig
4 |
5 | metadata:
6 | name: appmeshtestipv6
7 | region: us-west-2
8 | version: "1.21"
9 |
10 | kubernetesNetworkConfig:
11 | ipFamily: IPv6
12 |
13 | addons:
14 | - name: vpc-cni
15 | version: latest
16 | - name: coredns
17 | version: latest
18 | - name: kube-proxy
19 | version: latest
20 |
21 | iam:
22 | withOIDC: true
23 |
24 | managedNodeGroups:
25 | - name: ng-1
26 | instanceType: m5.large
27 | iam:
28 | withAddonPolicies:
29 | appMesh: true
30 | imageBuilder: true
31 |
32 |
33 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-metrics-extension/deploy/namespace.yaml.template:
--------------------------------------------------------------------------------
1 | ---
2 | apiVersion: v1
3 | kind: Namespace
4 | metadata:
5 | name: $NAMESPACE_NAME
6 | labels:
7 | mesh: $NAMESPACE_NAME
8 | gateway: ingress-gw
9 | appmesh.k8s.aws/sidecarInjectorWebhook: enabled
10 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-metrics-extension/images/djapp-v1-cloudwatch-metric-dimensions.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-metrics-extension/images/djapp-v1-cloudwatch-metric-dimensions.png
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-metrics-extension/images/djapp-v1-cloudwatch-upstream-rq.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-metrics-extension/images/djapp-v1-cloudwatch-upstream-rq.png
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-metrics-extension/images/djapp-v2-cloudwatch-metrics.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-metrics-extension/images/djapp-v2-cloudwatch-metrics.png
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-metrics-extension/images/djapp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-metrics-extension/images/djapp.png
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-mtls-file-based/.gitignore:
--------------------------------------------------------------------------------
1 | _output
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-mtls-file-based/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-mtls-file-based/feapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-mtls-sds-based/.gitignore:
--------------------------------------------------------------------------------
1 | _output
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-mtls-sds-based/cleanup.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | main(){
4 | kubectl delete -f _output/manifest.yaml
5 | kubectl delete ns spire
6 | }
7 |
8 | main
9 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-mtls-sds-based/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-mtls-sds-based/deploy_spire.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -e
4 |
5 | deploySpire() {
6 | kubectl apply -f spire/spire_setup.yaml
7 | }
8 |
9 | echo "Installing SPIRE Server and Agent"
10 | deploySpire
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-mtls-sds-based/feapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-multi-region/.gitignore:
--------------------------------------------------------------------------------
1 | _output
2 | .DS_Store
3 | *.code-workspace
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-multi-region/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/bitnami/python:latest
2 |
3 | COPY serve.py ./
4 | RUN chmod +x ./serve.py
5 | RUN pip install requests
6 | CMD ["python", "-u", "./serve.py"]
7 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-multi-region/envoy-iam-policy.json:
--------------------------------------------------------------------------------
1 | {
2 | "Version": "2012-10-17",
3 | "Statement": [
4 | {
5 | "Effect": "Allow",
6 | "Action": [
7 | "appmesh:StreamAggregatedResources"
8 | ],
9 | "Resource": "*"
10 | },
11 | {
12 | "Effect": "Allow",
13 | "Action": [
14 | "acm:ExportCertificate",
15 | "acm-pca:GetCertificateAuthorityCertificate"
16 | ],
17 | "Resource": "*"
18 | }
19 | ]
20 | }
21 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-multi-region/images/Architecture.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-multi-region/images/Architecture.png
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-multi-region/images/route53HealthCheck.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-multi-region/images/route53HealthCheck.png
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-multi-region/images/route53HealthCheckFailure.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-multi-region/images/route53HealthCheckFailure.png
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-multi-region/images/route53HostedZone.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-multi-region/images/route53HostedZone.png
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-multiple-listeners/app/.gitignore:
--------------------------------------------------------------------------------
1 | multiportapp
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-multiple-listeners/app/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM --platform=linux/amd64 golang:1.17.1 AS builder
2 | WORKDIR /workspace
3 | COPY go.mod ./
4 | ENV GOPROXY=direct
5 | RUN go mod download
6 | COPY . ./
7 | RUN go build -o app main.go
8 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
9 | WORKDIR /
10 | COPY --from=builder /workspace/app .
11 | ENTRYPOINT ["/app"]
12 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-multiple-listeners/app/go.mod:
--------------------------------------------------------------------------------
1 | module multiportapp
2 |
3 | go 1.18
4 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-multiple-listeners/app/go.sum:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-multiple-listeners/app/go.sum
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-outlier-detection/.gitignore:
--------------------------------------------------------------------------------
1 | _output
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-outlier-detection/colorapp/.gitignore:
--------------------------------------------------------------------------------
1 | color-app
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-outlier-detection/colorapp/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-outlier-detection/src/color-app
2 |
3 | go 1.14
4 |
5 | require github.com/google/uuid v1.1.2
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-outlier-detection/colorapp/go.sum:
--------------------------------------------------------------------------------
1 | github.com/google/uuid v1.1.2 h1:EVhdT+1Kseyi1/pUmXKaFxYsDNy9RQYkMWRH68J/W7Y=
2 | github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
3 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-outlier-detection/feapp/.gitignore:
--------------------------------------------------------------------------------
1 | frontend-app
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-outlier-detection/feapp/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-outlier-detection/src/frontend-app
2 |
3 | go 1.14
4 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-outlier-detection/feapp/go.sum:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-outlier-detection/feapp/go.sum
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-outlier-detection/results.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-k8s-outlier-detection/results.bin
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-retry-policy/.gitignore:
--------------------------------------------------------------------------------
1 | _output
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-retry-policy/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-retry-policy/feapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-timeout-policy/.gitignore:
--------------------------------------------------------------------------------
1 | _output
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-timeout-policy/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 |
3 | COPY requirements.txt ./
4 |
5 | RUN yum update -y && \
6 | yum install -y python3 && \
7 | pip3 install --no-cache-dir -r requirements.txt && \
8 | yum clean all && \
9 | rm -rf /var/cache/yum
10 |
11 | WORKDIR /usr/src/app
12 |
13 | COPY . .
14 |
15 | ENV PORT 8080
16 |
17 | CMD ["gunicorn", "app:app", "--config=config.py"]
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-timeout-policy/colorapp/config.py:
--------------------------------------------------------------------------------
1 | from os import environ as env
2 | import multiprocessing
3 |
4 | PORT = int(env.get("PORT", 8080))
5 | DEBUG_MODE = int(env.get("DEBUG_MODE", 0))
6 | XRAY_APP_NAME = env.get('XRAY_APP_NAME', 'feapp')
7 | COLOR = env.get('COLOR', 'n/a')
8 | TIMEOUT_VALUE = int(env.get("TIMEOUT_VALUE", 45))
9 |
10 | # Gunicorn config
11 | bind = ":" + str(PORT)
12 | workers = multiprocessing.cpu_count() * 2 + 1
13 | threads = 2 * multiprocessing.cpu_count()
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-timeout-policy/colorapp/requirements.txt:
--------------------------------------------------------------------------------
1 | flask
2 | aws-xray-sdk
3 | urllib3<2
4 | gunicorn==22.0.0
5 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-timeout-policy/feapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 |
3 | COPY requirements.txt ./
4 |
5 | RUN yum update -y && \
6 | yum install -y python3 && \
7 | pip3 install --no-cache-dir -r requirements.txt && \
8 | yum clean all && \
9 | rm -rf /var/cache/yum
10 |
11 | WORKDIR /usr/src/app
12 |
13 | COPY . .
14 |
15 | ENV PORT 8080
16 |
17 | CMD ["gunicorn", "app:app", "--config=config.py"]
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-timeout-policy/feapp/config.py:
--------------------------------------------------------------------------------
1 | from os import environ as env
2 | import multiprocessing
3 |
4 | PORT = int(env.get("PORT", 8080))
5 | DEBUG_MODE = int(env.get("DEBUG_MODE", 0))
6 | XRAY_APP_NAME = env.get('XRAY_APP_NAME', 'feapp')
7 | COLOR_HOST = env.get('COLOR_HOST')
8 |
9 | # Gunicorn config
10 | bind = ":" + str(PORT)
11 | workers = multiprocessing.cpu_count() * 2 + 1
12 | threads = 2 * multiprocessing.cpu_count()
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-timeout-policy/feapp/requirements.txt:
--------------------------------------------------------------------------------
1 | flask
2 | requests
3 | aws-xray-sdk
4 | urllib3<2
5 | gunicorn==22.0.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-tls-acm/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-tls-acm/feapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-tls-file-based/.gitignore:
--------------------------------------------------------------------------------
1 | _output
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-tls-file-based/colorapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-k8s-tls-file-based/feapp/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/amazonlinux/amazonlinux:2
2 | RUN yum update -y && \
3 | yum install -y python3 && \
4 | yum clean all && \
5 | rm -rf /var/cache/yum
6 |
7 | COPY serve.py ./
8 | RUN chmod +x ./serve.py
9 |
10 | CMD ["python3", "-u", "./serve.py"]
11 |
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/howto-match-and-rewrite-at-ingress.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-match-and-rewrite-at-ingress/howto-match-and-rewrite-at-ingress.png
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/infrastructure/ecr-repositories.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecr-repositories" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecr-repositories.yaml" \
12 | --parameter-overrides \
13 | ColorTellerImageName="${COLOR_TELLER_IMAGE_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/infrastructure/ecr-repositories.yaml:
--------------------------------------------------------------------------------
1 | Parameters:
2 |
3 | ColorTellerImageName:
4 | Description: The name for the color teller image
5 | Type: String
6 |
7 | Resources:
8 |
9 | ColorTellerRepository:
10 | Type: AWS::ECR::Repository
11 | Properties:
12 | RepositoryName: !Ref ColorTellerImageName
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/infrastructure/ecs-cluster.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecs-cluster" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecs-cluster.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | KeyName="${KEY_PAIR_NAME}" \
15 | ECSServicesDomain="${SERVICES_DOMAIN}"
16 |
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/infrastructure/vpc.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-vpc" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/vpc.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/mesh/colorgateway-route-1.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute" : {
4 | "match" : {
5 | "prefix" : "/red"
6 | },
7 | "action" : {
8 | "target" : {
9 | "virtualService": {
10 | "virtualServiceName": $VIRTUALSERVICE_NAME
11 | }
12 | }
13 | }
14 | }
15 | }
16 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/mesh/colorgateway-route-2.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute" : {
4 | "match" : {
5 | "prefix" : "/yellow"
6 | },
7 | "action" : {
8 | "target" : {
9 | "virtualService": {
10 | "virtualServiceName": $VIRTUALSERVICE_NAME
11 | }
12 | }
13 | }
14 | }
15 | }
16 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/mesh/colorgateway-route-updated-hostname-match.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute" : {
4 | "match" : {
5 | "prefix" : "/red",
6 | "hostname" : {
7 | "exact" : "www.example.com"
8 | }
9 | },
10 | "action" : {
11 | "target" : {
12 | "virtualService": {
13 | "virtualServiceName": $VIRTUALSERVICE_NAME
14 | }
15 | }
16 | }
17 | }
18 | }
19 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/mesh/colorgateway-vg.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 9080,
7 | "protocol": "http"
8 | }
9 | }
10 | ]
11 | }
12 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/mesh/colorteller-route-1.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute": {
4 | "action": {
5 | "weightedTargets": [
6 | {
7 | "virtualNode": "colorteller-red-vn",
8 | "weight": 1
9 | }
10 | ]
11 | },
12 | "match": {
13 | "prefix": "/tell"
14 | }
15 | }
16 | }
17 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/mesh/colorteller-route-2.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute": {
4 | "action": {
5 | "weightedTargets": [
6 | {
7 | "virtualNode": "colorteller-yellow-vn",
8 | "weight": 1
9 | }
10 | ]
11 | },
12 | "match": {
13 | "prefix": "/tell"
14 | }
15 | }
16 | }
17 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/mesh/colorteller-route-updated-rewrite.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute": {
4 | "action": {
5 | "weightedTargets": [
6 | {
7 | "virtualNode": "colorteller-red-vn",
8 | "weight": 1
9 | }
10 | ]
11 | },
12 | "match": {
13 | "prefix": "/red/tell"
14 | }
15 | }
16 | }
17 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/mesh/colorteller-vr-1.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 9080,
7 | "protocol": "http"
8 | }
9 | }
10 | ]
11 | }
12 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/mesh/colorteller-vr-2.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 9080,
7 | "protocol": "http"
8 | }
9 | }
10 | ]
11 | }
12 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/mesh/colorteller-vs-1.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "provider": {
4 | "virtualRouter": {
5 | "virtualRouterName": "colorteller-vr-1"
6 | }
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/mesh/colorteller-vs-2.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "provider": {
4 | "virtualRouter": {
5 | "virtualRouterName": "colorteller-vr-2"
6 | }
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/mesh/mesh.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {}
3 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/src/colorteller/.gitignore:
--------------------------------------------------------------------------------
1 | color_server
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/src/colorteller/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-http2/color_server
2 |
3 | go 1.13
4 |
5 | require golang.org/x/net v0.23.0
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-match-and-rewrite-at-ingress/vars.env:
--------------------------------------------------------------------------------
1 | export AWS_ACCOUNT_ID=
2 | export ENVOY_IMAGE=
3 | export KEY_PAIR_NAME=
4 | export AWS_DEFAULT_REGION=us-west-2
5 | export ENVIRONMENT_NAME=AppMeshIngress
6 | export MESH_NAME=ColorApp-Ingress
7 | export SERVICES_DOMAIN="default.svc.cluster.local"
8 | export COLOR_TELLER_IMAGE_NAME="howto-ingress/colorteller"
--------------------------------------------------------------------------------
/walkthroughs/howto-metrics-extension-ecs/images/djapp-v1-cloudwatch-metric-dimensions.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-metrics-extension-ecs/images/djapp-v1-cloudwatch-metric-dimensions.png
--------------------------------------------------------------------------------
/walkthroughs/howto-metrics-extension-ecs/images/djapp-v1-cloudwatch-upstream-rq.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-metrics-extension-ecs/images/djapp-v1-cloudwatch-upstream-rq.png
--------------------------------------------------------------------------------
/walkthroughs/howto-metrics-extension-ecs/images/djapp-v2-cloudwatch-metrics.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-metrics-extension-ecs/images/djapp-v2-cloudwatch-metrics.png
--------------------------------------------------------------------------------
/walkthroughs/howto-metrics-extension-ecs/images/djapp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-metrics-extension-ecs/images/djapp.png
--------------------------------------------------------------------------------
/walkthroughs/howto-metrics-extension-ecs/images/gateway-generated-dashboard.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-metrics-extension-ecs/images/gateway-generated-dashboard.png
--------------------------------------------------------------------------------
/walkthroughs/howto-metrics-extension-ecs/src/dashboard-v1/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM public.ecr.aws/lambda/nodejs:14
2 |
3 | COPY index.js package*.json ${LAMBDA_TASK_ROOT}/
4 |
5 | RUN npm install
6 |
7 | CMD [ "index.handler" ]
8 |
--------------------------------------------------------------------------------
/walkthroughs/howto-metrics-extension-ecs/src/dashboard-v1/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "appmesh-metrics-extension-dashboard-v1",
3 | "version": "1.0.0",
4 | "description": "",
5 | "main": "index.js",
6 | "scripts": {
7 | "test": "echo \"Error: no test specified\" && exit 1"
8 | },
9 | "author": "Amazon Web Services",
10 | "license": "Apache-2.0",
11 | "dependencies": {
12 | "cfn-response-promise": "1.1.0",
13 | "@aws-sdk/client-app-mesh": "3.637.0",
14 | "@aws-sdk/client-cloudwatch": "3.637.0"
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/walkthroughs/howto-metrics-extension-ecs/src/djapp/.gitignore:
--------------------------------------------------------------------------------
1 | djapp
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-metrics-extension-ecs/src/djapp/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/metrics-extension/djapp
2 |
3 | go 1.17
4 |
--------------------------------------------------------------------------------
/walkthroughs/howto-metrics-extension-ecs/src/djapp/go.sum:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-metrics-extension-ecs/src/djapp/go.sum
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/howto-ml-walkthrough.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-multiple-listeners/howto-ml-walkthrough.png
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/infrastructure/ecr-repositories.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecr-repositories" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecr-repositories.yaml" \
12 | --parameter-overrides \
13 | TellerImageName="${TELLER_IMAGE_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/infrastructure/ecr-repositories.yaml:
--------------------------------------------------------------------------------
1 | Parameters:
2 |
3 | TellerImageName:
4 | Description: The name for the color teller image
5 | Type: String
6 |
7 | Resources:
8 |
9 | TellerRepository:
10 | Type: AWS::ECR::Repository
11 | Properties:
12 | RepositoryName: !Ref TellerImageName
13 |
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/infrastructure/ecs-cluster.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecs-cluster" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecs-cluster.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | KeyName="${KEY_PAIR_NAME}" \
15 | ECSServicesDomain="${SERVICES_DOMAIN}"
16 |
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/infrastructure/vpc.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-vpc" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/vpc.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/mesh/color-gateway-route.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute" : {
4 | "match" : {
5 | "port": 2222
6 | },
7 | "action" : {
8 | "target" : {
9 | "virtualService": {
10 | "virtualServiceName": $VIRTUALSERVICE_NAME
11 | },
12 | "port": 7777
13 | }
14 | }
15 | }
16 | }
17 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/mesh/colorteller-vs.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "provider": {
4 | "virtualNode": {
5 | "virtualNodeName": "colorteller-vn"
6 | }
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/mesh/foodteller-vr.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 3333,
7 | "protocol": "http"
8 | }
9 | },
10 | {
11 | "portMapping": {
12 | "port": 4444,
13 | "protocol": "http"
14 | }
15 | }
16 | ]
17 | }
18 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/mesh/foodteller-vs.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "provider": {
4 | "virtualRouter": {
5 | "virtualRouterName": "foodteller-vr"
6 | }
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/mesh/fruit-gateway-route.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute" : {
4 | "match" : {
5 | "port": 1111,
6 | "prefix": "/fruit"
7 | },
8 | "action" : {
9 | "target" : {
10 | "virtualService": {
11 | "virtualServiceName": $VIRTUALSERVICE_NAME
12 | },
13 | "port": 3333
14 | }
15 | }
16 | }
17 | }
18 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/mesh/fruit-route.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute": {
4 | "action": {
5 | "weightedTargets": [
6 | {
7 | "virtualNode": "foodteller-vn",
8 | "weight": 1,
9 | "port": 5555
10 | }
11 | ]
12 | },
13 | "match": {
14 | "port": 3333
15 | }
16 | }
17 | }
18 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/mesh/mesh.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {}
3 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/mesh/tellergateway-vg.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 1111,
7 | "protocol": "http"
8 | }
9 | },
10 | {
11 | "portMapping": {
12 | "port": 2222,
13 | "protocol": "http"
14 | }
15 | }
16 | ]
17 | }
18 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/mesh/vegetable-gateway-route.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute" : {
4 | "match" : {
5 | "port": 1111,
6 | "prefix": "/vegetable"
7 | },
8 | "action" : {
9 | "target" : {
10 | "virtualService": {
11 | "virtualServiceName": $VIRTUALSERVICE_NAME
12 | },
13 | "port": 4444
14 | }
15 | }
16 | }
17 | }
18 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/mesh/vegetable-route.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute": {
4 | "action": {
5 | "weightedTargets": [
6 | {
7 | "virtualNode": "foodteller-vn",
8 | "weight": 1,
9 | "port": 6666
10 | }
11 | ]
12 | },
13 | "match": {
14 | "port": 4444
15 | }
16 | }
17 | }
18 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/src/teller/.gitignore:
--------------------------------------------------------------------------------
1 | teller
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/src/teller/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-multiple-listeners/teller
2 |
3 | go 1.13
4 |
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/src/teller/go.sum:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-multiple-listeners/src/teller/go.sum
--------------------------------------------------------------------------------
/walkthroughs/howto-multiple-listeners/vars.env:
--------------------------------------------------------------------------------
1 | export AWS_ACCOUNT_ID=
2 | export KEY_PAIR_NAME=
3 | export AWS_DEFAULT_REGION=us-west-2
4 | export ENVIRONMENT_NAME=MultipleListeners
5 | export MESH_NAME=multiple-listeners-mesh
6 | export ENVOY_IMAGE=
7 | export SERVICES_DOMAIN="default.svc.cluster.local"
8 | export TELLER_IMAGE_NAME="howto-multiple-listeners/teller"
9 |
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided-by-acm/infrastructure/acmpca.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-acm" \
10 | --capabilities CAPABILITY_IAM \
11 | --parameter-overrides \
12 | DomainName="${SERVICES_DOMAIN}" \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | --template-file "${DIR}/acmpca.yaml"
15 |
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided-by-acm/infrastructure/ecr-repositories.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecr-repositories" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecr-repositories.yaml" \
12 | --parameter-overrides \
13 | ColorTellerImageName="${COLOR_TELLER_IMAGE_NAME}" \
14 | ColorTellerEnvoyImageName="${ENVOY_IMAGE_NAME}"
15 |
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided-by-acm/infrastructure/ecs-cluster.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecs-cluster" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecs-cluster.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | KeyName="${KEY_PAIR_NAME}" \
15 | ECSServicesDomain="${SERVICES_DOMAIN}"
16 |
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided-by-acm/infrastructure/mesh.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-mesh" \
10 | --capabilities CAPABILITY_IAM \
11 | --parameter-overrides \
12 | ServiceDomain="${SERVICES_DOMAIN}" \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | MeshName="${MESH_NAME}" \
15 | TlsState=$1 \
16 | --template-file "${DIR}/mesh.yaml"
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided-by-acm/infrastructure/vpc.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-vpc" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/vpc.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided-by-acm/src/colorteller/.gitignore:
--------------------------------------------------------------------------------
1 | colorteller
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided-by-acm/src/colorteller/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-mutual-tls-file-provided-by-acm/src/colorteller
2 |
3 | go 1.17
4 |
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided-by-acm/src/colorteller/go.sum:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-mutual-tls-file-provided-by-acm/src/colorteller/go.sum
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided/.gitignore:
--------------------------------------------------------------------------------
1 | *.crt
2 | *.key
3 | *.csr
4 | *.pem
5 | *.srl
6 | *.generated
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided/infrastructure/ecr-repositories.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecr-repositories" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecr-repositories.yaml" \
12 | --parameter-overrides \
13 | ColorTellerImageName="${COLOR_TELLER_IMAGE_NAME}" \
14 | ColorTellerEnvoyImageName="${ENVOY_IMAGE_NAME}"
15 |
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided/infrastructure/ecr-repositories.yaml:
--------------------------------------------------------------------------------
1 | Parameters:
2 |
3 | ColorTellerImageName:
4 | Description: The name for the color teller image
5 | Type: String
6 |
7 | ColorTellerEnvoyImageName:
8 | Description: The name for the color app envoy image
9 | Type: String
10 |
11 | Resources:
12 |
13 | ColorTellerRepository:
14 | Type: AWS::ECR::Repository
15 | Properties:
16 | RepositoryName: !Ref ColorTellerImageName
17 |
18 | ColorTellerEnvoyRepository:
19 | Type: AWS::ECR::Repository
20 | Properties:
21 | RepositoryName: !Ref ColorTellerEnvoyImageName
22 |
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided/infrastructure/ecs-cluster.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecs-cluster" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecs-cluster.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | KeyName="${KEY_PAIR_NAME}" \
15 | ECSServicesDomain="${SERVICES_DOMAIN}"
16 |
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided/infrastructure/vpc.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-vpc" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/vpc.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided/mesh/colorteller-gwroute.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute": {
4 | "action": {
5 | "target": {
6 | "virtualService": {
7 | "virtualServiceName": $VIRTUAL_SERVICE
8 | }
9 | }
10 | },
11 | "match": {
12 | "prefix": "/"
13 | }
14 | }
15 | }
16 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided/mesh/colorteller-vn.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 9080,
7 | "protocol": "http"
8 | }
9 | }
10 | ],
11 | "serviceDiscovery": {
12 | "awsCloudMap": {
13 | "namespaceName": $SERVICES_DOMAIN,
14 | "serviceName": "colorteller"
15 | }
16 | }
17 | }
18 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided/mesh/colorteller-vs.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "provider": {
4 | "virtualNode": {
5 | "virtualNodeName": "colorteller-vn"
6 | }
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided/mesh/gateway-vgw.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 9080,
7 | "protocol": "http"
8 | }
9 | }
10 | ]
11 | }
12 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided/mesh/mesh.json:
--------------------------------------------------------------------------------
1 | {}
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided/src/colorteller/.gitignore:
--------------------------------------------------------------------------------
1 | colorteller
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided/src/colorteller/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-mutual-tls-file-provided/src/colorteller
2 |
3 | go 1.17
4 |
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided/src/colorteller/go.sum:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-mutual-tls-file-provided/src/colorteller/go.sum
--------------------------------------------------------------------------------
/walkthroughs/howto-mutual-tls-file-provided/src/tlsCertificates/cleanup.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 |
8 | # $1= Certificate Name
9 | removeSecret() {
10 | aws secretsmanager delete-secret --secret-id $1 --force-delete-without-recovery
11 | }
12 |
13 |
14 | removeSecret "ca_cert"
15 | removeSecret "gateway_cert"
16 | removeSecret "gateway_key"
17 | removeSecret "gateway_cert_chain"
18 | removeSecret "colorteller_cert"
19 | removeSecret "colorteller_key"
20 | removeSecret "colorteller_cert_chain"
21 | rm $DIR/*.pem
22 | rm $DIR/*.generated
23 |
--------------------------------------------------------------------------------
/walkthroughs/howto-outlier-detection/mesh/color-vs.json:
--------------------------------------------------------------------------------
1 | {
2 | "virtualServiceName": $VIRTUAL_SERVICE_NAME,
3 | "spec": {
4 | "provider": {
5 | "virtualNode": {
6 | "virtualNodeName": "color-node"
7 | }
8 | }
9 | }
10 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-outlier-detection/src/color-app/.gitignore:
--------------------------------------------------------------------------------
1 | color-app
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-outlier-detection/src/color-app/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-outlier-detection/src/color-app
2 |
3 | go 1.14
4 |
5 | require github.com/google/uuid v1.1.2
6 |
--------------------------------------------------------------------------------
/walkthroughs/howto-outlier-detection/src/color-app/go.sum:
--------------------------------------------------------------------------------
1 | github.com/google/uuid v1.1.2 h1:EVhdT+1Kseyi1/pUmXKaFxYsDNy9RQYkMWRH68J/W7Y=
2 | github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
3 |
--------------------------------------------------------------------------------
/walkthroughs/howto-outlier-detection/src/frontend-app/.gitignore:
--------------------------------------------------------------------------------
1 | frontend-app
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-outlier-detection/src/frontend-app/go.mod:
--------------------------------------------------------------------------------
1 | module github.com/aws/aws-app-mesh-examples/walkthroughs/howto-outlier-detection/src/frontend-app
2 |
3 | go 1.14
4 |
--------------------------------------------------------------------------------
/walkthroughs/howto-outlier-detection/src/frontend-app/go.sum:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-outlier-detection/src/frontend-app/go.sum
--------------------------------------------------------------------------------
/walkthroughs/howto-servicediscovery-cloudmap/deploy-images.sh:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 |
3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
4 | APP_DIR="${DIR}/../../examples/apps/colorapp"
5 |
6 | ${APP_DIR}/src/colorteller/deploy.sh
7 | echo "Done deploying color/teller docker image"
8 |
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/howto-timeout-with-gateway.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/aws/aws-app-mesh-examples/107deee107ec032f1fb55623660b3e797bae0d96/walkthroughs/howto-timeout-policy/howto-timeout-with-gateway.png
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/infrastructure/ecr-repositories.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecr-repositories" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecr-repositories.yaml" \
12 | --parameter-overrides \
13 | GatewayImageName="${COLOR_GATEWAY_IMAGE_NAME}" \
14 | ColorTellerImageName="${COLOR_TELLER_IMAGE_NAME}"
15 |
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/infrastructure/ecr-repositories.yaml:
--------------------------------------------------------------------------------
1 | Parameters:
2 |
3 | GatewayImageName:
4 | Description: The name for the gateway image
5 | Type: String
6 |
7 | ColorTellerImageName:
8 | Description: The name for the color teller image
9 | Type: String
10 |
11 |
12 | Resources:
13 | GatewayRepository:
14 | Type: AWS::ECR::Repository
15 | Properties:
16 | RepositoryName: !Ref GatewayImageName
17 |
18 | ColorTellerRepository:
19 | Type: AWS::ECR::Repository
20 | Properties:
21 | RepositoryName: !Ref ColorTellerImageName
22 |
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/infrastructure/ecs-cluster.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecs-cluster" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecs-cluster.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | KeyName="${KEY_PAIR_NAME}" \
15 | ECSServicesDomain="${SERVICES_DOMAIN}"
16 |
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/infrastructure/vpc.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-vpc" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/vpc.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/mesh/colorgateway-vn.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 80,
7 | "protocol": "http"
8 | }
9 | }
10 | ],
11 | "serviceDiscovery": {
12 | "dns": {
13 | "hostname": $DNS_HOSTNAME
14 | }
15 | },
16 | "backends": [
17 | {
18 | "virtualService": {
19 | "virtualServiceName": $COLOR_TELLER_VS
20 | }
21 | }
22 | ]
23 | }
24 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/mesh/colorteller-route-timeout20s.json:
--------------------------------------------------------------------------------
1 | {
2 | "virtualRouterName": "colorteller-vr",
3 | "routeName": "colorteller-route",
4 | "spec": {
5 | "priority": 1,
6 | "httpRoute": {
7 | "action": {
8 | "weightedTargets": [
9 | {
10 | "virtualNode": "ColorTellerWhite",
11 | "weight": 1
12 | }
13 | ]
14 | },
15 | "match": {
16 | "prefix": "/"
17 | },
18 | "timeout" : {
19 | "perRequest": {
20 | "value" : 20,
21 | "unit" : "s"
22 | }
23 | }
24 |
25 | }
26 | }
27 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/mesh/colorteller-route-timeout5s.json:
--------------------------------------------------------------------------------
1 | {
2 | "virtualRouterName": "colorteller-vr",
3 | "routeName": "colorteller-route",
4 | "spec": {
5 | "priority": 1,
6 | "httpRoute": {
7 | "action": {
8 | "weightedTargets": [
9 | {
10 | "virtualNode": "ColorTellerWhite",
11 | "weight": 1
12 | }
13 | ]
14 | },
15 | "match": {
16 | "prefix": "/"
17 | },
18 | "timeout" : {
19 | "perRequest": {
20 | "value" : 5,
21 | "unit" : "s"
22 | }
23 | }
24 | }
25 | }
26 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/mesh/colorteller-route.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute": {
4 | "action": {
5 | "weightedTargets": [
6 | {
7 | "virtualNode": "ColorTellerWhite",
8 | "weight": 1
9 | }
10 | ]
11 | },
12 | "match": {
13 | "prefix": "/"
14 | }
15 | }
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/mesh/colorteller-route1-timeout18s.json:
--------------------------------------------------------------------------------
1 | {
2 | "virtualRouterName": "colorteller-vr",
3 | "routeName": "colorteller-route",
4 | "spec": {
5 | "priority": 1,
6 | "httpRoute": {
7 | "action": {
8 | "weightedTargets": [
9 | {
10 | "virtualNode": "ColorTellerWhite",
11 | "weight": 1
12 | }
13 | ]
14 | },
15 | "match": {
16 | "prefix": "/color1"
17 | },
18 | "timeout" : {
19 | "perRequest": {
20 | "value" : 18,
21 | "unit" : "s"
22 | }
23 | }
24 | }
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/mesh/colorteller-route1.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute": {
4 | "action": {
5 | "weightedTargets": [
6 | {
7 | "virtualNode": "ColorTellerWhite",
8 | "weight": 1
9 | }
10 | ]
11 | },
12 | "match": {
13 | "prefix": "/color1"
14 | }
15 | }
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/mesh/colorteller-route2.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute": {
4 | "action": {
5 | "weightedTargets": [
6 | {
7 | "virtualNode": "ColorTellerRed",
8 | "weight": 1
9 | }
10 | ]
11 | },
12 | "match": {
13 | "prefix": "/color2"
14 | }
15 | }
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/mesh/colorteller-vr.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 80,
7 | "protocol": "http"
8 | }
9 | }
10 | ]
11 | }
12 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/mesh/colorteller-vs.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "provider": {
4 | "virtualRouter": {
5 | "virtualRouterName": "colorteller-vr"
6 | }
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/mesh/mesh.json:
--------------------------------------------------------------------------------
1 | {}
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/mesh/publicgateway-route.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "httpRoute" : {
4 | "match" : {
5 | "prefix" : "/"
6 | },
7 | "action" : {
8 | "target" : {
9 | "virtualService": {
10 | "virtualServiceName": $VIRTUALSERVICE_NAME
11 | }
12 | }
13 | }
14 | }
15 | }
16 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/mesh/publicgateway-vg.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec": {
3 | "listeners": [
4 | {
5 | "portMapping": {
6 | "port": 80,
7 | "protocol": "http"
8 | }
9 | }
10 | ]
11 | }
12 | }
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/src/colorgateway/.gitignore:
--------------------------------------------------------------------------------
1 | colorgateway
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-timeout-policy/src/colorteller/.gitignore:
--------------------------------------------------------------------------------
1 | colorteller
2 |
--------------------------------------------------------------------------------
/walkthroughs/howto-tls-file-provided/.gitignore:
--------------------------------------------------------------------------------
1 | *.crt
2 | *.key
3 | *.csr
4 | *.pem
5 | *.srl
6 | *.generated
--------------------------------------------------------------------------------
/walkthroughs/howto-tls-file-provided/infrastructure/ecr-repositories.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecr-repositories" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecr-repositories.yaml" \
12 | --parameter-overrides \
13 | ColorTellerImageName="${COLOR_TELLER_IMAGE_NAME}" \
14 | ColorAppEnvoyImageName="${COLOR_APP_ENVOY_IMAGE_NAME}"
15 |
--------------------------------------------------------------------------------
/walkthroughs/howto-tls-file-provided/infrastructure/ecr-repositories.yaml:
--------------------------------------------------------------------------------
1 | Parameters:
2 |
3 | ColorTellerImageName:
4 | Description: The name for the color teller image
5 | Type: String
6 |
7 | ColorAppEnvoyImageName:
8 | Description: The name for the color app envoy image
9 | Type: String
10 |
11 | Resources:
12 |
13 | ColorTellerRepository:
14 | Type: AWS::ECR::Repository
15 | Properties:
16 | RepositoryName: !Ref ColorTellerImageName
17 |
18 | ColorTellerEnvoyRepository:
19 | Type: AWS::ECR::Repository
20 | Properties:
21 | RepositoryName: !Ref ColorAppEnvoyImageName
22 |
--------------------------------------------------------------------------------
/walkthroughs/howto-tls-file-provided/infrastructure/ecs-cluster.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecs-cluster" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecs-cluster.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | KeyName="${KEY_PAIR_NAME}" \
15 | ECSServicesDomain="${SERVICES_DOMAIN}"
16 |
--------------------------------------------------------------------------------
/walkthroughs/howto-tls-file-provided/infrastructure/vpc.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-vpc" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/vpc.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/howto-tls-file-provided/src/colorteller/.gitignore:
--------------------------------------------------------------------------------
1 | colorteller
2 |
--------------------------------------------------------------------------------
/walkthroughs/tls-with-acm/.gitignore:
--------------------------------------------------------------------------------
1 | *.pem
2 | *.srl
--------------------------------------------------------------------------------
/walkthroughs/tls-with-acm/infrastructure/ecr-repositories.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecr-repositories" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecr-repositories.yaml" \
12 | --parameter-overrides \
13 | ColorTellerImageName="${COLOR_TELLER_IMAGE_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/tls-with-acm/infrastructure/ecr-repositories.yaml:
--------------------------------------------------------------------------------
1 | Parameters:
2 |
3 | ColorTellerImageName:
4 | Description: The name for the color teller image
5 | Type: String
6 |
7 |
8 | Resources:
9 |
10 | ColorTellerRepository:
11 | Type: AWS::ECR::Repository
12 | Properties:
13 | RepositoryName: !Ref ColorTellerImageName
14 |
--------------------------------------------------------------------------------
/walkthroughs/tls-with-acm/infrastructure/ecs-cluster.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-ecs-cluster" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/ecs-cluster.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}" \
14 | KeyName="${KEY_PAIR_NAME}" \
15 | ECSServicesDomain="${SERVICES_DOMAIN}"
16 |
--------------------------------------------------------------------------------
/walkthroughs/tls-with-acm/infrastructure/vpc.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-vpc" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/vpc.yaml" \
12 | --parameter-overrides \
13 | EnvironmentName="${ENVIRONMENT_NAME}"
14 |
--------------------------------------------------------------------------------
/walkthroughs/tls-with-acm/mesh/mesh.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -ex
4 |
5 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
6 |
7 | aws --profile "${AWS_PROFILE}" --region "${AWS_DEFAULT_REGION}" \
8 | cloudformation deploy \
9 | --stack-name "${ENVIRONMENT_NAME}-mesh" \
10 | --capabilities CAPABILITY_IAM \
11 | --template-file "${DIR}/mesh.yaml" \
12 | --parameter-overrides \
13 | MeshName="${MESH_NAME}" \
14 | ServicesDomain="${SERVICES_DOMAIN}" \
15 | CertificateAuthorityArn="${ROOT_CA_ARN}" \
16 | CertificateArn="${CERTIFICATE_ARN}"
17 |
--------------------------------------------------------------------------------
/walkthroughs/tls-with-acm/src/colorteller/.gitignore:
--------------------------------------------------------------------------------
1 | colorteller
2 |
--------------------------------------------------------------------------------