Add unattended upgrades for php7
This commit is contained in:
parent
bbc3f57b4c
commit
8186a62166
|
@ -48,6 +48,15 @@ function apt_install {
|
||||||
apt_get_quiet install $PACKAGES
|
apt_get_quiet install $PACKAGES
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function apt_add_repository_to_unattended_upgrades {
|
||||||
|
if [ -f /etc/apt/apt.conf.d/50unattended-upgrades ]; then
|
||||||
|
if ! grep -q "$1" /etc/apt/apt.conf.d/50unattended-upgrades; then
|
||||||
|
sed -i "/Allowed-Origins/a \
|
||||||
|
\"$1\";" /etc/apt/apt.conf.d/50unattended-upgrades
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
function get_default_hostname {
|
function get_default_hostname {
|
||||||
# Guess the machine's hostname. It should be a fully qualified
|
# Guess the machine's hostname. It should be a fully qualified
|
||||||
# domain name suitable for DNS. None of these calls may provide
|
# domain name suitable for DNS. None of these calls may provide
|
||||||
|
|
|
@ -18,6 +18,7 @@ apt-get purge -qq -y owncloud*
|
||||||
|
|
||||||
# Install php-7 from the ppa of the ubuntu php maintainer Ondřej Surý located here https://launchpad.net/%7Eondrej/+archive/ubuntu/php
|
# Install php-7 from the ppa of the ubuntu php maintainer Ondřej Surý located here https://launchpad.net/%7Eondrej/+archive/ubuntu/php
|
||||||
hide_output add-apt-repository -y ppa:ondrej/php
|
hide_output add-apt-repository -y ppa:ondrej/php
|
||||||
|
apt_add_repository_to_unattended_upgrades LP-PPA-ondrej-php:trusty
|
||||||
hide_output apt-get update
|
hide_output apt-get update
|
||||||
apt_install php7.0 php7.0-fpm \
|
apt_install php7.0 php7.0-fpm \
|
||||||
php7.0-cli php7.0-sqlite php7.0-gd php7.0-imap php7.0-curl php-pear php-apc curl \
|
php7.0-cli php7.0-sqlite php7.0-gd php7.0-imap php7.0-curl php-pear php-apc curl \
|
||||||
|
|
Loading…
Reference in New Issue