Switch container to debian

Signed-off-by: eternal-flame-AD <yume@yumechi.jp>
This commit is contained in:
ゆめ 2024-10-16 20:39:52 -05:00
parent 80bbdc50a0
commit d15571db8e
No known key found for this signature in database

View file

@ -1,7 +1,11 @@
FROM archlinux AS builder
FROM debian:stable-slim AS builder
RUN pacman -Sy --noconfirm \
base-devel \
RUN apt-get update && apt-get install -yqq --no-install-recommends \
build-essential \
curl \
ca-certificates \
pkg-config \
libssl-dev \
git
RUN curl -sSL https://sh.rustup.rs | bash -s -- -y --default-toolchain nightly
@ -11,12 +15,14 @@ COPY . /src
RUN cd /src && bash -c '. $HOME/.cargo/env; cargo build --release' && \
mkdir -p /target/usr/local/bin && cp /src/target/release/nyuukyou /target/usr/local/bin/nyuukyou
FROM archlinux
FROM debian:stable-slim
COPY --from=builder /target/ /
RUN pacman -Sy --noconfirm curl && \
useradd -m -u 1000 -r nyuukyou
RUN apt-get update && \
apt-get install -yqq --no-install-recommends openssl curl ca-certificates && \
useradd -m -u 1000 -r nyuukyou && \
rm -rf /var/lib/apt/lists/*
USER nyuukyou