mirror of
https://mau.dev/andreijiroh-dev/website.git
synced 2024-11-21 16:13:38 +00:00
build(docker): install node by copying files from official image
This commit is contained in:
parent
03c329238f
commit
e991b4b677
1 changed files with 7 additions and 4 deletions
|
@ -1,12 +1,18 @@
|
|||
# syntax=docker/dockerfile:1
|
||||
FROM python:3.12-alpine AS buildkit
|
||||
# Instead of using Alpine base image and then installing Python from pkgs.al.o,
|
||||
# we'll go with the official images instead.
|
||||
FROM python:3.12-alpine AS buildkit
|
||||
|
||||
# Since hadolint isn't in the package repos for Alpine yet, we'll copying from the offical
|
||||
# Docker image instead.
|
||||
COPY --from=ghcr.io/hadolint/hadolint:latest-alpine /bin/hadolint /usr/bin/hadolint
|
||||
|
||||
# Copy build artifacts from official node image into here
|
||||
ENV YARN_VERSION 1.22.22
|
||||
COPY --from=node:20-alpine /opt/yarn-v$YARN_VERSION/bin/ /usr/local/bin/
|
||||
COPY --from=node:20-alpine /usr/local/bin/node /usr/local/bin/node
|
||||
COPY --from=node:20-alpine /usr/lib/node_modules/ /usr/lib/node_modules/
|
||||
|
||||
ENV PACKAGES=/usr/local/lib/python3.11/site-packages PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/root/.local/bin PYTHONDONTWRITEBYTECODE=1
|
||||
LABEL org.opencontainers.image.description="GitLab CI image for custom mkdocs-material Docker image, alongside tools @ajhalili2006 use."
|
||||
|
||||
|
@ -26,9 +32,6 @@ RUN apk add --no-cache \
|
|||
gcc \
|
||||
libffi-dev \
|
||||
musl-dev \
|
||||
nodejs \
|
||||
npm \
|
||||
yarn \
|
||||
git \
|
||||
git-email \
|
||||
git-lfs \
|
||||
|
|
Loading…
Reference in a new issue