2 # This script guesses some environment variables based on the builder name and
3 # the current platform, to reduce the amount of variables defined in the CI
9 source "$(cd "$(dirname "$0")" && pwd)/../shared.sh"
11 # Builders starting with `dist-` are dist builders, but if they also end with
12 # `-alt` they are alternate dist builders.
13 if [[ "${CI_JOB_NAME}" = dist-* ]]; then
14 if [[ "${CI_JOB_NAME}" = *-alt ]]; then
15 echo "alternate dist builder detected, setting DEPLOY_ALT=1"
16 ciCommandSetEnv DEPLOY_ALT 1
18 echo "normal dist builder detected, setting DEPLOY=1"
19 ciCommandSetEnv DEPLOY 1
23 # All the Linux builds happen inside Docker.
25 if [[ -z "${IMAGE+x}" ]]; then
26 echo "linux builder detected, using docker to run the build"
27 ciCommandSetEnv IMAGE "${CI_JOB_NAME}"
29 echo "a custom docker image is already set"