I'm attempting to install nextcloud on my Rasbperry Pi 4 using the Techno Dad Life guide "Easiest Nextcloud Installation with Docker", but using the portainer web GUI rather than through docker on the command line. I've got to the NextCloudPi activation stage and click the "activate" button, but it says "Something went wrong. Try refreshing the page". I then checked the docker logs with 'sudo docker logs -f nextcloudpi' and this is what I get:
Initializing empty volume.. Making /usr/local/etc/ncp-config.d persistent ... Making /etc/services-enabled.d persistent ... Making /etc/letsencrypt persistent ... Making /etc/shadow persistent ... Making /etc/cron.d persistent ... Making /etc/cron.daily persistent ... Making /etc/cron.hourly persistent ... Making /etc/cron.weekly persistent ... Making /usr/local/bin persistent ... Making /etc/apache2 persistent ... Starting PHP-fpm Starting Apache Starting mariaDB 2020-07-13 15:46:38 0 [Note] mysqld (mysqld 10.3.22-MariaDB-0+deb10u1) starting as process 195 ... Starting Redis Starting Cron Starting Postfix Uninitialized instance, running nc-init... Running nc-init Setting up a clean Nextcloud instance... wait until message 'NC init done' Setting up database... Setting up Nextcloud... Console has to be executed with the user that owns the file config/config.php Current user: www-data Owner of config.php: root Try adding 'sudo -u root ' to the beginning of the command (without the single quotes) If running with 'docker exec' try adding the option '-u root' to the docker command (without the single quotes) Init done
It seems to be a problem with user permissions. However, I don't know how to do what it suggests, as I can't find out how to run a portainer container as 'root'. Could someone point me in the right direction please?