From 03507baf7c4e664f29f160f82ee90a413a339460 Mon Sep 17 00:00:00 2001 From: Michael Bear <38406045+mjbear@users.noreply.github.com> Date: Sun, 10 Nov 2024 21:52:18 -0500 Subject: [PATCH 1/2] Update 09_image_best.md - 18-alpine image --- content/get-started/workshop/09_image_best.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/content/get-started/workshop/09_image_best.md b/content/get-started/workshop/09_image_best.md index 2e91579a22..f465fe94a0 100644 --- a/content/get-started/workshop/09_image_best.md +++ b/content/get-started/workshop/09_image_best.md @@ -61,7 +61,7 @@ Look at the following Dockerfile you created for the getting started app. ```dockerfile # syntax=docker/dockerfile:1 -FROM node:18-alpine +FROM node:lts-alpine WORKDIR /app COPY . . RUN yarn install --production @@ -81,7 +81,7 @@ dependencies if there was a change to the `package.json`. ```dockerfile # syntax=docker/dockerfile:1 - FROM node:18-alpine + FROM node:lts-alpine WORKDIR /app COPY package.json yarn.lock ./ RUN yarn install --production @@ -103,10 +103,10 @@ dependencies if there was a change to the `package.json`. => => transferring dockerfile: 175B => [internal] load .dockerignore => => transferring context: 2B - => [internal] load metadata for docker.io/library/node:18-alpine + => [internal] load metadata for docker.io/library/node:lts-alpine => [internal] load build context => => transferring context: 53.37MB - => [1/5] FROM docker.io/library/node:18-alpine + => [1/5] FROM docker.io/library/node:lts-alpine => CACHED [2/5] WORKDIR /app => [3/5] COPY package.json yarn.lock ./ => [4/5] RUN yarn install --production @@ -127,10 +127,10 @@ dependencies if there was a change to the `package.json`. => => transferring dockerfile: 37B => [internal] load .dockerignore => => transferring context: 2B - => [internal] load metadata for docker.io/library/node:18-alpine + => [internal] load metadata for docker.io/library/node:lts-alpine => [internal] load build context => => transferring context: 450.43kB - => [1/5] FROM docker.io/library/node:18-alpine + => [1/5] FROM docker.io/library/node:lts-alpine => CACHED [2/5] WORKDIR /app => CACHED [3/5] COPY package.json yarn.lock ./ => CACHED [4/5] RUN yarn install --production From b04982b93fe3a11f50c9a76809e667c49ab9f3ff Mon Sep 17 00:00:00 2001 From: Michael Bear <38406045+mjbear@users.noreply.github.com> Date: Wed, 13 Nov 2024 20:28:57 -0500 Subject: [PATCH 2/2] Replace node:18 with node:lts in 09_image_best.md --- content/get-started/workshop/09_image_best.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/content/get-started/workshop/09_image_best.md b/content/get-started/workshop/09_image_best.md index f465fe94a0..a84842d75f 100644 --- a/content/get-started/workshop/09_image_best.md +++ b/content/get-started/workshop/09_image_best.md @@ -182,7 +182,7 @@ for your production build. You can ship the static resources in a static nginx c ```dockerfile # syntax=docker/dockerfile:1 -FROM node:18 AS build +FROM node:lts AS build WORKDIR /app COPY package* yarn.lock ./ RUN yarn install @@ -194,7 +194,7 @@ FROM nginx:alpine COPY --from=build /app/build /usr/share/nginx/html ``` -In the previous Dockerfile example, it uses the `node:18` image to perform the build (maximizing layer caching) and then copies the output +In the previous Dockerfile example, it uses the `node:lts` image to perform the build (maximizing layer caching) and then copies the output into an nginx container. ## Summary