diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2dc098c2ac47385da009120a3307968100c0383b..ead413ede8ffe2ac868df2fe101507fa0eaafdfd 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,7 +1,31 @@ +# YAML anchors +# +# We don't use a `before_script` definition here because `extend` doesn't merge +# `before_script` but rather overwrites it. +# So we rather use [yaml anchors for script](https://docs.gitlab.com/ce/ci/yaml/README.html#yaml-anchors-for-script) +# here. Unfortunatly, anchors can't get included from files so we need to +# define them here. +.debug_information: &debug_information + - | + echo "Env vars:" + echo + echo "HOSTNAME: $HOSTNAME" + echo "SUBDOMAIN: $SUBDOMAIN" + echo "DOMAIN: $DOMAIN" + echo "FQDN: $FQDN" + echo "CLUSTER_DIR: $CLUSTER_DIR" + echo "ANSIBLE_HOST_KEY_CHECKING: $ANSIBLE_HOST_KEY_CHECKING" + echo "KANIKO_BUILD_IMAGENAME: $KANIKO_BUILD_IMAGENAME" + echo "SSH_KEY_ID: $SSH_KEY_ID" + echo + [ -d $CLUSTER_DIR ] && find $CLUSTER_DIR || echo "directory ${CLUSTER_DIR} not found" + echo + echo + include: - .gitlab/ci_templates/kaniko.yml - .gitlab/ci_templates/ssh_setup.yml - - .gitlab/ci_templates/debug_information.yml + stages: - build - create-vps diff --git a/.gitlab/ci_templates/debug_information.yml b/.gitlab/ci_templates/debug_information.yml deleted file mode 100644 index c8e89aff01746ab02f5e7364061b75ec5aef1e8f..0000000000000000000000000000000000000000 --- a/.gitlab/ci_templates/debug_information.yml +++ /dev/null @@ -1,21 +0,0 @@ -# We don't use a `before_script` definition here because `extend` doesn't merge -# `before_script` but rather overwrites it. -# So we rather use [yaml anchors for script](https://docs.gitlab.com/ce/ci/yaml/README.html#yaml-anchors-for-script) -# here. - -.debug_information: &debug_information - - | - echo "Env vars:" - echo - echo "HOSTNAME: $HOSTNAME" - echo "SUBDOMAIN: $SUBDOMAIN" - echo "DOMAIN: $DOMAIN" - echo "FQDN: $FQDN" - echo "CLUSTER_DIR: $CLUSTER_DIR" - echo "ANSIBLE_HOST_KEY_CHECKING: $ANSIBLE_HOST_KEY_CHECKING" - echo "KANIKO_BUILD_IMAGENAME: $KANIKO_BUILD_IMAGENAME" - echo "SSH_KEY_ID: $SSH_KEY_ID" - echo - [ -d $CLUSTER_DIR ] && find $CLUSTER_DIR || echo "directory ${CLUSTER_DIR} not found" - echo - echo