-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathContainerfile
More file actions
61 lines (52 loc) · 2.11 KB
/
Containerfile
File metadata and controls
61 lines (52 loc) · 2.11 KB
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# --------------------------------------------------------------------------
# THIS FILE IS AUTOGENERATED - DO NOT EDIT MANUALLY
#
# Source: Containerfile.j2
# --------------------------------------------------------------------------
ARG FREEBSD_RELEASE=15.0
FROM ghcr.io/freebsd/freebsd-runtime:${FREEBSD_RELEASE}
ARG FREEBSD_MAJOR=15
ARG PKG_BRANCH=quarterly
ARG PACKAGES="FreeBSD-utilities jq ca_root_nss"
ARG VERSION=""
LABEL org.opencontainers.image.title="FreeBSD Base Core" \
org.opencontainers.image.description="Minimal FreeBSD base image without service supervision. Foundation for CLI tools and non-daemon containers." \
org.opencontainers.image.source="https://github.com/daemonless/base-core" \
org.opencontainers.image.url="https://github.com/daemonless/base-core" \
org.opencontainers.image.licenses="" \
org.opencontainers.image.vendor="daemonless" \
org.opencontainers.image.authors="daemonless" \
io.daemonless.type="base" \
io.daemonless.category="Base" \
io.daemonless.packages="${PACKAGES}"
ENV ASSUME_ALWAYS_YES=yes
ENV PUID=1000
ENV PGID=1000
ENV TZ=UTC
COPY root/ /
RUN mkdir -p /etc/pkg && \
printf '%s\n' \
'FreeBSD-ports-kmods: { enabled: no }' \
'FreeBSD-base: {' \
' url: "pkg+https://pkg.FreeBSD.org/${ABI}/base_release_${VERSION_MINOR}",' \
' mirror_type: "srv",' \
' signature_type: "fingerprints",' \
' fingerprints: "/usr/share/keys/pkgbase-${VERSION_MAJOR}",' \
' enabled: yes' \
'}' \
'FreeBSD-Ports: {' \
" url: \"pkg+https://pkg.FreeBSD.org/\${ABI}/${PKG_BRANCH}\"," \
' mirror_type: "srv",' \
' signature_type: "fingerprints",' \
' fingerprints: "/usr/share/keys/pkg",' \
' enabled: yes' \
'}' > /etc/pkg/FreeBSD.conf
RUN rm -rf /usr/local/etc/pkg/repos && \
pkg update && \
pkg install -y ${PACKAGES} && \
chmod 755 /usr/local/sbin && \
pkg clean -ay && \
rm -rf /var/cache/pkg/* /var/db/pkg/repos/*
RUN pw groupadd -n bsd -g 1000 && \
pw useradd -n bsd -u 1000 -g bsd -d /config -s /bin/sh -c "Container User"
CMD ["tail", "-f", "/dev/null"]