fix service
All checks were successful
Create and publish a Docker image / build-and-push-image (push) Successful in 26m18s

This commit is contained in:
Nicholas Orlowsky 2025-09-14 13:49:34 -04:00
parent 3d1e213798
commit 534c36b0f7
No known key found for this signature in database
GPG key ID: A9F3BA4C0AA7A70B
2 changed files with 20 additions and 8 deletions

View file

@ -1,11 +1,11 @@
FROM rust:1.86.0 as build
FROM rust:alpine as build
ENV PKG_CONFIG_ALLOW_CROSS=1
ENV SCCACHE_DIR=/build-cache
ENV RUSTC_WRAPPER=sccache
RUN apt update && apt install sccache
RUN apk add pkgconfig openssl-dev libc-dev openssl-libs-static sccache
WORKDIR .
COPY ./api ./api
@ -16,8 +16,20 @@ COPY ./api/templates ./templates
RUN cd api && cargo build --release
FROM alpine:latest
WORKDIR /app
RUN apk update \
&& apk add openssl ca-certificates
EXPOSE 8080
COPY --from=build /api/target/release/septastic_api /app/septastic_api
COPY api/assets /app/assets
COPY api/templates /app/templates
ENV RUST_LOG=info
ENV EXPOSE_PORT=8080
EXPOSE 8080
ENTRYPOINT ["/api/target/release/septastic_api"]
RUN ls -lah
RUN pwd
ENTRYPOINT ["./septastic_api"]