Commit f345cb5b authored by zhouzihao's avatar zhouzihao

更新.gitlab-ci.yaml

parent 4c50713c
# requiring the environment of NodeJS 6
image: node:6
# # requiring the environment of NodeJS 6
# image: node:6
# add 'node_modules' to cache for speeding up builds
cache:
paths:
- node_modules/ # Node modules and dependencies
# # add 'node_modules' to cache for speeding up builds
# cache:
# paths:
# - node_modules/ # Node modules and dependencies
before_script:
- npm install gitbook-cli -g # install gitbook
- gitbook fetch 3.2.3 # fetch final stable version
- gitbook install # add any requested plugins in book.json
# before_script:
# - npm install gitbook-cli -g # install gitbook
# - gitbook fetch 3.2.3 # fetch final stable version
# - gitbook install # add any requested plugins in book.json
# test:
# stage: test
# script:
# - gitbook build . public # build to public path
# only:
# - branches # this job will affect every branch except 'master'
# except:
# - master
# # the 'pages' job will deploy and build your site to the 'public' path
# pages:
# stage: deploy
# script:
# - gitbook build . public # build to public path
# artifacts:
# paths:
# - public
# expire_in: 1 week
# only:
# - master # this job will affect only the 'master' branch
stages:
- test
- build
- deploy
test:
stage: test
script:
- gitbook build . public # build to public path
only:
- branches # this job will affect every branch except 'master'
except:
- master
# the 'pages' job will deploy and build your site to the 'public' path
pages:
script: echo "Running tests"
build:
stage: build
script: echo "Building the app"
deploy_staging:
stage: deploy
script:
- gitbook build . public # build to public path
artifacts:
paths:
- public
expire_in: 1 week
- echo "Deploy to staging server"
environment:
name: staging
url: https://staging.example.com
only:
- master # this job will affect only the 'master' branch
- master
————————————————
版权声明:本文为CSDN博主「苍穹尘」的原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/lizhiqiang1217/article/details/88803783
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment