1
0
mirror of https://github.com/kremalicious/portfolio.git synced 2025-01-03 10:25:00 +01:00

prepare auto deployment

This commit is contained in:
Matthias Kretschmann 2018-04-21 02:09:08 +02:00
parent c09f97b658
commit e5f05857c2
Signed by: m
GPG Key ID: 606EEEF3C479A91F

View File

@ -4,14 +4,30 @@ cache:
paths: paths:
- node_modules/ - node_modules/
before_script:
- sudo apt-get -qq update
- sudo apt-get install python python-pip
- pip install --user awscli
- export PATH=$PATH:$HOME/.local/bin
- npm i -g gatsby-cli
- export PATH="$PATH:/usr/local/bin/gatsby"
stages:
- testing
- deployment
testing: testing:
stage: test stage: test
script: script:
- npm i -g gatsby-cli
- export PATH="$PATH:/usr/local/bin/gatsby"
- npm i - npm i
- npm test - npm test
- npm run build - npm run build
artifacts: artifacts:
paths: paths:
- public - public
deployment:
stage: deploy
script: aws s3 sync ./public s3://beta.matthiaskretschmann.com --delete --acl public-read
only:
- master