Skip to content

Commit

Permalink
feat: update base docker image from node 12 to node 18 (#172)
Browse files Browse the repository at this point in the history
Update base docker image from node 12 to node 18 and update dev dependencies
  • Loading branch information
Stephen Cefali authored Nov 29, 2023
1 parent 2b33edc commit d6dcd72
Show file tree
Hide file tree
Showing 4 changed files with 2,378 additions and 3,172 deletions.
8 changes: 6 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# The multi stage set up *saves* up image size by avoiding the dev dependencies
# required to produce dist/
FROM node:12-alpine as builder
FROM node:18-alpine as builder
WORKDIR /app
# This layer will invalidate upon new dependencies
COPY package.json yarn.lock ./
Expand All @@ -12,7 +12,7 @@ RUN export YARN_CACHE_FOLDER="$(mktemp -d)" \
COPY . .
RUN yarn build

FROM node:12-alpine as app
FROM node:18-alpine as app
COPY package.json yarn.lock /action-release/
# On the builder image, we install both types of dependencies rather than
# just the production ones. This generates /action-release/node_modules
Expand All @@ -25,6 +25,10 @@ RUN export YARN_CACHE_FOLDER="$(mktemp -d)" \
COPY --from=builder /app/dist /action-release/dist/
RUN chmod +x /action-release/dist/index.js

# move the sentry-cli binary to where the entrypoint expects it
RUN mv /action-release/node_modules/@sentry/cli/sentry-cli /action-release/sentry-cli
RUN chmod +x /action-release/sentry-cli

# XXX: This could probably be replaced with a standard CMD
COPY entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
Expand Down
28 changes: 14 additions & 14 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,22 +28,22 @@
"@sentry/cli": "^1.67.2"
},
"devDependencies": {
"@types/jest": "^26.0.0",
"@types/node": "^14.0.13",
"@typescript-eslint/parser": "^3.3.0",
"@zeit/ncc": "^0.22.3",
"eslint": "^7.2.0",
"eslint-plugin-github": "^4.0.1",
"eslint-plugin-jest": "^23.13.2",
"jest": "^26.0.1",
"jest-circus": "^26.0.1",
"js-yaml": "^3.14.0",
"prettier": "^2.0.5",
"ts-jest": "^26.1.0",
"typescript": "^3.9.5"
"@types/jest": "^29.5.6",
"@types/node": "^20.8.9",
"@typescript-eslint/parser": "^6.9.0",
"@vercel/ncc": "^0.38.1",
"eslint": "^8.52.0",
"eslint-plugin-github": "^4.10.1",
"eslint-plugin-jest": "^27.4.3",
"jest": "^29.7.0",
"jest-circus": "^29.7.0",
"js-yaml": "^4.1.0",
"prettier": "^3.0.3",
"ts-jest": "^29.1.1",
"typescript": "^5.2.2"
},
"volta": {
"node": "12.17.0",
"node": "18.17.0",
"yarn": "1.22.4"
}
}
2 changes: 1 addition & 1 deletion src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,6 @@ import * as process from 'process';
core.debug(`Done`);
core.setOutput('version', version);
} catch (error) {
core.setFailed(error.message);
core.setFailed((error as Error).message);
}
})();
Loading

0 comments on commit d6dcd72

Please sign in to comment.