Hey there
I know, it’s not good practice to just join a community and immediately ask questions without any contribution at all, but I’m quite stuck with my problem.
The Situation
I’ve watched Lawrence System’s Tutorial on how to setup NextCloud on TrueNAS (https://www.youtube.com/watch?v=8Cxg1mAYtL8) and it worked fine. The setup now looks like this:
As in the tutorial explained, I made a dataset for the config and one for the data. Now I want to access the “Generell” SMB-Share of my local network with NextCloud. The goal of this operation is to remove the NextCloud overhead when in the local LAN for more performance but still use NextCloud for automatic backup or access via smartphone.
I watched a couple of tutorials on this topic but they all failed me when I had to add an smbclient to my NextCloud Container in order to make the connection.
Is what i want to do dumb and I should just use NextCloud for everything since the overhead isn’t that big after all?
If the Idea isn’t stupid, how could I install the smbclient on my docker?
How would I need to handle the permissions for such a shared folder? Should I choose to use the “Generell” Dataset as my data directory for NextCloud instead of “NextCloud_Data”?
Not by any means dumb, but IMO violates Occam’s Razor in that NextCloud can upload files from a Windows or Linux folder directly without SMB sharing.
Suggest you look for the answer in another YouTube tutorial by Lawrence Systems: How To Setup TrueNAS Scale Apps With Shares For Host Path Volumes https://www.youtube.com/watch?v=vXGs221il3g
This demos how to set up an SMB share for Syncthing but probably the process is much the same although NextCloud storage entries in the app setup are more complex and I don’t know how those entries would work.
hi, you can add ‘smbclient’ in nextcloud parameters.On your second screen, next to “Application Info” clic on → “edit”. find “Command” and choose “smbclient” after that your nextcloud will restart and you can find SMB/CIFS in external storage. HF
I have found success installing smbclient in TrueNAS Scale inside my Nextcloud container, but I have to reinstall it every time I restart the app. I can’t find an image with smbclient already on it to use, so this works for me as long as I remember to do it.
First I use the Shell in the TrueNAS WebUI to find my NextCloud Container Name:
sudo docker ps
Then I open that container and install smbclient with the following commands:
Hello everyone.
I don’t use smbclient with docker/nextcloud anymore.
I installed an FTP server in docker to share a directory that is also an SMB share, with FTP on nextcloud there is no problem, everything works fine.
One way to make it persistent is to make your own container based on nextcloud. Then you can add whatever you want and it stays on restarts. Requires decent docker and compose skills though.
@sos_nz thanks for your Docker compose file. I am not a docker and compose expert.
question: what should be done when there is a new release of Nextcloud, should the image be rebuilt?
Done in the above manner, you simply click update on the apps screen. Mine still show as needing to be updated when a new version comes out. There’s slightly more to it though, what nextcloud version you are running (all in one or not)? His compose is not all in one.
I find the a-i-o image bloated and complicated. It sets up multiple containers, which are difficult (to me at least!) to edit and customise if required.
When Nextcloud notifies me there’s a new version, I purge the old images (‘docker system prune -a’ in TrueNAS’s shell), then rebuild from the Dockge console using ‘docker build --no-cache’ from within the nextcloud stack’s directory.
I then have to replace the default .htaccess file which nextcloud installs with my own customised .htaccess file, since I haven’t found a reliable way to automate that yet.
I use Dockge, installed as a TrueNAS app, to manage my stacks, FWIW.
I installed the aio version once and I also find it too complicated.
I am now using the official “normal” version.
I read on several forums that Nextcloud does not provide smbclient as standard because it is not stable, what do you think about that.
Totally and completely agree! I was pointing it out to the OP in case he needed aio.
I don’t have to delete any images, in the UI, I just click update, that’s it. Mine is custom built via dockerfile on Truenas and it’s automatic.
My compose isn’t terribly useful to post as it’s not a complete standalone stack for nextcloud. I have a separate mariadb and I despise postgres and need mariadb for many purposes.