From 9060e5b99c05b002cddb8720e1a75838240af160 Mon Sep 17 00:00:00 2001 From: 1Copenut Date: Mon, 20 Nov 2023 16:49:47 -0600 Subject: [PATCH 1/2] Bumping local Node and Docker image to v20.9.0. --- .buildkite/scripts/pipelines/pipeline_test.sh | 2 +- .nvmrc | 2 +- package.json | 4 ++-- scripts/deploy/build_docs | 2 +- scripts/docker-ci/Dockerfile | 2 +- scripts/test-a11y-docker.js | 4 ++-- scripts/test-docker.js | 14 +++++++------- 7 files changed, 15 insertions(+), 15 deletions(-) diff --git a/.buildkite/scripts/pipelines/pipeline_test.sh b/.buildkite/scripts/pipelines/pipeline_test.sh index b8cd1d0c9be..660ae060caf 100644 --- a/.buildkite/scripts/pipelines/pipeline_test.sh +++ b/.buildkite/scripts/pipelines/pipeline_test.sh @@ -10,7 +10,7 @@ DOCKER_OPTIONS=( --user="$(id -u):$(id -g)" --volume="$(pwd):/app" --workdir=/app - docker.elastic.co/eui/ci:5.6 + docker.elastic.co/eui/ci:6.0 ) case $TEST_TYPE in diff --git a/.nvmrc b/.nvmrc index 87ec8842b15..f3f52b42d3d 100644 --- a/.nvmrc +++ b/.nvmrc @@ -1 +1 @@ -18.18.2 +20.9.0 diff --git a/package.json b/package.json index ee2c402b0e5..0574732ad2f 100644 --- a/package.json +++ b/package.json @@ -6,9 +6,9 @@ "main": "lib", "module": "es", "types": "eui.d.ts", - "docker_image": "18.18.2", + "docker_image": "20.9.0", "engines": { - "node": "16.x || 18.x || >=20.0" + "node": "16.x || 18.x || >=20.x" }, "sideEffects": [ "*.css", diff --git a/scripts/deploy/build_docs b/scripts/deploy/build_docs index d6f523340af..c15dd68305f 100755 --- a/scripts/deploy/build_docs +++ b/scripts/deploy/build_docs @@ -2,7 +2,7 @@ set -e -NODE_IMG="docker.elastic.co/eui/ci:5.6" +NODE_IMG="docker.elastic.co/eui/ci:6.0" # Compile using node image echo "Building docs using ${NODE_IMG} Docker image" diff --git a/scripts/docker-ci/Dockerfile b/scripts/docker-ci/Dockerfile index 874ff29854f..9b9dbd165b3 100644 --- a/scripts/docker-ci/Dockerfile +++ b/scripts/docker-ci/Dockerfile @@ -2,7 +2,7 @@ # https://github.com/zenato/docker-puppeteer/blob/master/Dockerfile # >=12.0 required (for cypress). v18 is LTS. -FROM --platform=linux/amd64 node:18.18.2-slim +FROM --platform=linux/amd64 node:20.9.0-slim SHELL ["/bin/bash", "-o", "pipefail", "-c"] diff --git a/scripts/test-a11y-docker.js b/scripts/test-a11y-docker.js index 65cc57244bf..d1a1b6436e6 100644 --- a/scripts/test-a11y-docker.js +++ b/scripts/test-a11y-docker.js @@ -1,6 +1,6 @@ const { execSync } = require('child_process'); -execSync('docker pull docker.elastic.co/eui/ci:5.6', { +execSync('docker pull docker.elastic.co/eui/ci:6.0', { stdio: 'inherit', }); /* eslint-disable-next-line no-multi-str */ @@ -9,7 +9,7 @@ execSync( -i --rm --cap-add=SYS_ADMIN --volume=$(pwd):/app --workdir=/app --platform=linux/amd64 \ -e GIT_COMMITTER_NAME=test -e GIT_COMMITTER_EMAIL=test -e HOME=/tmp \ --user=$(id -u):$(id -g) \ - docker.elastic.co/eui/ci:5.6 \ + docker.elastic.co/eui/ci:6.0 \ bash -c '/opt/yarn*/bin/yarn \ && yarn cypress install \ && yarn run test-cypress-a11y \ diff --git a/scripts/test-docker.js b/scripts/test-docker.js index 2d90213c0b6..639f8e6a1bf 100644 --- a/scripts/test-docker.js +++ b/scripts/test-docker.js @@ -1,19 +1,19 @@ const { execSync } = require('child_process'); -execSync('docker pull docker.elastic.co/eui/ci:5.6', { +execSync('docker pull docker.elastic.co/eui/ci:6.0', { stdio: 'inherit', }); /* eslint-disable-next-line no-multi-str */ execSync( - 'docker run \ - -i --rm --cap-add=SYS_ADMIN --volume=$(pwd):/app --workdir=/app \ + "docker run \ + -i --rm --cap-add=SYS_ADMIN --volume=$(pwd):/app --workdir=/app --platform=linux/amd64 \ -e GIT_COMMITTER_NAME=test -e GIT_COMMITTER_EMAIL=test -e HOME=/tmp \ --user=$(id -u):$(id -g) \ - docker.elastic.co/eui/ci:5.6 \ - bash -c \'/opt/yarn*/bin/yarn \ + docker.elastic.co/eui/ci:6.0 \ + bash -c '/opt/yarn*/bin/yarn \ && yarn cypress install \ - && NODE_OPTIONS="--max-old-space-size=2048" npm run test-ci \ - && npm run build\'', + && yarn test-ci --node-options=--max_old_space_size=2048 \ + && yarn build'", { stdio: 'inherit', } From f8ed6efa84de61db8755bbcb65f7343225f5222c Mon Sep 17 00:00:00 2001 From: 1Copenut Date: Tue, 21 Nov 2023 11:48:47 -0600 Subject: [PATCH 2/2] Removing Docker test scripts to be refactored in another PR. --- scripts/test-a11y-docker.js | 21 --------------------- scripts/test-docker.js | 20 -------------------- 2 files changed, 41 deletions(-) delete mode 100644 scripts/test-a11y-docker.js delete mode 100644 scripts/test-docker.js diff --git a/scripts/test-a11y-docker.js b/scripts/test-a11y-docker.js deleted file mode 100644 index d1a1b6436e6..00000000000 --- a/scripts/test-a11y-docker.js +++ /dev/null @@ -1,21 +0,0 @@ -const { execSync } = require('child_process'); - -execSync('docker pull docker.elastic.co/eui/ci:6.0', { - stdio: 'inherit', -}); -/* eslint-disable-next-line no-multi-str */ -execSync( - "docker run \ - -i --rm --cap-add=SYS_ADMIN --volume=$(pwd):/app --workdir=/app --platform=linux/amd64 \ - -e GIT_COMMITTER_NAME=test -e GIT_COMMITTER_EMAIL=test -e HOME=/tmp \ - --user=$(id -u):$(id -g) \ - docker.elastic.co/eui/ci:6.0 \ - bash -c '/opt/yarn*/bin/yarn \ - && yarn cypress install \ - && yarn run test-cypress-a11y \ - --node-options=--max_old_space_size=2048 \ - --skip-css '", // Skipping CSS because compiling has a tendency to hang on Apple Silicon - { - stdio: 'inherit', - } -); diff --git a/scripts/test-docker.js b/scripts/test-docker.js deleted file mode 100644 index 639f8e6a1bf..00000000000 --- a/scripts/test-docker.js +++ /dev/null @@ -1,20 +0,0 @@ -const { execSync } = require('child_process'); - -execSync('docker pull docker.elastic.co/eui/ci:6.0', { - stdio: 'inherit', -}); -/* eslint-disable-next-line no-multi-str */ -execSync( - "docker run \ - -i --rm --cap-add=SYS_ADMIN --volume=$(pwd):/app --workdir=/app --platform=linux/amd64 \ - -e GIT_COMMITTER_NAME=test -e GIT_COMMITTER_EMAIL=test -e HOME=/tmp \ - --user=$(id -u):$(id -g) \ - docker.elastic.co/eui/ci:6.0 \ - bash -c '/opt/yarn*/bin/yarn \ - && yarn cypress install \ - && yarn test-ci --node-options=--max_old_space_size=2048 \ - && yarn build'", - { - stdio: 'inherit', - } -);