Merge pull request #1251 from balena-io/update-to-node12

🚀 Update supervisor to node12
This commit is contained in:
CameronDiver 2020-04-13 15:37:53 +01:00 committed by GitHub
commit 642c255f18
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 36 additions and 21 deletions

View File

@ -1,5 +1,5 @@
ARG ARCH=amd64
ARG NODE_VERSION=10.19.0
ARG NODE_VERSION=12.16.2
FROM balenalib/$ARCH-alpine-supervisor-base:3.11 as BUILD

View File

@ -1,5 +1,5 @@
c1e6e0ee0f3c903151d4118e7068d4ae5ef5b408c969d792b0a4af6dfe04275a node-no-intl-v10.19.0-linux-alpine-amd64.tar.gz
ba33990227362ecfe238839ee5e7611b55f3faf860fc44ce694a0aeebb265c2f node-no-intl-v10.19.0-linux-alpine-i386.tar.gz
e015cba0a644f9e08a641affec25afc047af8d0103c9353550c12734bba3b423 node-no-intl-v10.19.0-linux-alpine-armv7hf.tar.gz
9890e656869591cd3f0efeb10046103d324cd48147d40d6d7f6efd1eb680694c node-no-intl-v10.19.0-linux-alpine-aarch64.tar.gz
1227cda220cf86d72f1c57790660a3e3ec007ee6946cf4d92f73692eaae3874b node-no-intl-v10.19.0-linux-alpine-rpi.tar.gz
6d4ab189ece76bed2f40cffe1f1b4dd2d2a805e6fe10c577ae5ce89fce2ad53b node-no-intl-v12.16.2-linux-alpine-amd64.tar.gz
6d81db43dc1285656f6d95807e237e51d33774bed5daafad7f706a4e68b6b546 node-no-intl-v12.16.2-linux-alpine-i386.tar.gz
d964c84be94d0cf3f30f4c4d61d3f2e0d5439b43137c938d0a0df1b6860961fb node-no-intl-v12.16.2-linux-alpine-aarch64.tar.gz
00ac31e6e43319cc3786c0eb97784dad91b5152c5f8be31889215801dcab7712 node-no-intl-v12.16.2-linux-alpine-armv7hf.tar.gz
8c1cfa75a1523a5b21060201178f4a8cd51f492c93693ecfbd67e8b0a49b23f1 node-no-intl-v12.16.2-linux-alpine-rpi.tar.gz

30
package-lock.json generated
View File

@ -435,9 +435,9 @@
}
},
"@types/node": {
"version": "10.17.17",
"resolved": "https://registry.npmjs.org/@types/node/-/node-10.17.17.tgz",
"integrity": "sha512-gpNnRnZP3VWzzj5k3qrpRC6Rk3H/uclhAVo1aIvwzK5p5cOrs9yEyQ8H/HBsBY0u5rrWxXEiVPQ0dEB6pkjE8Q==",
"version": "12.12.35",
"resolved": "https://registry.npmjs.org/@types/node/-/node-12.12.35.tgz",
"integrity": "sha512-ASYsaKecA7TUsDrqIGPNk3JeEox0z/0XR/WsJJ8BIX/9+SkMSImQXKWfU/yBrSyc7ZSE/NPqLu36Nur0miCFfQ==",
"dev": true
},
"@types/optimist": {
@ -4590,7 +4590,8 @@
},
"ansi-regex": {
"version": "2.1.1",
"bundled": true
"bundled": true,
"optional": true
},
"aproba": {
"version": "1.2.0",
@ -4608,11 +4609,13 @@
},
"balanced-match": {
"version": "1.0.0",
"bundled": true
"bundled": true,
"optional": true
},
"brace-expansion": {
"version": "1.1.11",
"bundled": true,
"optional": true,
"requires": {
"balanced-match": "^1.0.0",
"concat-map": "0.0.1"
@ -4630,7 +4633,8 @@
},
"concat-map": {
"version": "0.0.1",
"bundled": true
"bundled": true,
"optional": true
},
"console-control-strings": {
"version": "1.1.0",
@ -4762,17 +4766,20 @@
"minimatch": {
"version": "3.0.4",
"bundled": true,
"optional": true,
"requires": {
"brace-expansion": "^1.1.7"
}
},
"minimist": {
"version": "0.0.8",
"bundled": true
"bundled": true,
"optional": true
},
"minipass": {
"version": "2.3.5",
"bundled": true,
"optional": true,
"requires": {
"safe-buffer": "^5.1.2",
"yallist": "^3.0.0"
@ -4789,6 +4796,7 @@
"mkdirp": {
"version": "0.5.1",
"bundled": true,
"optional": true,
"requires": {
"minimist": "0.0.8"
}
@ -4872,6 +4880,7 @@
"once": {
"version": "1.4.0",
"bundled": true,
"optional": true,
"requires": {
"wrappy": "1"
}
@ -4995,6 +5004,7 @@
"strip-ansi": {
"version": "3.0.1",
"bundled": true,
"optional": true,
"requires": {
"ansi-regex": "^2.0.0"
}
@ -9651,6 +9661,12 @@
"tar-stream": "^2.1.0"
},
"dependencies": {
"@types/node": {
"version": "10.17.19",
"resolved": "https://registry.npmjs.org/@types/node/-/node-10.17.19.tgz",
"integrity": "sha512-46/xThm3zvvc9t9/7M3AaLEqtOpqlYYYcCZbpYVAQHG20+oMZBkae/VMrn4BTi6AJ8cpack0mEXhGiKmDNbLrQ==",
"dev": true
},
"bl": {
"version": "4.0.2",
"resolved": "https://registry.npmjs.org/bl/-/bl-4.0.2.tgz",

View File

@ -55,7 +55,7 @@
"@types/mocha": "^5.2.7",
"@types/morgan": "^1.9.0",
"@types/mz": "0.0.32",
"@types/node": "^10.17.17",
"@types/node": "^12.12.6",
"@types/request": "^2.48.4",
"@types/rimraf": "^2.0.4",
"@types/rwlock": "^5.0.2",

View File

@ -42,10 +42,7 @@ export class NetworkManager {
return this.getAll().filter((network: Network) => network.appId === appId);
}
public async get(network: {
name: string;
appId: number;
}): Bluebird<Network> {
public async get(network: { name: string; appId: number }): Promise<Network> {
const dockerNet = await this.docker
.getNetwork(Network.generateDockerName(network.appId, network.name))
.inspect();

View File

@ -490,12 +490,13 @@ export function createV2Api(router: Router, applications: ApplicationManager) {
containerId,
});
res.status(200);
journald.stdout.pipe(res);
// We know stdout will be present
journald.stdout!.pipe(res);
res.on('close', () => {
journald.kill('SIGKILL');
});
journald.on('exit', () => {
journald.stdout.unpipe();
journald.stdout!.unpipe();
res.end();
});
});

View File

@ -80,7 +80,7 @@ export const startConnectivityCheck = _.once(
customMonitor(
{
host: parsedUrl.hostname,
host: parsedUrl.hostname ?? undefined,
port: port || (parsedUrl.protocol === 'https' ? 443 : 80),
path: parsedUrl.path || '/',
interval: 10 * 1000,

View File

@ -1,5 +1,6 @@
{
"compilerOptions": {
"target": "ES2019",
"module": "commonjs",
"noImplicitAny": true,
"preserveConstEnums": true,