summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThorbjørn Lindeijer <bjorn@lindeijer.nl>2024-05-31 21:10:51 +0200
committerThorbjørn Lindeijer <bjorn@lindeijer.nl>2024-05-31 21:28:56 +0200
commit798fc5b60bf95ae336f1fd469853a72db44ecfce (patch)
tree5492bbded0fbbc510251dd04f2580aaf7afe38e2
parentcaf76b535b7bb95557f73f971fc04d96950590d0 (diff)
downloadwebsite-master.tar.gz
website-master.tar.bz2
website-master.tar.xz
website-master.zip
CI: Make the 'pages' job succeedHEADmaster
And also run it on all branches rather than just 'master'. This makes it work as a basic sanity check to make sure that the 'yarn deploy' step runs without errors. Also changed it to run on node:12-buster, to match the version of Node currently used in production.
-rw-r--r--.gitlab-ci.yml22
1 files changed, 4 insertions, 18 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 6a0a95e..e08309a 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -1,30 +1,16 @@
before_script:
- uname -a
-image: node:16-buster
pages: # the job must be named pages
- image: node:16-buster
+ image: node:12-buster
stage: deploy
script:
- - rm -rf node_modules
- - rm -rf */node_modules
- - npm install yarn
- - echo $PATH
- - export PATH="$(yarn global bin):$PATH"
- - echo $PATH
- - yarn global add @vue/cli
+ - npm install --no-package-lock yarn
- yarn install
- - vue --version
- - npm i -g @vue/cli-service
- - yarn build
- yarn deploy
- rm -rf public
- - mkdir -p public
- - mv dist/* public # rename the dist folder (result of npm run build)
- - find public/
+ - mv dist public
+ - find public
artifacts:
paths:
- public # artifact path must be /public for GitLab Pages to pick it up
- only:
- - master
-