How do I create an admin account in Nextcloud?

Hello,

I have Nextcloud running on my NAS.

The Docker containers are all running and the website is displayed to me.

 CONTAINER ID  IMAGE             COMMAND  CREATED    STATUS    PORTS              NAMES 5ef00fd4e1f4  linuxserver/nextcloud:latest  "/init"  20 hours ago  Up 20 hours  80/tcp, 0.0.0.0:9443->443/tcp  nextcloud 9bd502e6a8ac  linuxserver/mariadb:latest   "/init"  20 hours ago  Up 20 hours  3306/tcp            nextcloud_db

But now when I try to create the admin account, I always get the error:

Mistake

Error while trying to create admin account: An exception occurred in the driver: SQLSTATE[HY000] [1045] Access denied for user 'nextclouduser'@'nextcloud.nextcloud_nextcloudnet' (using password: YES)

I entered the following configuration:
Data directory: /data
Set up database: MySQL/MariaDB
Database account: nextclouduser
Database password: XXXXXXXXX
Database name: nextcloud
Database host: nextcloud_db

my docker-compose.yml:

 version: "3.7" services:  nextcloud:    image: linuxserver/nextcloud:latest    container_name: nextcloud    networks:      - nextcloudnet    environment:      - PUID=1002   # dockeruser id      - PGID=100    # dockeruser group      - TZ=Europe/Berlin    volumes:      - /share/Docker/nextcloud/config:/config      - /share/Docker/nextcloud/data:/data    ports:      - 9443:443    restart: unless-stopped    depends_on:      - db  db:    image: linuxserver/mariadb:latest    container_name: nextcloud_db    networks:      - nextcloudnet    environment:      - PUID=1002      - PGID=100      - MYSQL_ROOT_PASSWORD=XXXXXXXX # replace with own password      - TZ=Europe/Berlin      - MYSQL_DATABASE=nextcloud      - MYSQL_USER=nextclouduser      - MYSQL_PASSWORD=XXXXXXXX # replace with own password    volumes:      - /share/Docker/nextcloud/config_db:/config    restart: unless-stopped networks:    nextcloudnet:        driver: bridge            ipam:          config:            - subnet: 10.0.8.0/24              gateway: 10.0.8.1
(1 votes)
Loading...

Similar Posts

Subscribe
Notify of
6 Answers
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
xxxcyberxxx
2 months ago

At first glance: you need to take the name of the service and not the name of the container.

So in database host instead of nextcloud_db only db

TheodorMssen04
2 months ago

How does the Wildcard mask look and what syntax did you use?

TheodorMssen04
2 months ago
Reply to  chandler222

Best send a screenshot from the interface.