-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathDockerfile
More file actions
34 lines (25 loc) · 1.24 KB
/
Copy pathDockerfile
File metadata and controls
34 lines (25 loc) · 1.24 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
# SPDX-FileCopyrightText: © 2024-2025 Triad National Security, LLC.
# SPDX-FileCopyrightText: © 2026 OpenCHAMI a Series of LF Projects, LLC
#
# SPDX-License-Identifier: MIT
FROM docker.io/chainguard/wolfi-base:latest
# Include curl and tini in the final image.
RUN set -ex \
&& apk update \
&& apk add --no-cache curl tini jq dhcping \
&& rm -rf /var/cache/apk/* \
&& rm -rf /tmp/*
# Download the latest ipxe binaries from https://github.com/OpenCHAMI/ipxe-binaries/releases and unpack them in the /tftpboot directory.
RUN set -ex \
&& mkdir -p /tftpboot \
&& latest_release_url=$(curl -s https://api.github.com/repos/OpenCHAMI/ipxe-binaries/releases/latest | jq -r '.assets[] | select(.name == "ipxe.tar.gz") | .browser_download_url') \
&& curl -L $latest_release_url -o /tmp/ipxe.tar.gz \
&& tar -xzvf /tmp/ipxe.tar.gz -C /tftpboot \
&& rm /tmp/ipxe.tar.gz
# Both coredns and coredhcp are built and added to the same container.
# By default, coredhcp is started and coredns is not. To start coredns, override the CMD in the
# container runtime configuration and provide a volume with the appropriate configuration file.
COPY coredhcp /coredhcp
COPY coredns /coredns
CMD [ "/coredhcp" ]
ENTRYPOINT [ "/sbin/tini", "--" ]