Created
May 12, 2019 18:07
-
-
Save tkssharma/246d4f9e460edcc519c28853eda3c8ae to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
stages: | |
- build | |
- deploy | |
build prod: | |
image: node:10.15.0-stretch | |
stage: build | |
only: | |
- tags | |
script: | |
- npm install | |
# Build App | |
- npm run build | |
artifacts: | |
paths: | |
# Build folder | |
- dist/ | |
expire_in: 1 hour | |
deploy prod: | |
image: python:latest | |
stage: deploy | |
only: | |
- tags | |
script: | |
- pip install awscli | |
- aws s3 sync ./dist s3://YOUR_BUCKET_NAME | |
build stage: | |
image: node:10.15.0-stretch | |
stage: build | |
only: | |
- master | |
script: | |
- npm install | |
# Build App | |
- npm run build-dev | |
artifacts: | |
paths: | |
# Build folder | |
- dist/ | |
expire_in: 1 hour | |
deploy stage: | |
image: python:latest | |
stage: deploy | |
only: | |
- master | |
script: | |
- pip install awscli | |
- aws s3 sync ./dist s3://YOUR_DEV_BUCKET_NAME |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment