Docker Community Forums

Share and learn in the Docker community.

Nextcloud in Docker - Reset Admin Password

Hello there!

I hope I am in the right section.

Using docker on a Synology NAS I have installed a Nextcloud which is working fine so far. But now I face the problem that I have lost the Administratorpassword for the nextcloud.
Searching the Nextcloud-forums I found out that generally the following bash-command is able to reset the Admin password:

sudo -u www-data php /var/www/nextcloud/occ user:resetpassword admin

Unlucky me, the sudo command cannot be used in the Docker bash. Because I am a total noob in Linux and bash I now need help to change the command to get it to run it in the Docker-terminal.

Hope somebody can help me!
(Sorry for my rusty English!)