-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathContainerfile
More file actions
30 lines (21 loc) · 908 Bytes
/
Copy pathContainerfile
File metadata and controls
30 lines (21 loc) · 908 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# SPDX-License-Identifier: MPL-2.0
# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) <j.d.a.jewell@open.ac.uk>
#
# Containerfile for 007-lang
# Build: podman build -t oo7-lang:latest -f Containerfile .
# Run: podman run --rm -it oo7-lang:latest
# Seal: selur seal oo7-lang:latest
# --- Build stage ---
FROM cgr.dev/chainguard/wolfi-base@sha256:016283cce63df878d2e7dbef006a36ad07a130eaa833ea6ecca53c022a855c7b AS build
RUN apk add --no-cache rust cargo
WORKDIR /build
COPY . .
RUN cargo build --release
# --- Runtime stage ---
FROM cgr.dev/chainguard/static@sha256:06da8503112471f5e132ade40ccde0679f5e730191fde7852e74fdb00e404a8f
COPY --from=build /build/target/release/oo7-cli /usr/local/bin/oo7
# Copy example programs for interactive use
COPY --from=build /build/examples/ /examples/
# Non-root user (chainguard images default to nonroot)
USER nonroot
ENTRYPOINT ["/usr/local/bin/oo7"]