Bump minimum supported Node.js version to v18

The LTS releases for v12 and v14 are already end of life and the v16 is
end of life in under two months from now on.  Bump supported version up
to v18 as it does not make sense to continue to support EOL releases.
Even if we wanted to keep supporting them, our dependencies will not.

Note that Node.js v18 is currently not avaliable via the NodeSource PPA
on Ubuntu 19.10 and below or Debian 9 and below.
This commit is contained in:
Hornwitser committed 2023-07-27 00:35:26 +02:00
1 parent 93b19110df
commit a96a8a6d25
15 files changed
+24 -24

No files matched your search

+4 -4
View File
@@ -12,7 +12,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [12.x, 14.x, 16.x]
node-version: [18.x, 20.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
steps:
@@ -29,13 +29,13 @@ jobs:
- run: node packages/lib/build_mod --source-dir packages/host/lua/clusterio_lib --output-dir temp/test/mods
- run: wget -q -O temp/test/mods/subspace_storage_1.99.8.zip -L https://github.com/clusterio/subspace_storage/releases/download/1.99.6/subspace_storage_1.99.8.zip
- name: Run tests
if: ${{ matrix.node-version != '12.x' }}
if: ${{ matrix.node-version != '18.x' }}
run: pnpm test
- name: Run coverage
if: ${{ matrix.node-version == '12.x' }}
if: ${{ matrix.node-version == '18.x' }}
run: pnpm run ci-cover
- name : Upload coverage to Codecov
if: ${{ matrix.node-version == '12.x' }}
if: ${{ matrix.node-version == '18.x' }}
uses: codecov/codecov-action@v2
with:
files: ./coverage/lcov.info
+2 -2
View File
@@ -1,4 +1,4 @@
FROM node:12 as subspace_storage_builder
FROM node:20 as subspace_storage_builder
RUN apt update && apt install -y git
WORKDIR /
RUN git clone https://github.com/clusterio/subspace_storage.git
@@ -6,7 +6,7 @@ WORKDIR /subspace_storage
RUN npm install \
&& node build
FROM node:12 as clusterio_builder
FROM node:20 as clusterio_builder
RUN apt update \
&& apt install -y wget \
&& mkdir /clusterio
+5 -5
View File
@@ -89,7 +89,7 @@ Check out the documentation on [Writing Plugins](/docs/writing-plugins.md) for w
## Installation
Clusterio runs on Node.js v12 and up, it's distributed via npm and comes with a guided install script.
Clusterio runs on Node.js v18 and up, it's distributed via npm and comes with a guided install script.
If you already have a recent Node.js installed, you can set it up in a new directory with:
npm init "@clusterio"
@@ -99,11 +99,11 @@ Otherwise see below for OS specific instructions.
### Ubuntu setup
1. Install Node.js v12 or higher.
For 20.04 LTS or below the version of Node.js provided by the Ubuntu repos are too old and you will have to use the nodesource PPA, otherwise you may skip the first line.
1. Install Node.js v18 or higher.
Note the version of Node.js provided by the Ubuntu/debian repos are too old and you will have to use the nodesource PPA
wget -qO - https://deb.nodesource.com/setup_14.x | sudo -E bash -
sudo apt install nodejs
curl -fsSL https://deb.nodesource.com/setup_20.x | sudo -E bash - &&\
sudo apt-get install -y nodejs
2. Log in as the user you wish to install Clusterio as (do not use root), and then create a new directory and run the Clusterio installer:
+2 -2
View File
@@ -181,8 +181,8 @@ The format of this log should be self explanatory, please follow it carefully.
## Supported Node.js and Factorio Versions
Clusterio run on Node.js v12 and up, make sure to check that the Node builtin API's and npm packages you use are supported on these versions.
The GitHub Actions tests are run on whatever version of Node.js v12, v14, and v16 is the default.
Clusterio run on Node.js v16 and up, make sure to check that the Node builtin API's and npm packages you use are supported on these versions.
The GitHub Actions tests are run on whatever version of Node.js v16 and v18 is the default.
For Factorio Clusterio 2.0 aims to support version 0.17.69 and up, including the latest experimental release.
It's recommended that you use the lua API reference for 0.17.69, as there's no information on what version Factorio API's were introduced in.
+1 -1
View File
@@ -19,7 +19,7 @@
]
},
"engines": {
"node": ">=12"
"node": ">=18"
},
"devDependencies": {
"@clusterio/controller": "workspace:*",
+1 -1
View File
@@ -16,7 +16,7 @@
"factorio"
],
"engines": {
"node": ">=12"
"node": ">=18"
},
"dependencies": {
"@clusterio/lib": "^2.0.0-alpha.13",
+1 -1
View File
@@ -13,7 +13,7 @@
"clusterio"
],
"engines": {
"node": ">=12"
"node": ">=18"
},
"dependencies": {
"chalk": "^4.1.0",
+1 -1
View File
@@ -15,7 +15,7 @@
"factorio"
],
"engines": {
"node": ">=12"
"node": ">=18"
},
"dependencies": {
"@clusterio/lib": "^2.0.0-alpha.13",
+1 -1
View File
@@ -15,7 +15,7 @@
"factorio"
],
"engines": {
"node": ">=12"
"node": ">=18"
},
"dependencies": {
"@clusterio/lib": "^2.0.0-alpha.13",
+1 -1
View File
@@ -14,7 +14,7 @@
"url": "https://github.com/clusterio/clusterio/issues"
},
"engines": {
"node": ">=12"
"node": ">=18"
},
"peerDependencies": {
"@clusterio/lib": "^2.0.0-alpha.0"
+1 -1
View File
@@ -14,7 +14,7 @@
"url": "https://github.com/clusterio/factorioClusterio/issues"
},
"engines": {
"node": ">=12"
"node": ">=18"
},
"peerDependencies": {
"@clusterio/lib": "^2.0.0-alpha.0"
+1 -1
View File
@@ -14,7 +14,7 @@
"url": "https://github.com/clusterio/clusterio/issues"
},
"engines": {
"node": ">=12"
"node": ">=18"
},
"peerDependencies": {
"@clusterio/lib": "^2.0.0-alpha.0"
+1 -1
View File
@@ -14,7 +14,7 @@
"url": "https://github.com/clusterio/clusterio/issues"
},
"engines": {
"node": ">=12"
"node": ">=18"
},
"peerDependencies": {
"@clusterio/lib": "^2.0.0-alpha.0"
+1 -1
View File
@@ -14,7 +14,7 @@
"url": "https://github.com/clusterio/clusterio/issues"
},
"engines": {
"node": ">=12"
"node": ">=18"
},
"peerDependencies": {
"@clusterio/lib": "^2.0.0-alpha.0"
+1 -1
View File
@@ -14,7 +14,7 @@
"url": "https://github.com/clusterio/clusterio/issues"
},
"engines": {
"node": ">=12"
"node": ">=18"
},
"peerDependencies": {
"@clusterio/lib": "^2.0.0-alpha.0"