Skip to content

Commit

Permalink
Test hotfix-release to test auto-deployment
Browse files Browse the repository at this point in the history
- Fix syntax of targetted deploy
- Make webhook-port configurable from outside
  • Loading branch information
elwinschmitz committed Apr 22, 2020
1 parent 155a96f commit 19a4c50
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [Unreleased]


## [0.2.1] - 2020-04-22
Test hotfix-release to test automatic deployment of patch-releases.

## [0.2.0] - 2020-04-22

### Added
Expand All @@ -29,7 +32,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Removed
- 2020-03-11: Remove usernames from `services/121-service/src/secrets.ts` AB#1641

[Unreleased]: /~https://github.com/global-121/121-platform/compare/v0.2.0...master
[Unreleased]: /~https://github.com/global-121/121-platform/compare/v0.2.1...master
[0.2.1]: /~https://github.com/global-121/121-platform/releases/tag/v0.2.0...v0.2.1
[0.2.0]: /~https://github.com/global-121/121-platform/releases/tag/v0.1.1...v0.2.0
[0.1.1]: /~https://github.com/global-121/121-platform/releases/tag/v0.1.0...v0.1.1
[0.1.0]: /~https://github.com/global-121/121-platform/releases/tag/v0.1.0
8 changes: 5 additions & 3 deletions tools/webhook.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@ const repo = process.env.GLOBAL_121_REPO;
*/
function deploy(target) {
exec(
`cd ${repo} && sudo ./tools/deploy.sh` + (target) ? ` ${target}` : ``,
target
? `cd ${repo} && sudo ./tools/deploy.sh "${target}"`
: `cd ${repo} && sudo ./tools/deploy.sh`,
function (error, stdout, stderr) {
if (error) {
console.log(stderr);
Expand Down Expand Up @@ -75,6 +77,6 @@ http
});
res.end();
})
.listen(3099);
.listen(process.env.NODE_PORT);

console.log("Listening on port 3099");
console.log(`Listening on port ${process.env.NODE_PORT}`);

0 comments on commit 19a4c50

Please sign in to comment.