www-new/.gitlab-ci.yml

49 lines
656 B
YAML
Raw Normal View History

default:
image: node:14
cache:
paths:
- node_modules/
- .next
stages:
- build
- staging
2021-06-07 20:18:15 -04:00
variables:
2021-06-07 21:51:02 -04:00
NEXT_PUBLIC_BASE_PATH: '/~a3thakra/csc'
2021-06-07 20:18:15 -04:00
install_deps:
stage: .pre
script:
- npm install
lint:
stage: build
script:
- npm run lint
build:
stage: build
script:
- npm run build
2021-06-07 20:18:15 -04:00
staging:
stage: staging
script:
- npm run export
artifacts:
paths:
2021-06-07 20:18:15 -04:00
- out
only:
2021-06-07 20:18:15 -04:00
refs:
2021-06-07 21:04:55 -04:00
- main
2021-06-07 21:13:32 -04:00
deploy_staging:
stage: .post
needs: ["staging"]
2021-06-07 21:04:55 -04:00
script:
2021-06-07 21:51:02 -04:00
- 'curl -XPOST -H "Authorization: Basic $STAGING_SECRET" "https://csclub.uwaterloo.ca/~a3thakra/csc/"'
2021-06-07 21:15:21 -04:00
only:
refs:
- main