This file contains 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
#!/usr/bin/env bash | |
set -euo pipefail | |
# Support aborting via SIGINT, without this bash will not exit the for loop until it's finished | |
trap 'exit 0' INT | |
# Usage example: | |
# bash migrate-state.sh '/home/myuser/terraform/destination-module' '/home/myuser/terraform/source-module' 'module.source' 'config/dev_backend.tfvars' 'config/dev_backend.tfvars' | |
# Arguments: | |
# $1 - destinationModuleDirectory: The directory in which the module resides where state should be moved to |
This file contains 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
#!/usr/bin/env bash | |
# Usage: See help | |
# $ bash mutagen.sh --help | |
COMPOSE_PROJECT_NAME=drupal | |
SYNC_APPDATA_SOURCE=. | |
SYNC_APPDATA=${COMPOSE_PROJECT_NAME}-appdata | |
SYNC_APPDATA_DRUPAL=${SYNC_APPDATA}-drupal |
This file contains 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
# Configuration for local development | |
version: "3.7" | |
services: | |
# MySQL | |
# ----- | |
db: | |
image: bitnami/mysql:latest | |
ports: | |
- '127.0.0.1:3307:3306' |
This file contains 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
#!/usr/bin/env bash | |
set -e | |
start=$(date +%s) | |
git clone ${GIT_REPOSITORY_URL} git-repo | |
end=$(date +%s) | |
runtime=$((end-start)) | |
printf 'Git clone time: %s seconds\n' "${runtime}" |
This file contains 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
#!/usr/bin/env bash | |
set -euo pipefail | |
# Parameters | |
# $1: The scheme and host of the site for which the cache should be warmed | |
warmCache () { | |
# E.g. https://www.example.com | |
local schemeAndHost="${1:?'The schemeAndHost parameter is missing'}" |