Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/scripts/install-node.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
#!/bin/bash
set -o errexit
set -o pipefail
set -o nounset

VERSION=${1:-"16"}
CMD=node
NAME="Node.js"
Expand Down
1 change: 1 addition & 0 deletions .github/scripts/run-tests.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#!/bin/bash
set -o errexit
set -o pipefail
set -o nounset

DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"

Expand Down
4 changes: 3 additions & 1 deletion cli/scripts/build.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#!/bin/bash
set -e
set -o errexit
set -o pipefail
set -o nounset


echo "Cleaning build/dist folders..."
Expand Down
4 changes: 3 additions & 1 deletion core/terraform/compare_plans.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#!/bin/bash
set -e
set -o errexit
set -o pipefail
set -o nounset

# if no arguments are provided, return usage function
if [[ $# -ne 2 || -z $1 || -z $2 ]]; then
Expand Down
4 changes: 3 additions & 1 deletion core/terraform/json-to-env.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#!/bin/bash
set -e
set -o errexit
set -o pipefail
set -o nounset

echo "# Generated environment variables from tf output"

Expand Down
4 changes: 3 additions & 1 deletion core/terraform/outputs.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#!/bin/bash
set -e
set -o errexit
set -o pipefail
set -o nounset

# shellcheck disable=SC1091
source ../../devops/scripts/mgmtstorage_enable_public_access.sh
Expand Down
3 changes: 3 additions & 0 deletions core/terraform/scripts/auth-hook.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
set -o errexit
set -o pipefail
set -o nounset

cat << EOF > 'validation.txt'
${CERTBOT_VALIDATION}
Expand Down
3 changes: 3 additions & 0 deletions core/terraform/scripts/cleanup-hook.sh
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
#!/bin/bash
set -o errexit
set -o pipefail
set -o nounset
4 changes: 3 additions & 1 deletion core/terraform/scripts/letsencrypt.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#!/bin/bash
set -e
set -o errexit
set -o pipefail
set -o nounset

script_dir=$(realpath "$(dirname "${BASH_SOURCE[0]}")")

Expand Down
3 changes: 3 additions & 0 deletions devops/scripts/aad/grant_admin_consent.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
set -o errexit
set -o pipefail
set -o nounset

# This script is designed to be `source`d to create reusable helper functions

Expand Down
3 changes: 3 additions & 0 deletions devops/scripts/aad/update_resource_access.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
set -o errexit
set -o pipefail
set -o nounset

# This script is designed to be `source`d to create reusable helper functions

Expand Down
3 changes: 3 additions & 0 deletions devops/scripts/aad/wait_for_new_service_principal.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
set -o errexit
set -o pipefail
set -o nounset

# This script is designed to be `source`d to create reusable helper functions

Expand Down
4 changes: 3 additions & 1 deletion devops/scripts/api_healthcheck.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
#!/bin/bash
# This script checks if the api server endpoint /api/health is available(response code 200) and then verifies that the response contains all OK
# Both verifications have a retry(4 retries, including call above makes total 5 calls).
set -e
set -o errexit
set -o pipefail
set -o nounset

# Get the directory that this script is in
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
Expand Down
3 changes: 3 additions & 0 deletions devops/scripts/bash_trap_helper.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
set -o errexit
set -o pipefail
set -o nounset

#
# allows multiple commands to be registered and called on shell exit
Expand Down
4 changes: 0 additions & 4 deletions devops/scripts/check_dependencies.sh
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,3 @@ fi
echo -e "\e[34m»»» 🔨 \e[96mAzure details from logged on user \e[0m"
echo -e "\e[34m»»» • \e[96mSubscription: \e[33m$SUB_NAME\e[0m"
echo -e "\e[34m»»» • \e[96mTenant: \e[33m$TENANT_ID\e[0m\n"

# This shouldn't be here but since other scripts don't use this option we must reset it.
# For tracking: https://github.com/microsoft/AzureTRE/issues/1672
set +o nounset
3 changes: 3 additions & 0 deletions devops/scripts/construct_tre_url.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
set -o errexit
set -o pipefail
set -o nounset

# This script is designed to be `source`d to create reusable helper functions

Expand Down
3 changes: 3 additions & 0 deletions devops/scripts/convert_azure_env_to_arm_env.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
set -o errexit
set -o pipefail
set -o nounset

# This script is designed to be `source`d to create reusable helper functions

Expand Down
3 changes: 0 additions & 3 deletions devops/scripts/env_to_yaml_config.sh
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,3 @@ do
fi
done < <(grep -v -e '^[[:space:]]*$' -e '^#' "$f" )
done


set +o nounset
1 change: 1 addition & 0 deletions devops/scripts/get_access_token.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

set -o errexit
set -o pipefail
set -o nounset
# Uncomment this line to see each command for debugging (careful: this will show secrets!)
# set -o xtrace

Expand Down
3 changes: 3 additions & 0 deletions devops/scripts/kv_add_network_exception.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
set -o errexit
set -o pipefail
set -o nounset

#
# Temporarily set Key Vault to public access for deployment, and restore to private on script exit
Expand Down
2 changes: 0 additions & 2 deletions devops/scripts/load_and_validate_env.sh
Original file line number Diff line number Diff line change
Expand Up @@ -100,5 +100,3 @@ if [ -f "$DIR/../../core/private.env" ]; then
KEY_VAULT_URL=$KEYVAULT_URI
export KEY_VAULT_URL
fi

set +o nounset
3 changes: 0 additions & 3 deletions devops/scripts/load_env.sh
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,3 @@ else
export "${tf_name?}"
done < <(grep -v -e '^[[:space:]]*$' -e '^#' "$1" ) # feed in via Process Substition to avoid bash subshell (http://mywiki.wooledge.org/ProcessSubstitution)
fi


set +o nounset
3 changes: 3 additions & 0 deletions devops/scripts/mgmtacr_enable_public_access.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
set -o errexit
set -o pipefail
set -o nounset

#
# Add an exception to the TRE management ACR by making it public for deployment, and remove it on script exit.
Expand Down
3 changes: 3 additions & 0 deletions devops/scripts/mgmtstorage_enable_public_access.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
set -o errexit
set -o pipefail
set -o nounset

#
# Add an exception to the TRE management storage account by making it public for deployment, and remove it on script exit.
Expand Down
3 changes: 3 additions & 0 deletions devops/scripts/porter_build_bundle.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
set -o errexit
set -o pipefail
set -o nounset

if [ -f "porter-build-context.env" ]; then

Expand Down
1 change: 1 addition & 0 deletions devops/scripts/porter_local_env.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

set -o errexit
set -o pipefail
set -o nounset
# set -o xtrace

while read -r env_var_name; do
Expand Down
1 change: 1 addition & 0 deletions devops/scripts/register_bundle_with_api.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

set -o errexit
set -o pipefail
set -o nounset
# Uncomment this line to see each command for debugging (careful: this will show secrets!)
# set -o xtrace

Expand Down
4 changes: 3 additions & 1 deletion devops/scripts/set_docker_sock_permission.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#!/bin/bash
set -e
set -o errexit
set -o pipefail
set -o nounset

# By default the docker.sock file is not associated with docker group on codespaces or macOS
# which causes a permission issue when docker is run without sudo.
Expand Down
4 changes: 3 additions & 1 deletion devops/scripts/terraform_upgrade_provider.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#!/bin/bash
set -e
set -o errexit
set -o pipefail
set -o nounset

# This script is used to upgrade terraform providers in a specified directory

Expand Down
4 changes: 3 additions & 1 deletion devops/scripts/terraform_wrapper.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#!/bin/bash
set -e
set -o errexit
set -o pipefail
set -o nounset

function usage() {
cat <<USAGE
Expand Down
Loading