Skip to content

Commit

Permalink
fix: use debian instead of alpine
Browse files Browse the repository at this point in the history
  • Loading branch information
jetsung committed Dec 10, 2024
1 parent 6e2ae90 commit 00f21c3
Showing 1 changed file with 7 additions and 14 deletions.
21 changes: 7 additions & 14 deletions Containerfile
Original file line number Diff line number Diff line change
@@ -1,29 +1,22 @@
FROM rust:alpine AS builder

RUN apk update
RUN apk add --no-cache \
openssl \
openssl-dev \
pkgconfig \
build-base

ENV OPENSSL_DIR=/usr
FROM rust:latest AS builder

WORKDIR /app
COPY . .

RUN cargo install --path .

FROM alpine:latest
FROM debian:bullseye-slim
LABEL maintainer="Jetsung Chan<[email protected]>"

RUN apk update && apk add --no-cache openssl libssl3 && rm -rf /var/cache/apk/*
# RUN apt-get update && apt-get install -y locales libssl3 libssl-dev && rm -rf /var/lib/apt/lists/* \
# && localedef -i zh_CN -c -f UTF-8 -A /usr/share/locale/locale.alias zh_CN.UTF-8
# ENV LANG zh_CN.utf8
RUN apt update && apt install -y libssl3 libssl-dev && rm -rf /var/lib/apt/lists/*

WORKDIR /app

COPY --from=builder /usr/local/cargo/bin/filetas /usr/local/bin/filetas
COPY --from=builder /app/static /app/static
COPY --from=builder /app/templates /app/templates


EXPOSE 8000
CMD [ "filetas" ]

0 comments on commit 00f21c3

Please sign in to comment.