-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
7 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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" ] |