This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| init: | |
| colima start argocd-selfmanaged --kubernetes | |
| kubectl-get-nodes: | |
| kubectl get nodes | |
| kubectl get pods -A | |
| kubectl-apply-argocd: | |
| kubectl create namespace argocd | |
| kubectl apply -n argocd -f https://raw.githubusercontent.com/argoproj/argo-cd/stable/manifests/install.yaml |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| target: | |
| SELECTED=`cat main.tf | grep resource | tr -d '"' | awk '{ print $$2 "." $$3 }' | fzf` ; \ | |
| terraform apply -target=$$SELECTED |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "encoding/json" | |
| "os" | |
| "path/filepath" | |
| ) | |
| const ( | |
| output = "shortcuts" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "aws-cli-reference": "https://docs.aws.amazon.com/cli/latest/reference/index.html", | |
| "aws-cli-acm": "https://docs.aws.amazon.com/cli/latest/reference/acm/index.html", | |
| "aws-cli-acm-pca": "https://docs.aws.amazon.com/cli/latest/reference/acm-pca/index.html", | |
| "aws-cli-alexaforbusiness": "https://docs.aws.amazon.com/cli/latest/reference/alexaforbusiness/index.html", | |
| "aws-cli-amplify": "https://docs.aws.amazon.com/cli/latest/reference/amplify/index.html", | |
| "aws-cli-apigateway": "https://docs.aws.amazon.com/cli/latest/reference/apigateway/index.html", | |
| "aws-cli-apigatewaymanagementapi": "https://docs.aws.amazon.com/cli/latest/reference/apigatewaymanagementapi/index.html", | |
| "aws-cli-apigatewayv2": "https://docs.aws.amazon.com/cli/latest/reference/apigatewayv2/index.html", | |
| "aws-cli-application-autoscaling": "https://docs.aws.amazon.com/cli/latest/reference/application-autoscaling/index.html", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "fmt" | |
| "os/exec" | |
| "strings" | |
| "strconv" | |
| "net" | |
| ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # terraform.vars | |
| rules = [ | |
| { | |
| api_groups = [""] | |
| resources = ["pods","services","deployments","jobs"] | |
| verbs = ["*"] | |
| }, | |
| { | |
| api_groups = [""] | |
| resources = ["namespaces"] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| apiVersion: v1 | |
| kind: ServiceAccount | |
| metadata: | |
| name: myapp | |
| namespace: mynamespace | |
| --- | |
| kind: ClusterRole | |
| apiVersion: rbac.authorization.k8s.io/v1 | |
| metadata: | |
| namespace: mynamespace |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| locals { | |
| policies_arns = { | |
| for item in aws_iam_policy.policy : | |
| item.name => item.arn | |
| } | |
| users_attachment = distinct( | |
| flatten([ | |
| for item in var.policies : [ | |
| for user in item.users_to_attach : { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # terraform.tfvars | |
| policies = [ | |
| { | |
| policy_name = "policy-alpha", | |
| roles_to_attach = [] | |
| users_to_attach = ["user1", "user2"] | |
| content = {} | |
| }, | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # variables.tf | |
| variable "myapp_conf" { | |
| type = map | |
| } | |
| # terraform.tfvars | |
| myapp_conf = { | |
| REPLICAS = 0 | |
| LIMIT_CPU = "50m" | |
| LIMIT_MEMORY = "96Mi" |
NewerOlder