我正在尝试使用Gitlab建立CI/CD管道以下是我想要做的事情:
注意:这是一个打字稿项目
这是.gitlab-ci.yml我正在使用的(i:
stages:
- test
- promote
- build
- deploy
cache:
paths:
- node_modules/
test:
image: node
stage: test
before_script:
- yarn
script:
- yarn test
promote:
image: node
stage: promote
only:
- dev
script:
- git push origin HEAD:integration
build
image: node
stage: build
only:
- integration
script:
- echo "build docker image from integration"
deploy:
image: node
stage: deploy
only:
- integration
script:
- echo "deploy integration"
Run Code Online (Sandbox Code Playgroud)
我的问题是这行git push …