You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

37 lines
1.1 KiB

FROM quay.io/redhat-et/rhel-bootc-tegra:base
ARG ADMIN_USERNAME=demo \
ADMIN_PASSWORD=redhat \
ENABLE_DNF_CACHE=1 \
LOCAL_RPM_REPO=0
RUN <<EOF
set -Eeuo pipefail
if [[ "$ENABLE_DNF_CACHE" == "1" ]] && ! grep -qxF 'keepcache=1' /etc/dnf/dnf.conf; then
echo "Enabling dnf cache..."
sed -i.bak '/^\[main\]$/a keepcache=1' /etc/dnf/dnf.conf
fi
if [[ "$LOCAL_RPM_REPO" == "1" ]]; then
echo "Disabling Subscription Manager because we have no internet connection and no satelite..."
echo -e "[main]\nenabled=0" > /etc/dnf/plugins/subscription-manager.conf
fi
if [[ "$LOCAL_RPM_REPO" != "1" ]]; then
#dnf config-manager --enable codeready-builder-for-rhel-9-$(arch)-rpms
dnf install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm
fi
dnf install -y mkpasswd NetworkManager-wifi podman skopeo git
if [ -n "$ADMIN_USERNAME" ]; then
useradd -m -G wheel -p "$(echo -n "$ADMIN_PASSWORD" | mkpasswd -m bcrypt --stdin)" "$ADMIN_USERNAME"
fi
EOF
ADD --chown=root:root root /
RUN set -Eeuo pipefail ; \
systemctl enable nvidia-ctk-init.service ; \
systemctl enable git-repo.service