__ungleich_nextcloud/manifest
2017-04-23 08:22:31 +02:00

38 lines
963 B
Bash
Executable file

#!/bin/sh
os=$(cat "$__global/explorer/os")
if [ ! "$os" = "debian" ]
then
echo "OS $os is currently not supported." >&2
exit 1
fi
os_version=$(cat "$__global/explorer/os_version")
case "$os_version" in
8*)
:
;;
9*)
:
;;
*)
echo "Unsupported version $os_version of $os." >&2
exit 1
;;
esac
# Install packages
for package in php7.0 php7.0-gd php7.0-json php7.0-pgsql php7.0-curl php7.0-mbstring \
php7.0-intl php7.0-mcrypt php-imagick php7.0-xml php7.0-zip php7.0-bz2 \
postgresql nginx
do __package $package --state=present
done
# Nginx
require="__package/nginx" __file /etc/nginx/sites-enabled/nextcloud --owner www-data \
--group www-data \
--mode 755 --source "$__type/files/nextcloud.nginx" \
--state exists
# Postgres
require="__package/postgresql" __postgres_database nextcloud --owner nextcloud
require="__package/postgresql" __start_on_boot postgres