switch to package install

This commit is contained in:
aptalca 2022-07-28 09:41:33 -04:00
parent b0fd5bbe94
commit 2a6bc0aeff
16 changed files with 45 additions and 11 deletions

View File

@ -1,5 +0,0 @@
#!/usr/bin/with-contenv bash
if [ -f /usr/bin/apt ]; then
apt-get update
fi

View File

@ -1 +0,0 @@
/etc/s6-overlay/s6-rc.d/init-mod-apt-get/run

View File

@ -0,0 +1,37 @@
#!/usr/bin/with-contenv bash
if [ -f "/mod-repo-packages-to-install.list" ]; then
echo "**** Installing all mod packages ****"
if [ -f /usr/bin/apt ]; then
DEBIAN_FRONTEND="noninteractive"
apt-get update
apt-get install -y \
$(cat /mod-repo-packages-to-install.list)
elif [ -f /usr/bin/apk ]; then
apk add --no-cache \
$(cat /mod-repo-packages-to-install.list)
fi
else
echo "**** No repo packages to install, skipping ****"
fi
if [ -f "/mod-pip-packages-to-install.list" ]; then
echo "**** Installing all pip packages ****"
python3 -m pip install -U pip wheel setuptools
if [ -f /usr/bin/apt ]; then
PIP_ARGS="-f https://wheel-index.linuxserver.io/ubuntu/"
elif [ -f /usr/bin/apk ]; then
ALPINE_VER=$(cat /etc/apk/repositories | grep main | sed 's|.*alpine/v||' | sed 's|/main.*||')
if [ "${ALPINE_VER}" = "3.14" ]; then
PIP_ARGS="-f https://wheel-index.linuxserver.io/alpine/"
else
PIP_ARGS="-f https://wheel-index.linuxserver.io/alpine-${ALPINE_VER}/"
fi
fi
python3 -m pip install ${PIP_ARGS} \
$(cat /mod-pip-packages-to-install.list)
fi
rm -rf \
/mod-repo-packages-to-install.list \
/mod-pip-packages-to-install.list

View File

@ -0,0 +1 @@
/etc/s6-overlay/s6-rc.d/init-mod-package-install/run

View File

@ -6,7 +6,8 @@ chown -R ${ABC_USER}:${ABC_USER} /config/logs
echo "**** installing docker and docker compose ****"
if [ -f /usr/bin/apt ]; then
apt-get install -y \
echo "**** Adding docker-in-docker dependency packages to install list ****"
echo "\
btrfs-progs \
ca-certificates \
curl \
@ -16,9 +17,10 @@ if [ -f /usr/bin/apt ]; then
openssl \
pigz \
xfsprogs \
xz-utils
xz-utils" >> /mod-repo-packages-to-install.list
else
apk add --no-cache \
echo "**** Adding docker-in-docker dependency packages to install list ****"
echo "\
btrfs-progs \
curl \
e2fsprogs \
@ -28,7 +30,7 @@ else
openssl \
pigz \
xfsprogs \
xz
xz" >> /mod-repo-packages-to-install.list
fi
ARCH=$(uname -m)
if [ -d "/docker-tgz" ] ; then

View File

@ -0,0 +1 @@
/etc/s6-overlay/s6-rc.d/init-mod-universal-docker-in-docker-add-package/run

View File

@ -1 +0,0 @@
/etc/s6-overlay/s6-rc.d/init-mod-universal-docker-in-docker/run

View File