to be done after all container updates

#!/bin/bash
apt update
apt install -y lsb-release

cat <<EOF >/etc/apt/sources.list
deb http://debian.volia.net/debian $(lsb_release -sc) main contrib non-free
deb-src http://debian.volia.net/debian $(lsb_release -sc) main contrib non-free

deb http://mirror.mirohost.net/debian-security $(lsb_release -sc)-security main contrib non-free non-free-firmware
deb-src http://mirror.mirohost.net/debian-security $(lsb_release -sc)-security main contrib non-free

deb http://debian.netforce.hosting/debian $(lsb_release -sc)-updates main contrib non-free non-free-firmware
deb-src http://debian.netforce.hosting/debian $(lsb_release -sc)-updates main contrib non-free
EOF

#ffmpeg

cat <<EOF >>/etc/apt/sources.list

deb http://debian.ids-services.de/debian-multimedia/ $(lsb_release -sc) main
deb-src http://debian.ids-services.de/debian-multimedia/ $(lsb_release -sc) main
EOF

apt update -oAcquire::AllowInsecureRepositories=true
apt install -y --allow-unauthenticated deb-multimedia-keyring

apt update
apt install -y --allow-unauthenticated sudo vim git wget exiftool vainfo intel-media-va-driver-non-free ffmpeg

# render group have different id in different systems (TBD autodetect)
groupadd -g 992 render
usermod -a -G video www-data
usermod -a -G render www-data

#imagemagic
apt install -y libde265-0
apt install -y libheif1
apt install -y imagemagick-7

echo "LimitRequestBody 0" > /etc/apache2/conf-enabled/apache-limits.conf

sed -i '/memory_limit/d' /usr/local/etc/php/conf.d/nextcloud.ini
sed -i '/upload_max_filesize/d' /usr/local/etc/php/conf.d/nextcloud.ini
sed -i '/post_max_size/d' /usr/local/etc/php/conf.d/nextcloud.ini
sed -i '/max_execution_time/d' /usr/local/etc/php/conf.d/nextcloud.ini
sed -i '/max_input_time/d' /usr/local/etc/php/conf.d/nextcloud.ini
sed -i '/max_file_uploads/d' /usr/local/etc/php/conf.d/nextcloud.ini
echo "memory_limit=15G" >>/usr/local/etc/php/conf.d/nextcloud.ini
echo "upload_max_filesize=100G" >>/usr/local/etc/php/conf.d/nextcloud.ini
echo "post_max_size=100G" >>/usr/local/etc/php/conf.d/nextcloud.ini
echo "max_execution_time = 3600" >>/usr/local/etc/php/conf.d/nextcloud.ini
echo "max_input_time = 3600" >>/usr/local/etc/php/conf.d/nextcloud.ini
echo "max_file_uploads = 1000" >>/usr/local/etc/php/conf.d/nextcloud.ini

service apache2 reload

echo "--------------------------------------- PHP Imagick ---------------------------"
php -r 'phpinfo();' |grep ImageMagick

echo "--------------------------------------- Imagick -------------------------------"
convert -version

echo "--------------------------------------- VAinfo --------------------------------"
vainfo

echo "--------------------------------------- ffmpeg --------------------------------"
ffmpeg -codecs |grep -e 265 -e 264


  • No labels