Skip to content

Instantly share code, notes, and snippets.

@Mcdavid95
Last active April 1, 2019 17:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Mcdavid95/579a2e3774e83be08a71a83c304a4054 to your computer and use it in GitHub Desktop.
Save Mcdavid95/579a2e3774e83be08a71a83c304a4054 to your computer and use it in GitHub Desktop.
# Node docker image on which this would be run
image: node:8.10.0
cache:
paths:
- node_modules/
stages:
- test
- deploy_production
# Job 1:
Test:
stage: test
script:
- npm install
- npm run test
# Job 2:
# Deploy to staging
Production:
image: ruby:latest
only:
- master
stage: deploy_production
script:
- apt-get update -qy
- apt-get install -y ruby-dev
- gem install dpl
- dpl --provider=heroku --app=$HEROKU_APP_NAME --api-key=$HEROKU_API_KEY
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment