-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
fd832b7
commit 8be45a2
Showing
9 changed files
with
72 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,3 +6,4 @@ | |
Dockerfile | ||
README.md | ||
test_coverage_reports/ | ||
deploy/balena-k3s/build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -46,12 +46,10 @@ RUN arkade version && \ | |
[email protected] \ | ||
[email protected] | ||
|
||
# Install kustomize | ||
RUN curl -s "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh" | bash | ||
RUN mv kustomize /usr/local/bin/kustomize | ||
|
||
# Copy edge-endpoint to /app/edge-endpoint | ||
RUN mkdir -p /app/edge-endpoint | ||
COPY . /app/edge-endpoint | ||
|
||
ENTRYPOINT [] | ||
CMD [ "tail" , "-f", "/dev/null" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
# https://hub.docker.com/r/rancher/k3s/tags | ||
# https://github.com/k3s-io/k3s/blob/master/package/Dockerfile | ||
# https://github.com/balena-io-experimental/balena-k3s/blob/main/server/Dockerfile | ||
|
||
|
||
# ----- k3s dockerfile (FROM rancher/k3s:v1.26.14-k3s1) ----- | ||
# FROM alpine:3.18 as base | ||
FROM balenalib/jetson-orin-nano-devkit-nvme-alpine:3.18-build as base | ||
|
||
RUN apk add -U ca-certificates tar zstd tzdata | ||
|
||
# Need build the k3s binary before this step | ||
COPY ./build/k3s/build/out/data.tar.zst / | ||
|
||
RUN mkdir -p /image/etc/ssl/certs /image/run /image/var/run /image/tmp /image/lib/modules /image/lib/firmware && \ | ||
tar -xa -C /image -f /data.tar.zst && \ | ||
echo "root:x:0:0:root:/:/bin/sh" > /image/etc/passwd && \ | ||
echo "root:x:0:" > /image/etc/group && \ | ||
cp /etc/ssl/certs/ca-certificates.crt /image/etc/ssl/certs/ca-certificates.crt | ||
|
||
FROM scratch as collect | ||
ARG DRONE_TAG="dev" | ||
COPY --from=base /image / | ||
COPY --from=base /usr/share/zoneinfo /usr/share/zoneinfo | ||
RUN mkdir -p /etc && \ | ||
echo 'hosts: files dns' > /etc/nsswitch.conf && \ | ||
echo "PRETTY_NAME=\"K3s ${DRONE_TAG}\"" > /etc/os-release && \ | ||
chmod 1777 /tmp | ||
|
||
FROM scratch | ||
COPY --from=collect / / | ||
VOLUME /var/lib/kubelet | ||
VOLUME /var/lib/rancher/k3s | ||
VOLUME /var/lib/cni | ||
VOLUME /var/log | ||
ENV PATH="$PATH:/bin/aux" | ||
ENV CRI_CONFIG_FILE="/var/lib/rancher/k3s/agent/etc/crictl.yaml" | ||
|
||
# ENTRYPOINT ["/bin/k3s"] | ||
# CMD ["agent"] | ||
# ----- end k3s dockerfile ----- | ||
|
||
COPY ./server/server.sh /server.sh | ||
RUN chmod +x /server.sh | ||
|
||
ENTRYPOINT [] | ||
CMD [ "/server.sh" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters