Skip to content

Commit

Permalink
Create traildepot folder during Docker build.
Browse files Browse the repository at this point in the history
  • Loading branch information
ignatz committed Nov 20, 2024
1 parent 6bb517a commit ac672c4
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,17 @@ COPY . .

RUN RUSTFLAGS="-C target-feature=+crt-static" cargo build --target x86_64-unknown-linux-gnu --release --bin trail


FROM alpine:3.20 AS runtime
RUN apk add --no-cache tini curl

COPY --from=builder /app/target/x86_64-unknown-linux-gnu/release/trail /app/

# When `docker run` is executed, launch the binary as unprivileged user.
RUN adduser -D trailbase

RUN mkdir -p /app/traildepot
RUN chown trailbase /app/traildepot
USER trailbase

WORKDIR /app
Expand Down

0 comments on commit ac672c4

Please sign in to comment.