feat: add docker image (#794)

* feat: add docker image

* fix: indentation

* fix: action version

* fix: tag format

* chore: unify layer

* feat: use metadata action

* fix: set path to dockerfile
This commit is contained in:
Ilya Zlobintsev
2025-12-20 12:25:21 +02:00
committed by GitHub
parent ccec3668a4
commit c2c9ecc6aa
3 changed files with 51 additions and 1 deletions
+22
View File
@@ -0,0 +1,22 @@
FROM rust:1.91-trixie AS builder
WORKDIR /app
RUN apt update -y && apt install -y build-essential clang libdrm-dev pkg-config ocl-icd-opencl-dev
COPY rust-toolchain.toml /app
RUN cargo --version
COPY --exclude=target* . /app
RUN --mount=type=cache,target=/usr/local/cargo/registry \
--mount=type=cache,target=/app/target \
make build-release-headless && cp ./target/release/lact /usr/local/bin/lact
FROM debian:trixie-slim
RUN apt update -y && apt install -y libdrm-amdgpu1 libdrm-radeon1 libdrm-intel1 libdrm2 hwdata vulkan-tools && rm -rf /var/cache
COPY --from=builder /usr/local/bin/lact /usr/local/bin/lact
CMD ["lact", "daemon"]