Skip to content

Commit 84ffb36

Browse files
authored
Bump minimum node version to 16. (#316)
* Bump minimum node version to 16. We already made the mistake of using features from 16 without realising Previously: #192 * Make sure CI uses specific version of node and we also lint. https://github.com/matrix-org/pipelines/blob/master/mjolnir/pipeline.yml#L13
1 parent 65f52fe commit 84ffb36

File tree

4 files changed

+32
-5
lines changed

4 files changed

+32
-5
lines changed

.github/workflows/mjolnir.yml

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,38 @@ env:
1111

1212
jobs:
1313
build:
14+
name: Build & Lint
15+
runs-on: ubuntu-latest
16+
steps:
17+
- uses: actions/checkout@v3
18+
19+
- name: Specifically use node 16 like in the readme.
20+
uses: actions/setup-node@v3
21+
with:
22+
node-version: '16'
23+
- run: yarn install
24+
- run: yarn build
25+
- run: yarn lint
26+
unit:
27+
name: Unit tests
28+
runs-on: ubuntu-latest
29+
steps:
30+
- uses: actions/checkout@v3
31+
- name: Specifically use node 16 like in the readme.
32+
uses: actions/setup-node@v3
33+
with:
34+
node-version: '16'
35+
- run: yarn install
36+
- run: yarn test
37+
integration:
1438
name: Integration tests
1539
runs-on: ubuntu-latest
1640
timeout-minutes: 60
1741
steps:
18-
- uses: actions/checkout@v2
42+
- uses: actions/checkout@v3
43+
- uses: actions/setup-node@v3
44+
with:
45+
node-version: '16'
1946
- name: install mx-tester
2047
run: cargo install mx-tester
2148
- name: Setup image

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM node:14-alpine
1+
FROM node:16-alpine
22
COPY . /tmp/src
33
RUN cd /tmp/src \
44
&& yarn install \

docs/setup_selfbuild.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
To build mjolnir, you have to have installed `yarn` 1.x and Node 14.
1+
To build mjolnir, you have to have installed `yarn` 1.x and Node 16.
22

33
```bash
44
git clone https://github.com/matrix-org/mjolnir.git
@@ -12,4 +12,4 @@ cp config/default.yaml config/development.yaml
1212
nano config/development.yaml
1313

1414
node lib/index.js
15-
```
15+
```

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,6 @@
4848
"shell-quote": "^1.7.3"
4949
},
5050
"engines": {
51-
"node": ">=14.0.0"
51+
"node": ">=16.0.0"
5252
}
5353
}

0 commit comments

Comments
 (0)