2016-06-16 12:54:04 +02:00
|
|
|
#!/bin/sh
|
|
|
|
addgroup -g ${GID} nextcloud && adduser -h /nextcloud -s /bin/sh -D -G nextcloud -u ${UID} nextcloud
|
|
|
|
|
2016-08-16 20:02:21 +03:00
|
|
|
# Set default data directory
|
|
|
|
if [ ! -f /config/config.php ]; then
|
|
|
|
echo -e "<?php\n\$CONFIG = array (\n 'datadirectory' => '/data',\n);" > /config/config.php
|
|
|
|
fi
|
|
|
|
|
2016-06-16 12:54:04 +02:00
|
|
|
touch /var/run/php-fpm.sock
|
|
|
|
mkdir /tmp/fastcgi /tmp/client_body
|
|
|
|
chown -R nextcloud:nextcloud /nextcloud /data /config /apps2 /var/run/php-fpm.sock /var/lib/nginx /tmp
|
2016-08-16 19:23:31 +03:00
|
|
|
ln -s /config/config.php /nextcloud/config/config.php
|
2016-06-16 12:54:04 +02:00
|
|
|
ln -s /apps2 /nextcloud
|
|
|
|
|
2016-08-29 22:07:53 +02:00
|
|
|
exec supervisord -c /etc/supervisor/supervisord.conf
|