Nextcloud AIO install with external storage

Hello

I have installed Nextcloud AIO using the below docker-compose

version: "3.8"

*olumes:
 nextcloud_aio_mastercontainer:
   name: nextcloud_aio_mastercontainer
services:
 nextcloud:
   image: nextcloud/all-in-one:latest
   restart: unless-stopped
   container_name: nextcloud-aio-mastercontainer
   volumes:
     - nextcloud_aio_mastercontainer:/mnt/docker-aio-config
     - /var/run/docker.sock:/var/run/docker.sock:ro
   ports:
     - 8195:8080 # change the port on the left side if it's already in use on your host system.
   environment:
     - APACHE_PORT=11000  # change this port number if 11000 is already in use on your host system.
     - APACHE_DISABLE_REWRITE_IP=1
     - NEXTCLOUD_TRUSTED_DOMAINS=[my domain] 10.0.2.15 # Your domain name + proxy host IP
     - TRUSTED_PROXIES=10.0.2.15 # proxy host IP
     - NEXTCLOUD_DATADIR="/mnt/media/aekash_Nextcloud/ncdata"
     - NEXTCLOUD_MOUNT="/mnt/media/aekash_Nextcloud"

When I log onto NextCloud and create folders and documents they do not appear under the Nextcloud DataDirectory specified above.

I have run the below commands and restarted the nextcloud-aio-mastercontainer container

Sudo chown -R 33:0 /mnt/media/aekash_Nextcloud/ncdata
sudo chmod -R 750 /mnt/media/aekash_Nextcloud

Would really appreciate if somebody could help me resolve the issue. I am not 100% sure whether with Nextcloud AIO in order to allow the NextCloud container to access a storage directory on the host you have to use the External Storage app ? I have installed the External Storage app but when accessing the app I recieve "No external storage configured or you don’t have the permission to configure them (I am logged in as the administrator)

On the host itself the following permissions are set

drwxr-x— 6 www-data root 4096 Feb 26 13:49 /mnt/media/aekash_Nextcloud/ncdata
drwxr-x— 3 root root 4096 Feb 26 13:47 /mnt/media/aekash_Nextcloud

Thanks
Aekash

Hi, did you already restart the containers from the AIO interface?

Hi,

I have, did it twice but still no joy…

I see. Did you already try sudo docker-compose down and sudo docker-compose up in the correct directory containing this docker-compose.yml file?

I have, I am using Portainer.

With NextCloud AIO do you have to use the external storage app to use local external storage ?

No, you don’t. Adjusting NEXTCLOUD_DATADIR to the desired path should indeed work. Can you post the output of sudo docker inspect nextcloud-aio-mastercontainer && sudo docker inspect nextcloud-aio-nextcloud ?

Sure

When I attempt to paste the output I get “An error occurred: Sorry, new users can only put 4 links in a post”

I am unable to attach the output as an attachment as well

You should be able to put the output into 3 backticks:
```
your-content-here
```

Here you go…

Please note the values for both NEXTCLOUD_DATADIR and NEXTCLOUD_MOUNT are actually as per below as opposed to the original email I sent.

  • NEXTCLOUD_DATADIR=“/mnt/media/BhujMandir_Nextcloud/ncdata”
  • NEXTCLOUD_MOUNT=“/mnt/media/BhujMandir_Nextcloud”
