Cant get Nextcloud to work via Portainer (Can you check my stack)

  • I am struggling to get Nextcloud working via Portainer on OMV6, when creating my admin user and initial setup, I constantly get the error:

    Error while trying to create admin user: Failed to connect to the database: An exception occurred in the driver: SQLSTATE[HY000] [1045] Access denied for user 'nextcloud'@'172.19.0.3' (using password: YES)


    I have tried wiping the stack, containers, and images and re-pulling, tried various combinations of passwords, tried username as nextcloud, database name as nextcloud and database host as db. I am wondering if the issue is with my volumes or a permissions? I have tried using guides online but none seem to work or they assume you are using a proxy manager, which I don't want to do as I want this to be a local only instance which I access via Tailscale.


    Anyway, here is my stack, I would really appreciate if someone could lend a hand as I have been trying for days:


    version: '2'


    volumes:

    nextcloud:

    db:


    services:

    db:

    image: mariadb

    container_name: nextcloud-database

    restart: always

    command: --transaction-isolation=READ-COMMITTED --binlog-format=ROW --innodb-file-per-table=1 --skip-innodb-read-only-compressed

    volumes:

    - /srv/dev-disk-by-uuid-1e54ed30-70b5-4c8b-8f8e-dabce498af23/NextcloudDB/AppData/Nextcloud/database:/var/lib/mysql:/var/lib/mysql

    environment:

    - MYSQL_ROOT_PASSWORD=placeholder1

    - MYSQL_PASSWORD=placeholder1

    - MYSQL_DATABASE=nextcloud

    - MYSQL_USER=nextcloud


    app:

    image: nextcloud

    container_name: nextcloud

    restart: always

    ports:

    - 9323:80

    links:

    - db

    volumes:

    - /srv/dev-disk-by-uuid-1e54ed30-70b5-4c8b-8f8e-dabce498af23/Nextcloud/Nextcloud/data:/var/www/html/data

    - /srv/dev-disk-by-uuid-1e54ed30-70b5-4c8b-8f8e-dabce498af23/Nextcloud/AppData/Nextcloud/main:/var/www/html:/var/www/html

    - /srv/dev-disk-by-uuid-1e54ed30-70b5-4c8b-8f8e-dabce498af23/Nextcloud/AppData/Nextcloud/config:/var/www/html/config

    - /srv/dev-disk-by-uuid-1e54ed30-70b5-4c8b-8f8e-dabce498af23/Nextcloud/AppData/Nextcloud/apps:/var/www/html/custom_apps:/var/www/html/custom_apps

    environment:

    - MYSQL_PASSWORD=placeholder

    - MYSQL_DATABASE=nextcloud

    - MYSQL_USER=nextcloud

    - MYSQL_HOST=db

  • If you want to use nextcloud official docker, you need to ask help on their forum/GitHub.


    If you want to use nextcloud docker supported on the forum, follow any of the guides in that section.


    And at first look, your MySQL password doesn't match.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!