Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build(node): upgrade to node v20.11.0 and related dependency #1195

Merged
merged 3 commits into from
Jun 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 6 additions & 7 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,13 @@ jobs:
run: |
poetry install

- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: 8

- name: Setup Yarn install
uses: borales/actions-yarn@v4
with:
cmd: install
node-version: '20.x'

- name: install via yarn2
run: |
yarn install --immutable

- name: Run ruff on src
run: |
Expand Down
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
lts/carbon
lts/iron
9 changes: 3 additions & 6 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,17 +1,14 @@
# [Node Stage to get node_modolues and node dependencies]
FROM node:8.16.0-buster-slim as node_base
FROM node:20.11.0-bullseye-slim as node_base
# [Python Stage for Django web server]
FROM python:3.10.14-slim-bullseye as python_base

FROM node_base as node_deps
COPY ./yarn.lock yarn.lock
COPY ./package.json package.json

RUN apt-get update
RUN apt-get install python-pip -y

RUN npm install -g yarn
RUN yarn install --dev --frozen-lockfile && yarn cache clean
RUN corepack enable
RUN yarn install --immutable
mattwang44 marked this conversation as resolved.
Show resolved Hide resolved

FROM python_base as python_deps
ENV APP_DIR /usr/local/app
Expand Down
9 changes: 5 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,12 @@
"@babel/plugin-syntax-import-meta": "^7.10.4",
"@babel/plugin-transform-class-properties": "^7.23.2",
"@babel/preset-env": "^7.23.2",
"autoprefixer": "^8.0.0",
"autoprefixer": "^10.4.19",
"babelify": "^10.0.0",
"browserify": "^16.1.0",
"node-sass": "^4.9.0",
"postcss-cli": "^5.0.0"
"browserify": "^17.0.0",
"node-sass": "^9.0.0",
"postcss": "^8.4.38",
mattwang44 marked this conversation as resolved.
Show resolved Hide resolved
"postcss-cli": "^11.0.0"
},
"dependencies": {
"blueimp-gallery": "^2.44.0",
Expand Down
2 changes: 1 addition & 1 deletion src/pycontw2016/settings/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ def node_bin(name):
COMPRESS_SCSS_COMPILER_CMD = (
'{node_sass_bin} --include --output-style expanded {paths} '
'--include-path="{node_modules}" "{infile}" "{outfile}" && '
'{postcss_bin} --use "{node_modules}/autoprefixer" '
'{postcss_bin} --use "{node_modules}/autoprefixer/lib/autoprefixer.js" '
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

原本文件中的command 會抓不到其他套件,所以改用這樣的方式處理

'--autoprefixer.browsers "{autoprefixer_browsers}" -r "{outfile}"'
)

Expand Down
Loading
Loading