-
Notifications
You must be signed in to change notification settings - Fork 0
/
Containerfile.nvidia
38 lines (28 loc) · 1013 Bytes
/
Containerfile.nvidia
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
ARG FEDORA_VERSION=40
ARG FEDORA_EDITION=base
ARG BASE_IMAGE=ghcr.io/rsturla/eternal-linux/main/${FEDORA_EDITION}
ARG BASE_TAG=${FEDORA_VERSION}
ARG BASE_IMAGE_FULL=${BASE_IMAGE}:${BASE_TAG}
ARG NVIDIA_AKMODS_IMAGE=ghcr.io/rsturla/akmods/nvidia
ARG NVIDIA_AKMODS_TAG=${FEDORA_VERSION}
FROM ${NVIDIA_AKMODS_IMAGE}:${NVIDIA_AKMODS_TAG} as akmods-nvidia
FROM ${BASE_IMAGE_FULL} as base-nvidia
ARG FEDORA_VERSION
COPY files/_nvidia /
COPY scripts /tmp/scripts
COPY --from=akmods-nvidia /rpms /tmp/akmods/rpms
COPY --from=akmods-nvidia /info /tmp/akmods/info
COPY --from=akmods-nvidia /scripts /tmp/akmods/scripts
RUN chmod +x /tmp/akmods/scripts/*.sh && \
chmod +x /tmp/scripts/*.sh \
&& \
/tmp/akmods/scripts/00-preinstall.sh && \
/tmp/akmods/scripts/01-install.sh && \
/tmp/akmods/scripts/02-postinstall.sh \
&& \
./tmp/scripts/cleanup.sh \
&& \
echo "import '/usr/share/eternal/nvidia.just'" >> /usr/share/eternal/justfile \
&& \
rm -rf /var/* /tmp/* && \
ostree container commit