terraform config for MWAA
https://github.com/hashicorp/terraform-provider-aws/releases/tag/v3.36.0
terraform plan -var-file=vars.tfvars
terraform apply -var-file=vars.tfvars
#!/usr/bin/env bash | |
set -euo pipefail | |
AZURE_RESOURCE_GROUP=$1 | |
CLUSTER_NAME=$2 | |
LOCATION=$3 | |
AZURE_NODEGROUP=$(az aks show -n ${CLUSTER_NAME} -g ${AZURE_RESOURCE_GROUP} -o tsv --query nodeResourceGroup) |
user www-data; | |
worker_processes auto; | |
pid /run/nginx.pid; | |
worker_rlimit_nofile 65535; | |
events { worker_connections 10000; } | |
http { | |
map $http_upgrade $connection_upgrade { | |
default upgrade; | |
‘’ close; |
# Start w/ a data source to get a list of all the workspaces | |
# See: https://www.terraform.io/docs/providers/tfe/d/workspace_ids.html | |
data "tfe_workspace_ids" "all-workspaces" { | |
names = ["*"] | |
organization = "my-org-name" | |
} | |
# Look up the ID of the teamn you're looking to map | |
# See: https://www.terraform.io/docs/providers/tfe/d/team.html | |
data "tfe_team" "architects" { |
________ ________ ___ __ ___ | |
|\_____ \|\ __ \|\ \|\ \ |\ \ | |
\|___/ /\ \ \|\ \ \ \/ /|\ \ \ | |
/ / /\ \ __ \ \ ___ \ \ \ | |
/ /_/__\ \ \ \ \ \ \\ \ \ \ \ | |
|\________\ \__\ \__\ \__\\ \__\ \__\ | |
\|_______|\|__|\|__|\|__| \|__|\|__| | |
ignore Azure, GCP |
# Measure traffic with tcpstat | |
tcpstat -i em1 -o "%r\t%b\n" -s 30 0.1 > traffic.txt | |
# Create plot using the below script | |
gnuplot traffic.script > traffic.png | |
# Display plot | |
qlmanage -p 2>/dev/null traffic.png |
#!/bin/bash | |
set -e | |
REGION=$(curl -s http://169.254.169.254/latest/meta-data/placement/region) | |
INSTANCE_ID=$(curl -s http://169.254.169.254/latest/meta-data/instance-id) | |
VOLUME_NAME=$1 | |
VOLUME_DEVICE=$2 | |
VOLUME_ID=$(aws ec2 describe-volumes --filters "Name=tag:Name,Values=${VOLUME_NAME}" --region "${REGION}" | jq -r .Volumes[0].VolumeId) |
terraform config for MWAA
https://github.com/hashicorp/terraform-provider-aws/releases/tag/v3.36.0
terraform plan -var-file=vars.tfvars
terraform apply -var-file=vars.tfvars
#!/usr/bin/env bash | |
cmd=$1 | |
chart=$2 | |
env=$3 | |
dir=${chart}-kustomize | |
chart=${chart/.\//} | |
build() { |
#!/usr/bin/env bash | |
set -e | |
if eksctl get cluster -f $FILE >/dev/null 2>&1; then | |
# See https://github.com/weaveworks/eksctl/blob/33ec1ed967c1ad03c985bf18774ea970d85c86f1/site/content/usage/03-cluster-upgrade.md#L41 | |
eksctl update cluster -f $FILE | |
eksctl utils update-kube-proxy | |
eksctl utils update-aws-node | |
eksctl utils update-coredns |