[
    {
        "Id": "07371e37ac894c4c7700b411d09fa9e9826d682f11be6508a67cc6dc2a4b1544",
        "Created": "2023-02-27T09:18:35.766578746Z",
        "Path": "start.sh",
        "Args": [
            "/usr/bin/supervisord",
            "-c",
            "/supervisord.conf"
        ],
        "State": {
            "Status": "running",
            "Running": true,
            "Paused": false,
            "Restarting": false,
            "OOMKilled": false,
            "Dead": false,
            "Pid": 451027,
            "ExitCode": 0,
            "Error": "",
            "StartedAt": "2023-02-27T09:18:36.484191736Z",
            "FinishedAt": "0001-01-01T00:00:00Z",
            "Health": {
                "Status": "healthy",
                "FailingStreak": 0,
                "Log": [
                    {
                        "Start": "2023-02-27T09:21:37.091036744Z",
                        "End": "2023-02-27T09:21:37.213580005Z",
                        "ExitCode": 0,
                        "Output": ""
                    },
                    {
                        "Start": "2023-02-27T09:22:07.223156081Z",
                        "End": "2023-02-27T09:22:07.355185696Z",
                        "ExitCode": 0,
                        "Output": ""
                    },
                    {
                        "Start": "2023-02-27T09:22:37.357832467Z",
                        "End": "2023-02-27T09:22:37.458083895Z",
                        "ExitCode": 0,
                        "Output": ""
                    },
                    {
                        "Start": "2023-02-27T09:23:07.470333801Z",
                        "End": "2023-02-27T09:23:07.585832732Z",
                        "ExitCode": 0,
                        "Output": ""
                    },
                    {
                        "Start": "2023-02-27T09:23:37.588922521Z",
                        "End": "2023-02-27T09:23:37.709507756Z",
                        "ExitCode": 0,
                        "Output": ""
                    }
                ]
            }
        },
        "Image": "sha256:261f690c504288e68478671c168fc8943cd5fac90b4899d456d99a4062d5f2c5",
        "ResolvConfPath": "/var/lib/docker/containers/07371e37ac894c4c7700b411d09fa9e9826d682f11be6508a67cc6dc2a4b1544/resolv.conf",
        "HostnamePath": "/var/lib/docker/containers/07371e37ac894c4c7700b411d09fa9e9826d682f11be6508a67cc6dc2a4b1544/hostname",
        "HostsPath": "/var/lib/docker/containers/07371e37ac894c4c7700b411d09fa9e9826d682f11be6508a67cc6dc2a4b1544/hosts",
        "LogPath": "/var/lib/docker/containers/07371e37ac894c4c7700b411d09fa9e9826d682f11be6508a67cc6dc2a4b1544/07371e37ac894c4c7700b411d09fa9e9826d682f11be650                                                 8a67cc6dc2a4b1544-json.log",
        "Name": "/nextcloud-aio-mastercontainer",
        "RestartCount": 0,
        "Driver": "overlay2",
        "Platform": "linux",
        "MountLabel": "",
        "ProcessLabel": "",
        "AppArmorProfile": "docker-default",
        "ExecIDs": null,
        "HostConfig": {
            "Binds": [
                "/var/run/docker.sock:/var/run/docker.sock:ro",
                "nextcloud_aio_mastercontainer:/mnt/docker-aio-config"
            ],
            "ContainerIDFile": "",
            "LogConfig": {
                "Type": "json-file",
                "Config": {}
            },
            "NetworkMode": "nextcloud_default",
            "PortBindings": {
                "8080/tcp": [
                    {
                        "HostIp": "",
                        "HostPort": "8080"
                    }
                ]
            },
            "RestartPolicy": {
                "Name": "unless-stopped",
                "MaximumRetryCount": 0
            },
            "AutoRemove": false,
            "VolumeDriver": "",
            "VolumesFrom": [],
            "ConsoleSize": [
                0,
                0
            ],
            "CapAdd": [
                "AUDIT_WRITE",
                "CHOWN",
                "DAC_OVERRIDE",
                "FOWNER",
                "FSETID",
                "KILL",
                "MKNOD",
                "NET_BIND_SERVICE",
                "NET_RAW",
                "SETFCAP",
                "SETGID",
                "SETPCAP",
                "SETUID",
                "SYS_CHROOT"
            ],
            "CapDrop": [
                "AUDIT_CONTROL",
                "BLOCK_SUSPEND",
                "DAC_READ_SEARCH",
                "IPC_LOCK",
                "IPC_OWNER",
                "LEASE",
                "LINUX_IMMUTABLE",
                "MAC_ADMIN",
                "MAC_OVERRIDE",
                "NET_ADMIN",
                "NET_BROADCAST",
                "SYSLOG",
                "SYS_ADMIN",
                "SYS_BOOT",
                "SYS_MODULE",
                "SYS_NICE",
                "SYS_PACCT",
                "SYS_PTRACE",
                "SYS_RAWIO",
                "SYS_RESOURCE",
                "SYS_TIME",
                "SYS_TTY_CONFIG",
                "WAKE_ALARM"
            ],
            "CgroupnsMode": "private",
            "Dns": [],
            "DnsOptions": null,
            "DnsSearch": null,
            "ExtraHosts": [],
            "GroupAdd": null,
            "IpcMode": "private",
            "Cgroup": "",
            "Links": null,
            "OomScoreAdj": 0,
            "PidMode": "",
            "Privileged": false,
            "PublishAllPorts": false,
            "ReadonlyRootfs": false,
            "SecurityOpt": null,
            "UTSMode": "",
            "UsernsMode": "",
            "ShmSize": 67108864,
            "Runtime": "runc",
            "Isolation": "",
            "CpuShares": 0,
            "Memory": 0,
            "NanoCpus": 0,
            "CgroupParent": "",
            "BlkioWeight": 0,
            "BlkioWeightDevice": null,
            "BlkioDeviceReadBps": null,
            "BlkioDeviceWriteBps": null,
            "BlkioDeviceReadIOps": null,
            "BlkioDeviceWriteIOps": null,
            "CpuPeriod": 0,
            "CpuQuota": 0,
            "CpuRealtimePeriod": 0,
            "CpuRealtimeRuntime": 0,
            "CpusetCpus": "",
            "CpusetMems": "",
            "Devices": [],
            "DeviceCgroupRules": null,
            "DeviceRequests": null,
            "MemoryReservation": 0,
            "MemorySwap": 0,
            "MemorySwappiness": null,
            "OomKillDisable": null,
            "PidsLimit": null,
            "Ulimits": null,
            "CpuCount": 0,
            "CpuPercent": 0,
            "IOMaximumIOps": 0,
            "IOMaximumBandwidth": 0,
            "MaskedPaths": [
                "/proc/asound",
                "/proc/acpi",
                "/proc/kcore",
                "/proc/keys",
                "/proc/latency_stats",
                "/proc/timer_list",
                "/proc/timer_stats",
                "/proc/sched_debug",
                "/proc/scsi",
                "/sys/firmware"
            ],
            "ReadonlyPaths": [
                "/proc/bus",
                "/proc/fs",
                "/proc/irq",
                "/proc/sys",
                "/proc/sysrq-trigger"
            ]
        },
        "GraphDriver": {
            "Data": {
                "LowerDir": "/var/lib/docker/overlay2/ec406ab649fc7d1226df83483bfa13b9e3f4b06c5b9591ed9ea83d86ea1fd68f-init/diff:/var/lib/docker/overlay2/d126b                                                 af2da2db3cd7f52d918903f4cc3ade1044d1269d9e2388c642a2fe03914/diff:/var/lib/docker/overlay2/9d77649b03383c941b2844a0cb2f684c36dca71b231806533abcc7a3d5631694/diff                                                 :/var/lib/docker/overlay2/87f89c6753ecf76043fd8fb263a11e9a88fe531d659bf0d6e9692d0ec2025bbd/diff:/var/lib/docker/overlay2/405bdccb44231d307ad019d0b7602df61459ef                                                 2049a5ff316363ba83df5bbc12/diff:/var/lib/docker/overlay2/d873c8dfcd330ec39940b1b2237fb443d2042d5b898a09dd655dd5d37fd343c2/diff:/var/lib/docker/overlay2/6e31074                                                 7c07e5c7375536ad257dab297702b7c36b3d0afaff4c2dcb7a37edaba/diff:/var/lib/docker/overlay2/3dcf0c4fe226ac1396c9b776af4ebdba891e2ce00e35ff0103b67020d94dde43/diff:/                                                 var/lib/docker/overlay2/3a04ed01903a3e62575ff1caae94375380036964118a9e41d79d06901add400a/diff:/var/lib/docker/overlay2/182f377013824e1aceba2b7d83edae1c0d73a6fc                                                 9520ce6d85f9d1b033a74f9a/diff:/var/lib/docker/overlay2/01fddf7d002e21eddf4afc5462281116aafedae68163dc9bfbd2410dc2468404/diff:/var/lib/docker/overlay2/2973b09bd                                                 78e3df3044855f9505e988ea22cac62d401b70b7619f802ec622243/diff:/var/lib/docker/overlay2/b089e67f819a4decb966ec58df0093be388999fa09509432b6d86075432751fc/diff:/va                                                 r/lib/docker/overlay2/ae7699d5e93da5df685b0ce6629f85bb25f53d84ba3831d82d26442921b818e1/diff:/var/lib/docker/overlay2/64b19f02de93f672f218de8b0ec562b4e2ef9bdb7f                                                 988c74e1da9823dd926d11/diff:/var/lib/docker/overlay2/e67bf843938b66f80fdea57aaf8d24740f33b20bdd26a397bfb1ab4de0a52526/diff:/var/lib/docker/overlay2/99e0483b774                                                 2613145284eef3441b0683e28859f3f8dc49063f521a446e5f81a/diff:/var/lib/docker/overlay2/1b72ae2ba9cb006cc7b1208c9c70aff22e8febae9e56fbfd34ccb08172dbc0cc/diff:/var/                                                 lib/docker/overlay2/f80e60a1da49cbdce58b3aa30d9bc2c261314622afa1e6d0e02e270051af3119/diff:/var/lib/docker/overlay2/4f5f66067b20357182dce132f0381b61c77db4a44098                                                 7ef7fad71199ff92d1ca/diff:/var/lib/docker/overlay2/1dcecb1c914c19297d4e8a4bd712a542a73d57cb3cc14e9f18b12098dc9cf8af/diff:/var/lib/docker/overlay2/7af6ac38cb8f6                                                 024effb3b029850f333fd66aae154da03408760a51a6982d5a7/diff:/var/lib/docker/overlay2/79a7d124750a87fb33f31890795ed391cc5c7a6d3a1506b169a4ada94bc9d561/diff:/var/li                                                 b/docker/overlay2/c777257037467c04795f78d09619f48edb504dd48679be9060ffd5da258bd538/diff:/var/lib/docker/overlay2/ec9bc456531bf003101728a08ada43cb3bec5b2ea0cc7b                                                 5fee5974379781101d/diff:/var/lib/docker/overlay2/68494e6ed3776b4044a9458b6190ad213bf188f9ddaa0f44b2127626539b2dc5/diff:/var/lib/docker/overlay2/c5f5fd90396e612                                                 04f3c324f42680e2d8c7b15e028de6af4d846d115da7c1dd7/diff:/var/lib/docker/overlay2/4d9ed2762d927c24edc514c1b51f8cf54dd5b1a59fcce81498fb901a146e66ad/diff:/var/lib/                                                 docker/overlay2/1348dd9f04e104257f63b87e11d5193ba9a3c9a34dfc10fd25b6dc70a97e5747/diff:/var/lib/docker/overlay2/6e8d9ba2a93e380a44e1afb241b9b5f52acf54586ea1f813                                                 4b8ff09addc8cc96/diff:/var/lib/docker/overlay2/bc5817ddef6cc8bbd01ce3a89fd77290f54b4bcc10e703d18c7432d80be6ffc5/diff:/var/lib/docker/overlay2/c4ace335b73af6aa4                                                 68b2863c16ac999445a162a62376263648b1bf01f7807a4/diff:/var/lib/docker/overlay2/6a3597aae36bc7aa57e10088678e7e692c5017d74689fec384761d3295583a8e/diff:/var/lib/do                                                 cker/overlay2/d9e1d4f92bf872c55ce24529cf5b06ace07f6d1ea437f50b90295ff88dc33d48/diff:/var/lib/docker/overlay2/3e2fb6d66f9bafda017ed34d65bdfe605ec88eac48598a7d45                                                 d2a57dced692e6/diff:/var/lib/docker/overlay2/2aceb4c8e67055e124aa3020a1079d3ca9753f59acbb84a01c72f6d5c7d11abd/diff",
                "MergedDir": "/var/lib/docker/overlay2/ec406ab649fc7d1226df83483bfa13b9e3f4b06c5b9591ed9ea83d86ea1fd68f/merged",
                "UpperDir": "/var/lib/docker/overlay2/ec406ab649fc7d1226df83483bfa13b9e3f4b06c5b9591ed9ea83d86ea1fd68f/diff",
                "WorkDir": "/var/lib/docker/overlay2/ec406ab649fc7d1226df83483bfa13b9e3f4b06c5b9591ed9ea83d86ea1fd68f/work"
            },
            "Name": "overlay2"
        },
        "Mounts": [
            {
                "Type": "bind",
                "Source": "/var/run/docker.sock",
                "Destination": "/var/run/docker.sock",
                "Mode": "ro",
                "RW": false,
                "Propagation": "rprivate"
            },
            {
                "Type": "volume",
                "Name": "nextcloud_aio_mastercontainer",
                "Source": "/var/lib/docker/volumes/nextcloud_aio_mastercontainer/_data",
                "Destination": "/mnt/docker-aio-config",
                "Driver": "local",
                "Mode": "z",
                "RW": true,
                "Propagation": ""
            }
        ],
        "Config": {
            "Hostname": "425ccd56fc81",
            "Domainname": "",
            "User": "root",
            "AttachStdin": false,
            "AttachStdout": false,
            "AttachStderr": false,
            "ExposedPorts": {
                "80/tcp": {},
                "8080/tcp": {},
                "8443/tcp": {},
                "9000/tcp": {}
            },
            "Tty": false,
            "OpenStdin": false,
            "StdinOnce": false,
            "Env": [
                "APACHE_PORT=11000",
                "APACHE_DISABLE_REWRITE_IP=1",
                "NEXTCLOUD_TRUSTED_DOMAINS=bmnxc101.nndevws.com 10.0.8.15",
                "TRUSTED_PROXIES=10.0.8.15",
                "NEXTCLOUD_DATADIR=/mnt/media/BhujMandir_Nextcloud/ncdata",
                "NEXTCLOUD_MOUNT=/mnt/media/BhujMandir_Nextcloud",
                "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
                "PHPIZE_DEPS=autoconf \t\tdpkg-dev dpkg \t\tfile \t\tg++ \t\tgcc \t\tlibc-dev \t\tmake \t\tpkgconf \t\tre2c",
                "PHP_INI_DIR=/usr/local/etc/php",
                "PHP_CFLAGS=-fstack-protector-strong -fpic -fpie -O2 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64",
                "PHP_CPPFLAGS=-fstack-protector-strong -fpic -fpie -O2 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64",
                "PHP_LDFLAGS=-Wl,-O1 -pie",
                "GPG_KEYS=528995BFEDFBA7191D46839EF9BA0ADA31CBD89E 39B641343D8C104B2B146DC3F9C39DC0B9698544 F1F692238FBC1666E5A5CCD4199F9DFEF6FFBAFD",
                "PHP_VERSION=8.1.16",
                "PHP_URL=https://www.php.net/distributions/php-8.1.16.tar.xz",
                "PHP_ASC_URL=https://www.php.net/distributions/php-8.1.16.tar.xz.asc",
                "PHP_SHA256=d61f13d96a58b93c39672b58f25e1ee4ce88500f4acb1430cb01a514875c1258"
            ],
            "Cmd": [
                "/usr/bin/supervisord",
                "-c",
                "/supervisord.conf"
            ],
            "Healthcheck": {
                "Test": [
                    "CMD-SHELL",
                    "/healthcheck.sh"
                ]
            },
            "Image": "nextcloud/all-in-one:latest",
            "Volumes": {
                "/mnt/docker-aio-config": {},
                "/mnt/docker-aio-config/": {},
                "/var/run/docker.sock": {}
            },
            "WorkingDir": "/var/www/docker-aio",
            "Entrypoint": [
                "start.sh"
            ],
            "OnBuild": null,
            "Labels": {
                "com.docker.compose.config-hash": "2d66473ca8d687e472c8d71137c6d7153c2623f314ec769d45bc363a6cfbfed9",
                "com.docker.compose.container-number": "1",
                "com.docker.compose.oneoff": "False",
                "com.docker.compose.project": "nextcloud",
                "com.docker.compose.project.config_files": "docker-compose.yml",
                "com.docker.compose.project.working_dir": "/Docker/Nextcloud",
                "com.docker.compose.service": "nextcloud",
                "com.docker.compose.version": "1.29.2"
            },
            "StopSignal": "SIGQUIT"
        },
        "NetworkSettings": {
            "Bridge": "",
            "SandboxID": "d3fc52c184e694efdabd063b312750fec1a22261422263aeba9ee4e85f1df5ce",
            "HairpinMode": false,
            "LinkLocalIPv6Address": "",
            "LinkLocalIPv6PrefixLen": 0,
            "Ports": {
                "80/tcp": null,
                "8080/tcp": [
                    {
                        "HostIp": "0.0.0.0",
                        "HostPort": "8080"
                    },
                    {
                        "HostIp": "::",
                        "HostPort": "8080"
                    }
                ],
                "8443/tcp": null,
                "9000/tcp": null
            },
            "SandboxKey": "/var/run/docker/netns/d3fc52c184e6",
            "SecondaryIPAddresses": null,
            "SecondaryIPv6Addresses": null,
            "EndpointID": "",
            "Gateway": "",
            "GlobalIPv6Address": "",
            "GlobalIPv6PrefixLen": 0,
            "IPAddress": "",
            "IPPrefixLen": 0,
            "IPv6Gateway": "",
            "MacAddress": "",
            "Networks": {
                "nextcloud_default": {
                    "IPAMConfig": {},
                    "Links": null,
                    "Aliases": [
                        "425ccd56fc81",
                        "07371e37ac89"
                    ],
                    "NetworkID": "69a15c3730427f0c274bda18a09a0e6458c490bd4ba8f442fa19911381534620",
                    "EndpointID": "c37f3cdb47900f1bae8451accd36d1ed6fcedc50a06035b1fecdd5683ad21af4",
                    "Gateway": "172.18.0.1",
                    "IPAddress": "172.18.0.2",
                    "IPPrefixLen": 16,
                    "IPv6Gateway": "",
                    "GlobalIPv6Address": "",
                    "GlobalIPv6PrefixLen": 0,
                    "MacAddress": "02:42:ac:12:00:02",
                    "DriverOpts": null
                }
            }
        }
    }
]
[
    {
        "Id": "3d2ef08d6ddf6c2c4e30d7061e2b9f3e0c5a60316b2aa68a72068e95d81f7d74",
        "Created": "2023-02-26T13:47:36.771231299Z",
        "Path": "/start.sh",
        "Args": [
            "/usr/bin/supervisord",
            "-c",
            "/supervisord.conf"
        ],
        "State": {
            "Status": "running",
            "Running": true,
            "Paused": false,
            "Restarting": false,
            "OOMKilled": false,
            "Dead": false,
            "Pid": 46056,
            "ExitCode": 0,
            "Error": "",
            "StartedAt": "2023-02-26T13:47:38.2128365Z",
            "FinishedAt": "0001-01-01T00:00:00Z",
            "Health": {
                "Status": "healthy",
                "FailingStreak": 0,
                "Log": [
                    {
                        "Start": "2023-02-27T09:21:35.860953768Z",
                        "End": "2023-02-27T09:21:35.96204092Z",
                        "ExitCode": 0,
                        "Output": ""
                    },
                    {
                        "Start": "2023-02-27T09:22:05.966535684Z",
                        "End": "2023-02-27T09:22:06.107460887Z",
                        "ExitCode": 0,
                        "Output": ""
                    },
                    {
                        "Start": "2023-02-27T09:22:36.120381964Z",
                        "End": "2023-02-27T09:22:36.265797511Z",
                        "ExitCode": 0,
                        "Output": ""
                    },
                    {
                        "Start": "2023-02-27T09:23:06.269175766Z",
                        "End": "2023-02-27T09:23:06.377149445Z",
                        "ExitCode": 0,
                        "Output": ""
                    },
                    {
                        "Start": "2023-02-27T09:23:36.389747578Z",
                        "End": "2023-02-27T09:23:36.543217315Z",
                        "ExitCode": 0,
                        "Output": ""
                    }
                ]
            }
        },
        "Image": "sha256:77a2bf30e3b718adc5f25da7d998987055254a7463aca02e6b31153dcbfd3bae",
        "ResolvConfPath": "/var/lib/docker/containers/3d2ef08d6ddf6c2c4e30d7061e2b9f3e0c5a60316b2aa68a72068e95d81f7d74/resolv.conf",
        "HostnamePath": "/var/lib/docker/containers/3d2ef08d6ddf6c2c4e30d7061e2b9f3e0c5a60316b2aa68a72068e95d81f7d74/hostname",
        "HostsPath": "/var/lib/docker/containers/3d2ef08d6ddf6c2c4e30d7061e2b9f3e0c5a60316b2aa68a72068e95d81f7d74/hosts",
        "LogPath": "/var/lib/docker/containers/3d2ef08d6ddf6c2c4e30d7061e2b9f3e0c5a60316b2aa68a72068e95d81f7d74/3d2ef08d6ddf6c2c4e30d7061e2b9f3e0c5a60316b2aa68                                                 a72068e95d81f7d74-json.log",
        "Name": "/nextcloud-aio-nextcloud",
        "RestartCount": 0,
        "Driver": "overlay2",
        "Platform": "linux",
        "MountLabel": "",
        "ProcessLabel": "",
        "AppArmorProfile": "docker-default",
        "ExecIDs": null,
        "HostConfig": {
            "Binds": [
                "nextcloud_aio_nextcloud:/var/www/html:rw",
                "/mnt/media/BhujMandir_Nextcloud/ncdata:/mnt/ncdata:rw",
                "/mnt/media/BhujMandir_Nextcloud:/mnt/media/BhujMandir_Nextcloud:rw"
            ],
            "ContainerIDFile": "",
            "LogConfig": {
                "Type": "json-file",
                "Config": {}
            },
            "NetworkMode": "nextcloud-aio",
            "PortBindings": null,
            "RestartPolicy": {
                "Name": "unless-stopped",
                "MaximumRetryCount": 0
            },
            "AutoRemove": false,
            "VolumeDriver": "",
            "VolumesFrom": null,
            "ConsoleSize": [
                0,
                0
            ],
            "CapAdd": null,
            "CapDrop": null,
            "CgroupnsMode": "private",
            "Dns": null,
            "DnsOptions": null,
            "DnsSearch": null,
            "ExtraHosts": null,
            "GroupAdd": null,
            "IpcMode": "private",
            "Cgroup": "",
            "Links": null,
            "OomScoreAdj": 0,
            "PidMode": "",
            "Privileged": false,
            "PublishAllPorts": false,
            "ReadonlyRootfs": false,
            "SecurityOpt": null,
            "UTSMode": "",
            "UsernsMode": "",
            "ShmSize": 67108864,
            "Runtime": "runc",
            "Isolation": "",
            "CpuShares": 0,
            "Memory": 0,
            "NanoCpus": 0,
            "CgroupParent": "",
            "BlkioWeight": 0,
            "BlkioWeightDevice": null,
            "BlkioDeviceReadBps": null,
            "BlkioDeviceWriteBps": null,
            "BlkioDeviceReadIOps": null,
            "BlkioDeviceWriteIOps": null,
            "CpuPeriod": 0,
            "CpuQuota": 0,
            "CpuRealtimePeriod": 0,
            "CpuRealtimeRuntime": 0,
            "CpusetCpus": "",
            "CpusetMems": "",
            "Devices": null,
            "DeviceCgroupRules": null,
            "DeviceRequests": null,
            "MemoryReservation": 0,
            "MemorySwap": 0,
            "MemorySwappiness": null,
            "OomKillDisable": null,
            "PidsLimit": null,
            "Ulimits": null,
            "CpuCount": 0,
            "CpuPercent": 0,
            "IOMaximumIOps": 0,
            "IOMaximumBandwidth": 0,
            "MaskedPaths": [
                "/proc/asound",
                "/proc/acpi",
                "/proc/kcore",
                "/proc/keys",
                "/proc/latency_stats",
                "/proc/timer_list",
                "/proc/timer_stats",
                "/proc/sched_debug",
                "/proc/scsi",
                "/sys/firmware"
            ],
            "ReadonlyPaths": [
                "/proc/bus",
                "/proc/fs",
                "/proc/irq",
                "/proc/sys",
                "/proc/sysrq-trigger"
            ]
        },
        "GraphDriver": {
            "Data": {
                "LowerDir": "/var/lib/docker/overlay2/f025c511702bba302555cfe37f6f8a7c91283a165fde5e7675849881850a8a9c-init/diff:/var/lib/docker/overlay2/f7a9b                                                 8d0e878d24fa6fc483a00ada776e5c8b30c0b398fd75a7ba3ad8b833922/diff:/var/lib/docker/overlay2/fca4d206ae6e2f7bdbce0d72b2c225520d3977203b7141207f29101ff4351ad5/diff                                                 :/var/lib/docker/overlay2/9ded461b1639f4937b1169297756989843c3d68db4461cd506c8391fe45bb2f6/diff:/var/lib/docker/overlay2/9b50837a5da0d983dbe5548ead1397f369d677                                                 8cc50cb6f6d663ea29dcf53f07/diff:/var/lib/docker/overlay2/3e87774484d77e6f09a9cdcec0ba0536b17a1f3069ee6533400c244b29470000/diff:/var/lib/docker/overlay2/ea22193                                                 41e473c01e6ad5901f1bb4a301203b2d2ee873d9b1dbd6a33595b9a99/diff:/var/lib/docker/overlay2/cf729d64219d39c5c7ff50df3efc24ad8cf7ad11217549e40b516b2e21d2dc5e/diff:/                                                 var/lib/docker/overlay2/35b5107d7bc1f6a743ee983ebc5bfd874f8e212720149f1832396230b51cc1a1/diff:/var/lib/docker/overlay2/1d9b4fa813d437c3181dcc7e9d33d32402cbbd60                                                 a9ea9598a11473937cd88b94/diff:/var/lib/docker/overlay2/cd948848458eb9bb91d6b66aa58dd26f1f40e23724ec453753ff6ce587b7d4b7/diff:/var/lib/docker/overlay2/bec2534e0                                                 982ffa1c94616ef53a95da06424686cbd27acec507f8f4cb91e2943/diff:/var/lib/docker/overlay2/49137da195dbc5b9eb68ba33aae9f8e714e7553cb37ca8bf720a341cd8c53912/diff:/va                                                 r/lib/docker/overlay2/a8e86c6ab9081370b6c0de9a3037e9d0e1134739ea8509f80c73a82ab3a082e9/diff:/var/lib/docker/overlay2/a811624e82c937a91c81aa92f2783fa882842fab09                                                 3ca7c899ab115859a7d6e4/diff:/var/lib/docker/overlay2/718df2f589da0d7a76188c1c06cfa3ec98feb0d4369dd17100a3e364ad87a460/diff:/var/lib/docker/overlay2/ddbfeb5d522                                                 c5b9d1f34958fd8a4f838184b5064cf709945e9d836bd88872661/diff:/var/lib/docker/overlay2/18cb8e11fe0f3f02f30a678cf8485f8a94a5fc399d653bed7f60a190778d2763/diff:/var/                                                 lib/docker/overlay2/82820f43b2a465f7166de41a86c44266bb924aabbf008236ef1defb18bb9789d/diff:/var/lib/docker/overlay2/7ba9615478bc65b33fc1d91d68fa270afd423656a4bd                                                 e2a9b3119647785de129/diff:/var/lib/docker/overlay2/52425af1eaa1d9cc91b3ffb6749f7965f35564b4e15ef94a6b179e1df5714554/diff:/var/lib/docker/overlay2/be098db99ef50                                                 06f5f3be9e93d71aef812331798bb02403302a789c50728307c/diff:/var/lib/docker/overlay2/39cb5044089ea40e7689caa70034e5279479b1822662f1aa3535e66d51f4c4c1/diff:/var/li                                                 b/docker/overlay2/9307d00d992d2cf874de19989c014d49cf32c677f1241309771dc32a4c4630b0/diff:/var/lib/docker/overlay2/57a3ee5f3ce972296d390c24a898cdb418204b2f71dd9b                                                 d9d18be43997d5e813/diff:/var/lib/docker/overlay2/3b3e6946caa590474e6ae7cca907f414918dd4bc35ea2e51d98dcb8476819a08/diff:/var/lib/docker/overlay2/a96dd3ce4734957                                                 29e359b9356e539faad66708680b083ef1ed868481964a365/diff:/var/lib/docker/overlay2/f9949402c7ef9ffb83400361de9d528b0db7b6703ed5ec312c787d2c623af230/diff:/var/lib/                                                 docker/overlay2/6763a80d855b14558705ff1025444a5793b1653aa42b1355828a17598f968eba/diff:/var/lib/docker/overlay2/be3e5353b7f29dbb16638b6361dfaf4ad46652c4199dc0f1                                                 08ae1335722a2ae6/diff:/var/lib/docker/overlay2/4229f658633984f256386f63db9539074f3247a1aea2a1be40022107568cc17a/diff:/var/lib/docker/overlay2/98ab32002138131c4                                                 92a384497bf1b8bd8c25f31cb2da336c1cf8d67dcaaf350/diff",
                "MergedDir": "/var/lib/docker/overlay2/f025c511702bba302555cfe37f6f8a7c91283a165fde5e7675849881850a8a9c/merged",
                "UpperDir": "/var/lib/docker/overlay2/f025c511702bba302555cfe37f6f8a7c91283a165fde5e7675849881850a8a9c/diff",
                "WorkDir": "/var/lib/docker/overlay2/f025c511702bba302555cfe37f6f8a7c91283a165fde5e7675849881850a8a9c/work"
            },
            "Name": "overlay2"
        },
        "Mounts": [
            {
                "Type": "bind",
                "Source": "/mnt/media/BhujMandir_Nextcloud/ncdata",
                "Destination": "/mnt/ncdata",
                "Mode": "rw",
                "RW": true,
                "Propagation": "rprivate"
            },
            {
                "Type": "bind",
                "Source": "/mnt/media/BhujMandir_Nextcloud",
                "Destination": "/mnt/media/BhujMandir_Nextcloud",
                "Mode": "rw",
                "RW": true,
                "Propagation": "rprivate"
            },
            {
                "Type": "volume",
                "Name": "nextcloud_aio_nextcloud",
                "Source": "/var/lib/docker/volumes/nextcloud_aio_nextcloud/_data",
                "Destination": "/var/www/html",
                "Driver": "local",
                "Mode": "rw",
                "RW": true,
                "Propagation": ""
            }
        ],
        "Config": {
            "Hostname": "3d2ef08d6ddf",
            "Domainname": "",
            "User": "root",
            "AttachStdin": false,
            "AttachStdout": false,
            "AttachStderr": false,
            "ExposedPorts": {
                "9000/tcp": {}
            },
            "Tty": false,
            "OpenStdin": false,
            "StdinOnce": false,
            "Env": [
                "POSTGRES_HOST=nextcloud-aio-database",
                "POSTGRES_PASSWORD=d13144375e621ed8bb098148c85de4b999521159d7dd0da7",
                "POSTGRES_DB=nextcloud_database",
                "POSTGRES_USER=nextcloud",
                "REDIS_HOST=nextcloud-aio-redis",
                "REDIS_HOST_PASSWORD=3508588d5cce2cd93eb8f1543d1ff688e7319ab96508a063",
                "AIO_TOKEN=393e8fc6249ef5e2e6540b5700b63e81837b3e65a254cb50",
                "NC_DOMAIN=bmnxc101.nndevws.com",
                "ADMIN_USER=admin",
                "ADMIN_PASSWORD=d388dc2fd30fb94e010fee5711f1c1cb416b9d852d25ba6c",
                "NEXTCLOUD_DATA_DIR=/mnt/ncdata",
                "OVERWRITEHOST=bmnxc101.nndevws.com",
                "OVERWRITEPROTOCOL=https",
                "TURN_SECRET=264235df1b56419f37bfa2d014c49918b6b01e8681366f13",
                "SIGNALING_SECRET=3ebb093193d5c7a147a0cb1f4b8cb29c0d720b82a07121ed",
                "ONLYOFFICE_SECRET=39dbb73d1f6a3dfbaf3a5c60ef6fd2499f7d160b9a8e1d8c",
                "AIO_URL=10.0.8.14:8080",
                "NEXTCLOUD_MOUNT=/mnt/media/BhujMandir_Nextcloud",
                "CLAMAV_ENABLED=",
                "CLAMAV_HOST=nextcloud-aio-clamav",
                "ONLYOFFICE_ENABLED=",
                "COLLABORA_ENABLED=yes",
                "COLLABORA_HOST=nextcloud-aio-collabora",
                "TALK_ENABLED=",
                "ONLYOFFICE_HOST=nextcloud-aio-onlyoffice",
                "UPDATE_NEXTCLOUD_APPS=",
                "TZ=UTC",
                "TALK_PORT=3478",
                "IMAGINARY_ENABLED=",
                "IMAGINARY_HOST=nextcloud-aio-imaginary",
                "PHP_UPLOAD_LIMIT=10G",
                "PHP_MEMORY_LIMIT=512M",
                "FULLTEXTSEARCH_ENABLED=",
                "FULLTEXTSEARCH_HOST=nextcloud-aio-fulltextsearch",
                "PHP_MAX_TIME=3600",
                "TRUSTED_CACERTS_DIR=",
                "STARTUP_APPS=deck twofactor_totp tasks calendar contacts",
                "ADDITIONAL_APKS=imagemagick",
                "ADDITIONAL_PHP_EXTENSIONS=imagick",
                "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
                "PHPIZE_DEPS=autoconf \t\tdpkg-dev dpkg \t\tfile \t\tg++ \t\tgcc \t\tlibc-dev \t\tmake \t\tpkgconf \t\tre2c",
                "PHP_INI_DIR=/usr/local/etc/php",
                "PHP_CFLAGS=-fstack-protector-strong -fpic -fpie -O2 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64",
                "PHP_CPPFLAGS=-fstack-protector-strong -fpic -fpie -O2 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64",
                "PHP_LDFLAGS=-Wl,-O1 -pie",
                "GPG_KEYS=1729F83938DA44E27BA0F4D3DBDB397470D12172 BFDDD28642824F8118EF77909B67A5C12229118F 2C16C765DBE54A088130F1BC4B9B5F600B55F3B4",
                "PHP_VERSION=8.0.28",
                "PHP_URL=https://www.php.net/distributions/php-8.0.28.tar.xz",
                "PHP_ASC_URL=https://www.php.net/distributions/php-8.0.28.tar.xz.asc",
                "PHP_SHA256=5e07278a1f315a67d36a676c01343ca2d4da5ec5bdb15d018e4248b3012bc0cd",
                "NEXTCLOUD_VERSION=25.0.3",
                "NEXTCLOUD_UPDATE=1"
            ],
            "Cmd": [
                "/usr/bin/supervisord",
                "-c",
                "/supervisord.conf"
            ],
            "Healthcheck": {
                "Test": [
                    "CMD-SHELL",
                    "sudo -E -u www-data bash /healthcheck.sh"
                ]
            },
            "Image": "nextcloud/aio-nextcloud:latest",
            "Volumes": {
                "/mnt/ncdata": {},
                "/var/www/html": {}
            },
            "WorkingDir": "/var/www/html",
            "Entrypoint": [
                "/start.sh"
            ],
            "OnBuild": null,
            "Labels": {
                "com.centurylinklabs.watchtower.monitor-only": "true"
            },
            "StopSignal": "SIGQUIT"
        },
        "NetworkSettings": {
            "Bridge": "",
            "SandboxID": "5686d80e286a3a5b6a872bc49b5f66db813f1f07ab0a21249d708a2a6bd95f17",
            "HairpinMode": false,
            "LinkLocalIPv6Address": "",
            "LinkLocalIPv6PrefixLen": 0,
            "Ports": {
                "9000/tcp": null
            },
            "SandboxKey": "/var/run/docker/netns/5686d80e286a",
            "SecondaryIPAddresses": null,
            "SecondaryIPv6Addresses": null,
            "EndpointID": "",
            "Gateway": "",
            "GlobalIPv6Address": "",
            "GlobalIPv6PrefixLen": 0,
            "IPAddress": "",
            "IPPrefixLen": 0,
            "IPv6Gateway": "",
            "MacAddress": "",
            "Networks": {
                "nextcloud-aio": {
                    "IPAMConfig": null,
                    "Links": null,
                    "Aliases": [
                        "3d2ef08d6ddf"
                    ],
                    "NetworkID": "136e9bf0bbf68760654696366f316a44d90df6e70476b5b398cda2f80e993e34",
                    "EndpointID": "c20c05d5fc1c519fbea4328dfe65e300dc91b1a120426bffcba32da6097ff026",
                    "Gateway": "172.19.0.1",
                    "IPAddress": "172.19.0.6",
                    "IPPrefixLen": 16,
                    "IPv6Gateway": "",
                    "GlobalIPv6Address": "",
                    "GlobalIPv6PrefixLen": 0,
                    "MacAddress": "02:42:ac:13:00:06",
                    "DriverOpts": null
                }
            }
        }
    }
]

