gitlab-ci-training icon indicating copy to clipboard operation
gitlab-ci-training copied to clipboard

add example except/variables

Open ondrejsika opened this issue 3 years ago • 0 comments

# .gitlab-ci.yml

stages:
  - build
  - test
  - deploy

build:
  stage: build
  script: echo build && sleep 10
  except:
    variables:
      - $SKIP_STAGE_build == "1" && $SKIP_BRANCH == $CI_COMMIT_REF_NAME

test:
  stage: test
  script: echo test && sleep 10
  except:
    variables:
      - $SKIP_STAGE_test == "1" && $SKIP_BRANCH == $CI_COMMIT_REF_NAME

deploy:
  stage: deploy
  script: echo deploy
  except:
    variables:
      - $SKIP_STAGE_deploy == "1" && $SKIP_BRANCH == $CI_COMMIT_REF_NAME

ondrejsika avatar Nov 18 '21 10:11 ondrejsika