diff --git a/24/Dockerfile b/24/Dockerfile new file mode 100644 index 0000000..d58478a --- /dev/null +++ b/24/Dockerfile @@ -0,0 +1,4 @@ +ARG ARCH=amd64 +FROM sykescottages/node:base-$ARCH + +RUN getnode v24.11.1 \ No newline at end of file diff --git a/24/docker-compose.test.yml b/24/docker-compose.test.yml new file mode 100644 index 0000000..83d23a0 --- /dev/null +++ b/24/docker-compose.test.yml @@ -0,0 +1,6 @@ +services: + sut: + build: . + command: /tests/run_tests.sh + volumes: + - ./run_tests.sh:/tests/run_tests.sh \ No newline at end of file diff --git a/24/run_tests.sh b/24/run_tests.sh new file mode 100644 index 0000000..18d0d22 --- /dev/null +++ b/24/run_tests.sh @@ -0,0 +1,29 @@ +#!/bin/sh + +itShouldCheckThatAllInstalledSoftwareExists() { + doesCommandExist node + doesCommandExist npm +} + +itShouldMatchTheDesiredVersions() { + doesMatchVersion node v24.11.1 + doesMatchVersion npm 11.6.2 +} + +doesCommandExist() { + if ! [ -x "$(command -v $1)" ]; then + echo "Error: $1 is not installed." >&2 + exit 1 + fi +} + +doesMatchVersion() { + VERSION=$($1 -v|grep -i "$2") + if [ -z "$VERSION" ]; then + echo "Error: $1 version $2 is not found, found $($1 -v) instead." >&2 + exit 1 + fi +} + +itShouldCheckThatAllInstalledSoftwareExists +itShouldMatchTheDesiredVersions \ No newline at end of file diff --git a/25/Dockerfile b/25/Dockerfile new file mode 100644 index 0000000..b1a2239 --- /dev/null +++ b/25/Dockerfile @@ -0,0 +1,4 @@ +ARG ARCH=amd64 +FROM sykescottages/node:base-$ARCH + +RUN getnode v25.2.1 \ No newline at end of file diff --git a/25/docker-compose.test.yml b/25/docker-compose.test.yml new file mode 100644 index 0000000..83d23a0 --- /dev/null +++ b/25/docker-compose.test.yml @@ -0,0 +1,6 @@ +services: + sut: + build: . + command: /tests/run_tests.sh + volumes: + - ./run_tests.sh:/tests/run_tests.sh \ No newline at end of file diff --git a/25/run_tests.sh b/25/run_tests.sh new file mode 100644 index 0000000..c8a984e --- /dev/null +++ b/25/run_tests.sh @@ -0,0 +1,29 @@ +#!/bin/sh + +itShouldCheckThatAllInstalledSoftwareExists() { + doesCommandExist node + doesCommandExist npm +} + +itShouldMatchTheDesiredVersions() { + doesMatchVersion node v25.2.1 + doesMatchVersion npm 11.6.2 +} + +doesCommandExist() { + if ! [ -x "$(command -v $1)" ]; then + echo "Error: $1 is not installed." >&2 + exit 1 + fi +} + +doesMatchVersion() { + VERSION=$($1 -v|grep -i "$2") + if [ -z "$VERSION" ]; then + echo "Error: $1 version $2 is not found, found $($1 -v) instead." >&2 + exit 1 + fi +} + +itShouldCheckThatAllInstalledSoftwareExists +itShouldMatchTheDesiredVersions \ No newline at end of file diff --git a/README.MD b/README.MD index fe625a4..cc27122 100644 --- a/README.MD +++ b/README.MD @@ -40,12 +40,14 @@ docker run -it --platform= sykescottages/node: arch - v15.14.0 (Deprecated) - `sykescottages/node:15` - v16.20.2 (Deprecated) - `sykescottages/node:16` - v17.9.1 (Deprecated) - `sykescottages/node:17` -- **v18.20.7 (LTS Active EOL 2025-04-30)** - `sykescottages/node:18` +- v18.20.7 (Deprecated) - `sykescottages/node:18` - v19.9.0 (Deprecated) - `sykescottages/node:19` -- **v20.18.3 (LTS Current EOL 2026-04-30)** - `sykescottages/node:20` +- **v20.18.3 (LTS Active EOL 2026-04-30)** - `sykescottages/node:20` - v21.7.3 (Deprecated) - `sykescottages/node:21` -- **v22.14.0 (Current EOL 2027-04-30)** - `sykescottages/node:22` -- **v23.9.0 (Current EOL 2025-04-30)** - `sykescottages/node:23` +- **v22.14.0 (LTS Active EOL 2027-04-30)** - `sykescottages/node:22` +- v23.9.0 (Deprecated) - `sykescottages/node:23` +- **v24.11.1 (LTS Current EOL 2028-04-30)** - `sykescottages/node:24` +- **v25.2.1 (Current)** - `sykescottages/node:25` ## Image Itinerary