Okay, the settings seem to be correctly appllied as you can see here:

        "Mounts": [
            {
                "Type": "bind",
                "Source": "/mnt/media/BhujMandir_Nextcloud/ncdata",
                "Destination": "/mnt/ncdata",
                "Destination": "/mnt/ncdata",
                "Mode": "rw",
                "RW": true,
                "Propagation": "rprivate"
            },

What exactly does not work for you?

I have created a folder and some documents and when I look at the local external storage location I do not see anything relating to what I have created i.e. the Test folder and the documents…

Can you post the output of sudo ls -al /mnt/media/BhujMandir_Nextcloud/ncdata

administrator@BMNXC101:~$ sudo ls -al /mnt/media/BhujMandir_Nextcloud/ncdata
[sudo] password for administrator:
total 32
drwxr-x— 7 www-data root 4096 Feb 27 09:51 .
drwxr-x— 3 root root 4096 Feb 26 13:47 …
drwxr-x— 4 www-data root 4096 Feb 26 13:50 admin
drwxr-x— 10 www-data root 4096 Feb 26 14:19 appdata_ocdc1c2iyzwb
-rwxr-x— 1 www-data root 0 Feb 26 13:48 audit.log
drwxr-x— 2 www-data root 4096 Feb 26 13:48 files_external
-rwxr-x— 1 www-data root 542 Feb 26 13:48 .htaccess
-rwxr-x— 1 www-data root 0 Feb 26 13:48 index.html
-rwxr-x— 1 www-data root 0 Feb 26 13:48 nextcloud.log
-rwxr-x— 1 www-data root 0 Feb 26 13:48 .ocdata
drwxr-xr-x 2 www-data www-data 4096 Feb 27 09:51 Test
drwxr-x— 2 www-data root 4096 Feb 27 09:52 tmp

As you can see are the files in there. So everything seems to work as expected.

Is there a reason why I cannot see the files/ folders in the Nautilus File Manager ?

I have launched Nautilus File Manager as sudo and still cannot view the files/folders…

Yes, this is because you are opening the files with the user that you used to log in to ubuntu desktop which does not have read rights to this folder. You could use

xhost +si:localuser:root && sudo nautilus /mnt/media/BhujMandir_Nextcloud/ncdata

if you want to see them in Nautilus.

Thanks you have been a lot of help

one last question if I may

How do I ensure both sudo and a standard account can view the files and folders just launching File Manager ?

You could add your user to the group with gid 33. However I would usually not recommend to modify files or folders in the datadir via Nautilus directly as they might get out-of-sync with the database for Nextcloud and you might modify permissions in an incorrect way.

Thank you

I have run granted the account I am using to log into Ubuntu with full permissions by running the below command, however I still cannot view the folders or files. I have logged out and logged back in. I am able to create files and directories in in the folder but cannot view the files and folders which Nextcloud creates.

sudo chown -R administrator:administrator /mnt/media/BhujMandir_Nextcloud/ncdata

I basically want to be able to use the account I use to log into Ubuntu to view/ edit files etc i.e. have full permissions to the folder.

Do I need to make account administrator a member of group named www-data ?

Thanks
Aekash