Skip to content

Commit 1b01a1b

Browse files
committed
feat: Update container images to alpine
1 parent a27fc1c commit 1b01a1b

File tree

4 files changed

+26
-14
lines changed

4 files changed

+26
-14
lines changed

.dockerignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
Dockerfile
2+
.env
3+
target/
4+
examples/
5+

Dockerfile

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
FROM docker.io/library/rust:1.85-alpine as builder
2+
3+
ENV TARGET=x86_64-unknown-linux-musl
4+
5+
WORKDIR /app
6+
7+
COPY . .
8+
9+
# Install dependencies
10+
RUN apk update && \
11+
apk add --no-cache pkgconf alpine-sdk openssl-dev perl musl-dev && \
12+
rustup target add ${TARGET} && \
13+
cargo build --release --target ${TARGET} && \
14+
mv target/${TARGET}/release/codeql-extractor-action target/
15+
16+
FROM docker.io/library/alpine:3.21
17+
WORKDIR /app
18+
19+
COPY --from=builder /app/target/codeql-extractor-action /usr/local/bin/codeql-extractor-action
20+
21+
ENTRYPOINT ["action"]

container/Dockerfile

Lines changed: 0 additions & 14 deletions
This file was deleted.

0 commit comments

Comments
 (0)