Skip to content

Commit 436050a

Browse files
committed
trying to fix CI
1 parent 8652c49 commit 436050a

File tree

4 files changed

+37
-37
lines changed

4 files changed

+37
-37
lines changed

.devcontainer/devcontainer.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@
33
{
44
"name": "Node.js & TypeScript",
55
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
6-
"image": "mcr.microsoft.com/devcontainers/typescript-node:0-16",
6+
"image": "mcr.microsoft.com/devcontainers/typescript-node:1-22-bookworm",
77
"features": {
8-
"ghcr.io/devcontainers/features/python:1": {
9-
"installTools": true,
10-
"version": "os-provided"
11-
}
12-
}
8+
// "ghcr.io/devcontainers/features/python:1": {
9+
// "installTools": true,
10+
// "version": "os-provided"
11+
// }
12+
},
1313

1414
// Features to add to the dev container. More info: https://containers.dev/features.
1515
// "features": {},
@@ -18,7 +18,7 @@
1818
// "forwardPorts": [],
1919

2020
// Use 'postCreateCommand' to run commands after the container is created.
21-
// "postCreateCommand": "yarn install",
21+
"postCreateCommand": "sudo apt-get update && sudo apt-get install -y python3 gcc g++ make && npm install"
2222

2323
// Configure tool-specific properties.
2424
// "customizations": {},

.github/workflows/build-and-release.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ on:
99
- master
1010
- development
1111
- beta
12+
- ci
1213
pull_request:
1314

1415
jobs:
@@ -18,7 +19,7 @@ jobs:
1819
- uses: actions/checkout@v4
1920
- uses: actions/setup-node@v4
2021
with:
21-
node-version: 20
22+
node-version: 22
2223
- name: Install depencencies
2324
run: npm ci
2425
- name: Run tests

Dockerfile

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,25 @@
1-
FROM node:16-alpine as node-original
2-
FROM node-original as install
1+
FROM node:22-bookworm-slim AS node-original
2+
FROM node-original AS install
33
WORKDIR /usr/src/app
44
COPY package*.json ./
5-
RUN apk update && \
6-
apk add --no-cache make gcc g++ python3 linux-headers udev
7-
RUN npm ci --only=production
5+
RUN apt-get update && \
6+
apt-get install -y make python3 udev gcc g++
7+
RUN npm install --omit=dev
88

9-
FROM install as compile
10-
RUN npm install
9+
FROM install AS compile
10+
#RUN npm install
1111
COPY ./src/ ./src/
1212
COPY tsconfig.json ./
1313
RUN npm run prepack
1414

15-
FROM node-original as combiner
15+
FROM node-original AS combiner
1616
WORKDIR /usr/src/app
1717
COPY --from=install /usr/src/app/node_modules /usr/src/app/node_modules
1818
COPY --from=install /usr/src/app/package.json /usr/src/app/package.json
1919
COPY bin/run /usr/src/app/bin/run
2020
COPY --from=compile /usr/src/app/dist /usr/src/app/dist
2121

22-
FROM node-original as production
22+
FROM node-original AS production
2323
ARG BUILD_DATE=unknown
2424
ARG BUILD_VERSION=0.0.0-development
2525
ARG VCS_REF=not-set

package.json

Lines changed: 19 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -26,44 +26,43 @@
2626
"meter",
2727
"electricity"
2828
],
29-
"author": "Stephan van Rooij <github@svrooij.nl> (https://svrooij.nl)",
29+
"author": "Stephan van Rooij <github@svrooij.io> (https://svrooij.io)",
3030
"license": "MIT",
3131
"bugs": {
3232
"url": "https://github.com/svrooij/smartmeter2mqtt/issues"
3333
},
3434
"homepage": "https://github.com/svrooij/smartmeter2mqtt#readme",
3535
"dependencies": {
36-
"@influxdata/influxdb-client": "^1.17.0",
37-
"@serialport/parser-readline": "^9.0.7",
36+
"@influxdata/influxdb-client": "^1.35.0",
37+
"@serialport/parser-readline": "^13.0.0",
3838
"@svrooij/sunspec": "^0.9.0",
3939
"@svrooij/tcp-server": "^1.0.1",
4040
"crc": "^3.8.0",
41-
"express": "^4.17.1",
42-
"mqtt": "^4.2.8",
43-
"node-fetch": "^2.6.1",
44-
"serialport": "^9.2.0",
45-
"typed-emitter": "^1.3.1",
46-
"ws": "^8.2.1",
47-
"yargs": "^17.1.1"
41+
"express": "^4.21.2",
42+
"mqtt": "^5.10.4",
43+
"node-fetch": "^3.3.2",
44+
"serialport": "^13.0.0",
45+
"typed-emitter": "^2.1.0",
46+
"ws": "^8.18.1",
47+
"yargs": "^17.7.2"
4848
},
4949
"devDependencies": {
50-
"@types/chai": "^4.2.21",
50+
"@types/chai": "^5.2.0",
5151
"@types/crc": "^3.4.0",
5252
"@types/express": "^4.17.13",
53-
"@types/jest": "^27.0.1",
54-
"@types/node-fetch": "^2.5.12",
55-
"@types/serialport": "^8.0.2",
56-
"@types/ws": "^7.4.7",
57-
"@types/yargs": "^17.0.2",
53+
"@types/jest": "^29.5.14",
54+
"@types/node-fetch": "^2.6.12",
55+
"@types/ws": "^8.18.0",
56+
"@types/yargs": "^17.0.33",
5857
"@typescript-eslint/eslint-plugin": "^4.29.3",
59-
"chai": "^4.3.4",
58+
"chai": "^5.2.0",
6059
"eslint": "^7.32.0",
6160
"eslint-config-airbnb": "^18.2.1",
6261
"eslint-config-airbnb-typescript": "^14.0.0",
6362
"eslint-plugin-import": "^2.24.2",
64-
"jest": "^27.1.0",
65-
"ts-jest": "^27.0.5",
66-
"typescript": "^4.4.2"
63+
"jest": "^29.7.0",
64+
"ts-jest": "^29.2.6",
65+
"typescript": "^5.5.0"
6766
},
6867
"bin": {
6968
"smartmeter2mqtt": "./bin/run"

0 commit comments

Comments
 (0)