Loading .gitlab-ci.yml +27 −0 Changes for .gitlab-ci.yml: 27 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -130,6 +130,14 @@ images: rename=$(echo "${base_rename}" | cut -d'|' -f2 | tr -d ' ') image="${REGISTRY_HOST}/${REGISTRY_NAMESPACE}/${REGISTRY_PROJECT}/${rename:-${base}}" if [ -z "${IMAGE}" ] || echo "${image}" | grep -q "${IMAGE}"; then base_local='false' image_local='false' if docker images -q "${base}" 2>/dev/null | grep -q '.'; then base_local='true' fi if docker images -q "${image}" 2>/dev/null | grep -q '.'; then image_local='true' fi echo ' ' echo " [INFO] Pull: ${base}" echo ' ' Loading @@ -139,8 +147,13 @@ images: echo " [INFO] Push: ${image}" echo ' ' docker push "${image}" || true if [ ! -z "${CI_LOCAL:-}" ] && [ "${base_local}" = 'false' ]; then docker rmi "${base}" >/dev/null || true fi if [ ! -z "${CI_LOCAL:-}" ] && [ "${image_local}" = 'false' ]; then docker rmi "${image}" >/dev/null || true fi fi done # Prepare project images - | Loading @@ -164,6 +177,14 @@ images: base="${REGISTRY_HOST}/${REGISTRY_NAMESPACE}/${REGISTRY_PROJECT}/${base}" image="${REGISTRY_HOST}/${REGISTRY_NAMESPACE}/${REGISTRY_PROJECT}/${REGISTRY_PROJECT}:${name}" if [ -z "${IMAGE}" ] || echo "${image}" | grep -q "${IMAGE}"; then base_local='false' image_local='false' if docker images -q "${base}" 2>/dev/null | grep -q '.'; then base_local='true' fi if docker images -q "${image}" 2>/dev/null | grep -q '.'; then image_local='true' fi echo ' ' echo " [INFO] Pull: ${image}" echo ' ' Loading @@ -180,6 +201,12 @@ images: echo " [INFO] Push: ${image}" echo ' ' docker push "${image}" || true if [ ! -z "${CI_LOCAL:-}" ] && [ "${base_local}" = 'false' ]; then docker rmi "${base}" >/dev/null || true fi if [ ! -z "${CI_LOCAL:-}" ] && [ "${image_local}" = 'false' ]; then docker rmi "${image}" >/dev/null || true fi fi done rules: Loading Loading
.gitlab-ci.yml +27 −0 Changes for .gitlab-ci.yml: 27 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -130,6 +130,14 @@ images: rename=$(echo "${base_rename}" | cut -d'|' -f2 | tr -d ' ') image="${REGISTRY_HOST}/${REGISTRY_NAMESPACE}/${REGISTRY_PROJECT}/${rename:-${base}}" if [ -z "${IMAGE}" ] || echo "${image}" | grep -q "${IMAGE}"; then base_local='false' image_local='false' if docker images -q "${base}" 2>/dev/null | grep -q '.'; then base_local='true' fi if docker images -q "${image}" 2>/dev/null | grep -q '.'; then image_local='true' fi echo ' ' echo " [INFO] Pull: ${base}" echo ' ' Loading @@ -139,8 +147,13 @@ images: echo " [INFO] Push: ${image}" echo ' ' docker push "${image}" || true if [ ! -z "${CI_LOCAL:-}" ] && [ "${base_local}" = 'false' ]; then docker rmi "${base}" >/dev/null || true fi if [ ! -z "${CI_LOCAL:-}" ] && [ "${image_local}" = 'false' ]; then docker rmi "${image}" >/dev/null || true fi fi done # Prepare project images - | Loading @@ -164,6 +177,14 @@ images: base="${REGISTRY_HOST}/${REGISTRY_NAMESPACE}/${REGISTRY_PROJECT}/${base}" image="${REGISTRY_HOST}/${REGISTRY_NAMESPACE}/${REGISTRY_PROJECT}/${REGISTRY_PROJECT}:${name}" if [ -z "${IMAGE}" ] || echo "${image}" | grep -q "${IMAGE}"; then base_local='false' image_local='false' if docker images -q "${base}" 2>/dev/null | grep -q '.'; then base_local='true' fi if docker images -q "${image}" 2>/dev/null | grep -q '.'; then image_local='true' fi echo ' ' echo " [INFO] Pull: ${image}" echo ' ' Loading @@ -180,6 +201,12 @@ images: echo " [INFO] Push: ${image}" echo ' ' docker push "${image}" || true if [ ! -z "${CI_LOCAL:-}" ] && [ "${base_local}" = 'false' ]; then docker rmi "${base}" >/dev/null || true fi if [ ! -z "${CI_LOCAL:-}" ] && [ "${image_local}" = 'false' ]; then docker rmi "${image}" >/dev/null || true fi fi done rules: Loading