Infrastructure-as-Code using HCL manifests to define cloud resources.
Idempotent, queries cloud APIs, detects what is missing or has changed and then applies the necessary changes to reconcile.
| name: Terraform Plan | |
| on: | |
| push: | |
| branches: | |
| - main | |
| - staging | |
| - prod | |
| pull_request: | |
| branches: |
Infrastructure-as-Code using HCL manifests to define cloud resources.
Idempotent, queries cloud APIs, detects what is missing or has changed and then applies the necessary changes to reconcile.
A curated list of things related to GitHub Actions.
Actions are triggered by GitHub platform events directly in a repo and run on-demand workflows either on Linux, Windows or macOS virtual machines or inside a container in response. With GitHub Actions you can automate your workflow from idea to production.
| # ls aliases | |
| alias ll='ls -alF' | |
| alias la='ls -A' | |
| alias l='ls -CF' | |
| # aws-cli | |
| alias gac='gimme-aws-creds' | |
| # apt pacakge manager | |
| alias install='sudo apt install -y' | |
| alias purge='sudo apt purge -y' |
| name: "Terraform" | |
| concurrency: | |
| group: "single" | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] |
| name: 'Terraform' | |
| on: | |
| push: | |
| branches: | |
| - master | |
| paths: | |
| - ".github/workflows/terraform.yaml" | |
| - "terraform/**" | |
| pull_request: |
| # Checkout a specific PR number, then change folder to one of the folders based on the changed files | |
| function gh-checkout() { | |
| local pr_number repo_folder first_commit parent_commit folders | |
| pr_number=$1 | |
| repo_folder=$(git rev-parse --show-toplevel) | |
| gh pr checkout "$pr_number" || return | |
| first_commit=$(gh pr view "$pr_number" --json commits | jq -r .commits[0].oid) | |
| parent_commit=$(git show --no-patch --format="%P" "$first_commit") |
| name: Setup Terraform via GitHub Actions | |
| # Source: https://github.com/marketplace/actions/hashicorp-setup-terraform | |
| on: [push, pull_request] | |
| #on: | |
| # push: | |
| # branches: | |
| # - main | |
| env: |