Skip to content

Commit

Permalink
Fix packages on Docker package
Browse files Browse the repository at this point in the history
Closes #1962
  • Loading branch information
ghormann committed Sep 7, 2024
1 parent 1a7150d commit 8145fae
Show file tree
Hide file tree
Showing 2 changed files with 56 additions and 24 deletions.
67 changes: 43 additions & 24 deletions Docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,34 +5,53 @@ FROM debian:bookworm
# so building docker containers will be faster
RUN DEBIAN_FRONTEND=noninteractive apt-get update && DEBIAN_FRONTEND=noninteractive apt-get -yq upgrade

RUN echo "force-unsafe-io" > /etc/dpkg/dpkg.cfg.d/02apt-speedup
RUN echo '\
Acquire::http {No-Cache=True;};\
Acquire::https {No-Cache=True;};\
Acquire::Retries "32";\
Acquire::https::Timeout "240";\
Acquire::http::Timeout "240";\
APT::Get::Assume-Yes "true";\
APT::Install-Recommends "false";\
APT::Install-Suggests "false";\
Debug::Acquire::https "true";\
' > /etc/apt/apt.conf.d/99custom

RUN DEBIAN_FRONTEND=noninteractive apt-get install -yq -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confold" \
alsa-utils arping avahi-daemon avahi-utils locales nano net-tools \
apache2 apache2-bin apache2-data apache2-utils \
ARG PHPVER="8.2"

#
# This should exact match SD/FPP_Install.sh
#
# Packages custom to docker are listed below
#
ARG PACKAGE_LIST="alsa-utils arping avahi-daemon avahi-utils locales nano net-tools \
apache2 apache2-bin apache2-data apache2-utils libavahi-client-dev \
bc bash-completion btrfs-progs exfat-fuse lsof ethtool curl zip unzip bzip2 wireless-tools dos2unix \
fbi fbset file flite ca-certificates lshw ffmpeg mp3gain libfmt9 \
build-essential gcc g++ gdb ccache vim vim-common bison flex device-tree-compiler dh-autoreconf \
git git-core hdparm i2c-tools ifplugd less sysstat tcpdump time usbutils usb-modeswitch \
samba rsync ssh sudo shellinabox dnsmasq hostapd vsftpd ntp sqlite3 at haveged samba samba-common-bin \
mp3info mailutils dhcp-helper parprouted bridge-utils libiio-utils bsdextrautils libavahi-client-dev \
php php-cli php-common php-curl php-pear php-sqlite3 php-zip php-xml php-fpm php-bcmath \
fbi fbset file flite ca-certificates lshw gettext wget iproute2 \
build-essential ffmpeg gcc g++ gdb vim vim-common bison flex device-tree-compiler dh-autoreconf \
git git-core hdparm i2c-tools ifplugd jq less sysstat tcpdump time usbutils usb-modeswitch \
samba rsync sudo shellinabox dnsmasq hostapd vsftpd ntp sqlite3 at haveged samba samba-common-bin \
mp3info exim4 mailutils dhcp-helper parprouted bridge-utils libiio-utils libfmt9 \
php${PHPVER} php${PHPVER}-cli php${PHPVER}-fpm php${PHPVER}-common php${PHPVER}-curl php-pear \
php${PHPVER}-bcmath php${PHPVER}-sqlite3 php${PHPVER}-zip php${PHPVER}-xml \
libavcodec-dev libavformat-dev libswresample-dev libswscale-dev libavdevice-dev libavfilter-dev libtag1-dev \
vorbis-tools libgraphicsmagick++1-dev graphicsmagick-libmagick-dev-compat libmicrohttpd-dev \
gettext apt-utils x265 libtheora-dev libvorbis-dev libx265-dev iputils-ping mp3gain \
libmosquitto-dev mosquitto-clients mosquitto libzstd-dev lzma zstd gpiod libgpiod-dev libjsoncpp-dev libcurl4-openssl-dev \
gettext apt-utils x265 libtheora-dev libvorbis-dev libx265-dev iputils-ping libssl-dev libusb-1.0-0-dev \
wget flex bison pkg-config libasound2-dev mesa-common-dev python3-distutils libssl-dev libtool bsdextrautils iw && apt-get clean
fonts-freefont-ttf flex bison pkg-config libasound2-dev mesa-common-dev qrencode libusb-1.0-0-dev \
flex bison pkg-config libasound2-dev python3-setuptools libssl-dev libtool bsdextrautils iw rsyslog tzdata"

ARG PACKAGE_LIST_DOCKER=ssh

RUN echo "force-unsafe-io" > /etc/dpkg/dpkg.cfg.d/02apt-speedup
RUN echo '\
Acquire::http {No-Cache=True;};\
Acquire::https {No-Cache=True;};\
Acquire::Retries "32";\
Acquire::https::Timeout "240";\
Acquire::http::Timeout "240";\
APT::Get::Assume-Yes "true";\
APT::Install-Recommends "false";\
APT::Install-Suggests "false";\
Debug::Acquire::https "true";\
' > /etc/apt/apt.conf.d/99custom

RUN DEBIAN_FRONTEND=noninteractive apt-get install -yq -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confold" $PACKAGE_LIST

#
# These are unique to docker
#
RUN DEBIAN_FRONTEND=noninteractive apt-get install -yq -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confold" $PACKAGE_LIST_DOCKER

RUN apt-get clean

# similar to above, do this once and Docker can cache the intermediary
COPY SD/buildVLC.sh /root/buildVLC.sh
Expand Down
13 changes: 13 additions & 0 deletions SD/FPP_Install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -480,6 +480,13 @@ case "${OSVER}" in
ACTUAL_PHPVER="8.2"
PHPVER="8.2"
fi

#########################################
# WARNING
# ---------------------------------------
# If you modify this file, be sure to update Docker/Dockerfile
#########################################

PACKAGE_LIST="alsa-utils arping avahi-daemon avahi-utils locales nano net-tools \
apache2 apache2-bin apache2-data apache2-utils libavahi-client-dev \
bc bash-completion btrfs-progs exfat-fuse lsof ethtool curl zip unzip bzip2 wireless-tools dos2unix \
Expand Down Expand Up @@ -517,9 +524,15 @@ case "${OSVER}" in
if [ "${OSVER}" == "debian_12" ]; then
PACKAGE_LIST="$PACKAGE_LIST python3-distutils"
fi


if $skip_apt_install; then
echo "skipping apt install because skpt_apt_install == $skip_apt_install"
PACKAGE_LIST=""
else
echo "--------------------------"
echo "INSTALLING $PACKAGE_LIST"
echo "--------------------------"
apt-get -y -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confold" install ${PACKAGE_LIST}
fi

Expand Down

0 comments on commit 8145fae

Please sign in to comment.