I'm trying to follow this tutorial on setting up NextCloud remote access. At about 9:57, when I go to put --network my-net into Extra arguments, I get this error:
Failed to execute command 'export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin; export LANG=C.UTF-8; docker run -d --restart=always -v /etc/localtime:/etc/localtime:ro --net=bridge -p 0.0.0.0:444:443/tcp -p 0.0.0.0:8080:80/tcp -h "fa47fe7d0d48" -e PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" -e PS1="root@HC2:/$ " -e HOME="/root" -e TERM="xterm" -e NEXTCLOUD_PATH="/config/www/nextcloud" -v "/sharedfolders/AppData/Nextcloud":"/config":rw -v "/sharedfolders/Nextcloud":"/data":rw --name="nextcloud" --label omv_docker_extra_args="--network my-net" --network my-net "linuxserver/nextcloud:latest" 2>&1' with exit code '125': docker: conflicting options: cannot attach both user-defined and non-user-defined network-modes. See 'docker run --help'.
The details are as follows:
Error #0:
OMV\ExecException: Failed to execute command 'export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin; export LANG=C.UTF-8; docker run -d --restart=always -v /etc/localtime:/etc/localtime:ro --net=bridge -p 0.0.0.0:444:443/tcp -p 0.0.0.0:8080:80/tcp -h "fa47fe7d0d48" -e PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" -e PS1="root@HC2:/$ " -e HOME="/root" -e TERM="xterm" -e NEXTCLOUD_PATH="/config/www/nextcloud" -v "/sharedfolders/AppData/Nextcloud":"/config":rw -v "/sharedfolders/Nextcloud":"/data":rw --name="nextcloud" --label omv_docker_extra_args="--network my-net" --network my-net "linuxserver/nextcloud:latest" 2>&1' with exit code '125': docker: conflicting options: cannot attach both user-defined and non-user-defined network-modes.
See 'docker run --help'. in /usr/share/php/openmediavault/system/process.inc:182
Stack trace:
#0 /usr/share/openmediavault/engined/rpc/docker.inc(607): OMV\System\Process->execute()
#1 /usr/share/openmediavault/engined/rpc/docker.inc(714): OMVRpcServiceDocker->runContainer(Array, Array)
#2 [internal function]: OMVRpcServiceDocker->modifyContainer(Array, Array)
#3 /usr/share/php/openmediavault/rpc/serviceabstract.inc(123): call_user_func_array(Array, Array)
#4 /usr/share/php/openmediavault/rpc/rpc.inc(86): OMV\Rpc\ServiceAbstract->callMethod('modifyContainer', Array, Array)
#5 /usr/sbin/omv-engined(537): OMV\Rpc\Rpc::call('Docker', 'modifyContainer', Array, Array, 1)
#6 {main}
Alles anzeigen
Then I simply have to cancel modifying the container. After this, my nextcloud container completely disappears. I tried docker restart nextcloud, and it says no such container. So then I tried creating the container again, and Nextcloud was working fine and I could access it again. Then I tried to modify again adding the Extra Arguments, and the same error and same thing happened (container disappeared). So I tried creating the container again, but with the Extra arguments added right away the first time, and got the same error. I'm not sure how to resolve this.