36 lines
615 B
YAML
36 lines
615 B
YAML
stages:
|
|
- build
|
|
- test
|
|
- deploy
|
|
|
|
build:
|
|
stage: build
|
|
image: node
|
|
script:
|
|
- echo "Start building App"
|
|
- yarn
|
|
- CI= yarn run build
|
|
- echo "Build successfully!"
|
|
artifacts:
|
|
expire_in: 1 hour
|
|
paths:
|
|
- build
|
|
- node_modules/
|
|
|
|
test:
|
|
stage: test
|
|
image: node
|
|
script:
|
|
- echo "Testing App"
|
|
- CI= yarn test --passWithNoTests
|
|
- echo "Test successfully!"
|
|
|
|
deploy_production:
|
|
stage: deploy
|
|
script:
|
|
- echo "Deploying to server"
|
|
- rsync --progress -r build/* --delete root@35.207.132.68:/var/www/plannaplan.pl
|
|
- echo "Deployed"
|
|
only:
|
|
- master
|