Skip to content

Commit

Permalink
chore(heroku): add heroku deploy via travis (#3116)
Browse files Browse the repository at this point in the history
  • Loading branch information
IlyaSurmay authored and valorkin committed Nov 27, 2017
1 parent 6bb077c commit 080d89a
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
10 changes: 10 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ stages:
if: ( branch = development AND type = push ) OR type = pull_request
- name: deploy-surge
if: branch = development AND type = push
- name: deploy-heroku
if: branch = development AND type = push
- name: sauce-tests
if: ( branch = development AND type = push ) OR type = pull_request

Expand Down Expand Up @@ -110,6 +112,14 @@ jobs:
project: ./gh-pages/
domain: ngx-bootstrap-latest.surge.sh
on: development
- stage: deploy-heroku
script: npm run build:dynamic
deploy:
provider: heroku
api_key: $HEROKU_API_KEY
skip_cleanup: true
app: ngx-universal
on: development

cache:
apt: true
Expand Down
1 change: 1 addition & 0 deletions Procfile
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
web: node demo/dist/server.js
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"demo.deploy-gh-pages": "gh-pages -d gh-pages",
"demo.build": "run-s build link demo.gen-docs demo.ng-build demo.set-version",
"demo.serve": "run-s demo.build lite-server",
"demo.serve-universal": "run-s build link build:dynamic serve:dynamic",
"demo.serve-universal": "run-s build:dynamic serve:dynamic",
"demo.deploy": "run-s demo.build demo.deploy-gh-pages",
"link": "ngm link -p src --here",
"lint-pretty": "prettier --config .prettierrc --write -l \"{demo/src,src}/**/*.ts\"",
Expand All @@ -39,7 +39,7 @@
"e2e": "protractor",
"e2e-cross": "SAUCE=true npm run e2e",
"view-stats": "webpack-bundle-analyzer demo/dist/stats.json",
"build:dynamic": "npm run build:client-and-server-bundles && npm run webpack:server",
"build:dynamic": "run-s build link build:client-and-server-bundles webpack:server",
"serve:dynamic": "node demo/dist/server.js",
"build:client-and-server-bundles": "ng build -bh / --prod --env=server && ng build -bh / --prod --env=server --app 1 --output-hashing=false",
"webpack:server": "webpack --config ./scripts/universal/webpack.server.config.js --progress --colors"
Expand Down

0 comments on commit 080d89a

Please sign in to comment.