Files
athome/Dockerfile
Tuan-Dat Tran 5ce21498e5 feat(build): Updated build to version 0.4.0
Signed-off-by: Tuan-Dat Tran <tuan-dat.tran@tudattr.dev>
2025-02-07 00:18:01 +01:00

22 lines
637 B
Docker

FROM rust:1.84.0 AS dioxus
RUN cargo install dioxus-cli@^0.6
FROM dioxus AS builder
WORKDIR /athome/
RUN apt-get update && apt install libwebkit2gtk-4.1-dev build-essential curl npm \
wget file libxdo-dev libssl-dev libayatana-appindicator3-dev librsvg2-dev -y\
&& rm -rf /var/lib/apt/lists/*
RUN npm install -D tailwindcss
COPY ./Cargo.toml ./Cargo.toml
COPY ./Dioxus.toml ./Dioxus.toml
COPY ./input.css ./input.css
COPY ./tailwind.config.js ./tailwind.config.js
COPY ./src/ ./src/
COPY ./assets/ ./assets/
RUN dx bundle --platform web
FROM alpine:3 AS runner
WORKDIR /app/
COPY --from=builder /athome/docs/ ./
CMD [ "./server" ]