mirror of
https://github.com/MCSManager/MCSManager.git
synced 2024-11-27 06:59:54 +08:00
chore: change base image to node:lts-alpine to reduce image size
This commit is contained in:
parent
3822a7bfb4
commit
d6f0691828
@ -1,7 +1,7 @@
|
||||
ARG EMBEDDED_JAVA_VERSION=21
|
||||
ARG BUILDPLATFORM=linux/amd64
|
||||
|
||||
FROM --platform=${BUILDPLATFORM} node:lts AS builder
|
||||
FROM --platform=${BUILDPLATFORM} node:lts-alpine AS builder
|
||||
|
||||
WORKDIR /src
|
||||
COPY . /src
|
||||
@ -9,9 +9,8 @@ COPY . /src
|
||||
RUN chmod a+x ./install-dependents.sh &&\
|
||||
chmod a+x ./build.sh &&\
|
||||
./install-dependents.sh &&\
|
||||
./build.sh
|
||||
|
||||
RUN wget --input-file=lib-urls.txt --directory-prefix=production-code/daemon/lib/ &&\
|
||||
./build.sh &&\
|
||||
wget --input-file=lib-urls.txt --directory-prefix=production-code/daemon/lib/ &&\
|
||||
chmod a+x production-code/daemon/lib/*
|
||||
|
||||
FROM eclipse-temurin:${EMBEDDED_JAVA_VERSION}-jdk
|
||||
|
@ -1,5 +1,5 @@
|
||||
ARG BUILDPLATFORM=linux/amd64
|
||||
FROM --platform=${BUILDPLATFORM} node:lts AS builder
|
||||
FROM --platform=${BUILDPLATFORM} node:lts-alpine AS builder
|
||||
|
||||
WORKDIR /src
|
||||
COPY . /src
|
||||
@ -9,7 +9,7 @@ RUN chmod a+x ./install-dependents.sh &&\
|
||||
./install-dependents.sh &&\
|
||||
./build.sh
|
||||
|
||||
FROM node:lts
|
||||
FROM node:lts-alpine
|
||||
|
||||
WORKDIR /opt/mcsmanager/web
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user