Skip to content

Commit 6958910

Browse files
author
Kirill Dorofeev
committed
Merge branch 'feature/https' of https://github.com/ki-do/test-things into feature/https
2 parents 1e6e736 + ac1e724 commit 6958910

5 files changed

Lines changed: 30 additions & 66 deletions

File tree

scripts/installDependencies.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,14 @@
11
#!/bin/bash
22

3+
# Remove nested local node_modules to avoid shadowing workspace dependencies in CI.
4+
find things -type d -name node_modules -prune -exec rm -rf {} +
5+
36
# Install dependencies for npm workspaces packages
47
npm ci
58

9+
npm --workspace ./util run clean
10+
npm --workspace ./util run build
11+
612
# Install dependencies for non-npm packages
713
for protocol_directory in things/*/*/* ; do
814
current_path="$(pwd)"

scripts/runTests.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
#!/bin/bash
22

33
# default to HTTP unless explicitly overridden.
4+
export HOSTNAME="127.0.0.1"
5+
export STACK_HOSTNAME="127.0.0.1"
46
export PROTOCOL="${PROTOCOL:-http}"
5-
export HOSTNAME="${HOSTNAME:-127.0.0.1}"
6-
export STACK_HOSTNAME="${STACK_HOSTNAME:-127.0.0.1}"
77
export WEB_PORT_OUT="${WEB_PORT_OUT:-80}"
88
export EXTERNAL_PORT="${EXTERNAL_PORT:-80}"
99

things/calculator/mqtt/js/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
"license": "EPL-2.0 OR W3C-20150513",
1919
"dependencies": {
2020
"dotenv": "^16.3.1",
21+
"duplexify": "^4.1.2",
2122
"json-placeholder-replacer": "^1.0.35",
2223
"mqtt": "^4.3.8",
2324
"yallist": "^4.0.0",

util/dist/util.js

Lines changed: 19 additions & 63 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

util/util.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,9 @@ export const getInitiateMain = (mainCmd: string, cmdArgs: string[]): Promise<Thi
4848
const thingProcess = spawn(mainCmd, cmdArgs, {
4949
env: {
5050
...process.env,
51+
HOSTNAME: "127.0.0.1",
52+
STACK_HOSTNAME: "127.0.0.1",
5153
PROTOCOL: process.env.PROTOCOL ?? "http",
52-
HOSTNAME: process.env.HOSTNAME ?? "127.0.0.1",
5354
PORT: process.env.PORT ?? derivedPort ?? "80",
5455
EXTERNAL_PORT: process.env.EXTERNAL_PORT ?? derivedPort ?? "80",
5556
},

0 commit comments

Comments
 (0)