Skip to content

Commit cd2b1b3

Browse files
committed
fix: node 404 error
1 parent 995677b commit cd2b1b3

File tree

4 files changed

+14
-51
lines changed

4 files changed

+14
-51
lines changed

docker/build_and_push.Dockerfile

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -72,29 +72,20 @@ RUN --mount=type=cache,target=/root/.cache/uv \
7272
################################
7373
FROM python:3.12.12-slim-trixie AS runtime
7474

75+
7576
RUN apt-get update \
7677
&& apt-get upgrade -y \
77-
&& apt-get install -y curl git libpq5 gnupg xz-utils \
78+
&& apt-get install --no-install-recommends -y curl git libpq5 gnupg xz-utils \
7879
&& apt-get clean \
7980
&& rm -rf /var/lib/apt/lists/*
80-
81-
RUN NODE_VERSION=$(curl -fsSL https://nodejs.org/dist/index.json \
82-
| grep '"version": "v22' \
83-
| head -n 1 \
84-
| cut -d'"' -f4) \
85-
&& echo "Installing Node.js $NODE_VERSION" \
86-
&& curl -fsSL "https://nodejs.org/dist/$NODE_VERSION/node-$NODE_VERSION-linux-x64.tar.xz" -o node.tar.xz \
87-
&& tar -xf node.tar.xz -C /usr/local --strip-components=1 \
88-
&& rm node.tar.xz \
81+
RUN curl -fsSL https://nodejs.org/dist/latest-v22.x/node-v22-linux-x64.tar.xz \
82+
| tar -xJ -C /usr/local --strip-components=1 \
8983
&& node --version \
9084
&& npm --version
91-
9285
RUN useradd user -u 1000 -g 0 --no-create-home --home-dir /app/data
9386

9487
COPY --from=builder --chown=1000 /app/.venv /app/.venv
95-
9688
ENV PATH="/app/.venv/bin:$PATH"
97-
9889
RUN /app/.venv/bin/pip install --upgrade playwright \
9990
&& /app/.venv/bin/playwright install
10091

docker/build_and_push_base.Dockerfile

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -76,29 +76,20 @@ RUN --mount=type=cache,target=/root/.cache/uv \
7676
################################
7777
FROM python:3.12.12-slim-trixie AS runtime
7878

79+
7980
RUN apt-get update \
8081
&& apt-get upgrade -y \
81-
&& apt-get install -y curl git libpq5 gnupg xz-utils \
82+
&& apt-get install --no-install-recommends -y curl git libpq5 gnupg xz-utils \
8283
&& apt-get clean \
8384
&& rm -rf /var/lib/apt/lists/*
84-
85-
RUN NODE_VERSION=$(curl -fsSL https://nodejs.org/dist/index.json \
86-
| grep '"version": "v22' \
87-
| head -n 1 \
88-
| cut -d'"' -f4) \
89-
&& echo "Installing Node.js $NODE_VERSION" \
90-
&& curl -fsSL "https://nodejs.org/dist/$NODE_VERSION/node-$NODE_VERSION-linux-x64.tar.xz" -o node.tar.xz \
91-
&& tar -xf node.tar.xz -C /usr/local --strip-components=1 \
92-
&& rm node.tar.xz \
85+
RUN curl -fsSL https://nodejs.org/dist/latest-v22.x/node-v22-linux-x64.tar.xz \
86+
| tar -xJ -C /usr/local --strip-components=1 \
9387
&& node --version \
9488
&& npm --version
95-
9689
RUN useradd user -u 1000 -g 0 --no-create-home --home-dir /app/data
9790

9891
COPY --from=builder --chown=1000 /app/.venv /app/.venv
99-
10092
ENV PATH="/app/.venv/bin:$PATH"
101-
10293
RUN /app/.venv/bin/pip install --upgrade playwright \
10394
&& /app/.venv/bin/playwright install
10495

docker/build_and_push_ep.Dockerfile

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -77,24 +77,14 @@ RUN apt-get update \
7777
&& apt-get install --no-install-recommends -y curl git libpq5 gnupg xz-utils \
7878
&& apt-get clean \
7979
&& rm -rf /var/lib/apt/lists/*
80-
81-
RUN NODE_VERSION=$(curl -fsSL https://nodejs.org/dist/index.json \
82-
| grep '"version": "v22' \
83-
| head -n 1 \
84-
| cut -d'"' -f4) \
85-
&& echo "Installing Node.js $NODE_VERSION" \
86-
&& curl -fsSL "https://nodejs.org/dist/$NODE_VERSION/node-$NODE_VERSION-linux-x64.tar.xz" -o node.tar.xz \
87-
&& tar -xf node.tar.xz -C /usr/local --strip-components=1 \
88-
&& rm node.tar.xz \
80+
RUN curl -fsSL https://nodejs.org/dist/latest-v22.x/node-v22-linux-x64.tar.xz \
81+
| tar -xJ -C /usr/local --strip-components=1 \
8982
&& node --version \
9083
&& npm --version
91-
9284
RUN useradd user -u 1000 -g 0 --no-create-home --home-dir /app/data
9385

9486
COPY --from=builder --chown=1000 /app/.venv /app/.venv
95-
9687
ENV PATH="/app/.venv/bin:$PATH"
97-
9888
RUN /app/.venv/bin/pip install --upgrade playwright \
9989
&& /app/.venv/bin/playwright install
10090

docker/build_and_push_with_extras.Dockerfile

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -72,29 +72,20 @@ RUN --mount=type=cache,target=/root/.cache/uv \
7272
################################
7373
FROM python:3.12.12-slim-trixie AS runtime
7474

75+
7576
RUN apt-get update \
7677
&& apt-get upgrade -y \
77-
&& apt-get install -y curl git libpq5 gnupg xz-utils \
78+
&& apt-get install --no-install-recommends -y curl git libpq5 gnupg xz-utils \
7879
&& apt-get clean \
7980
&& rm -rf /var/lib/apt/lists/*
80-
81-
RUN NODE_VERSION=$(curl -fsSL https://nodejs.org/dist/index.json \
82-
| grep '"version": "v22' \
83-
| head -n 1 \
84-
| cut -d'"' -f4) \
85-
&& echo "Installing Node.js $NODE_VERSION" \
86-
&& curl -fsSL "https://nodejs.org/dist/$NODE_VERSION/node-$NODE_VERSION-linux-x64.tar.xz" -o node.tar.xz \
87-
&& tar -xf node.tar.xz -C /usr/local --strip-components=1 \
88-
&& rm node.tar.xz \
81+
RUN curl -fsSL https://nodejs.org/dist/latest-v22.x/node-v22-linux-x64.tar.xz \
82+
| tar -xJ -C /usr/local --strip-components=1 \
8983
&& node --version \
9084
&& npm --version
91-
9285
RUN useradd user -u 1000 -g 0 --no-create-home --home-dir /app/data
9386

9487
COPY --from=builder --chown=1000 /app/.venv /app/.venv
95-
9688
ENV PATH="/app/.venv/bin:$PATH"
97-
9889
RUN /app/.venv/bin/pip install --upgrade playwright \
9990
&& /app/.venv/bin/playwright install
10091

0 commit comments

Comments
 (0)