I have a NAS.
I want to run a simple web server on it, to make my files accessible over the internet.
I also want to be able to share files from my daily driver windows machine via that same server.
I’m a noob with linux, so I need help to do that
I am running Ubuntu 22.04. I installed something called webinoly, which seems an easy way to keep a simple web server running and up to date.
Next I tried to mount a folder on my windows machine and serve that mounted location.
I run the following command
sudo mount -t cifs -o credentials=~/.smbcredentials,uid=www-data,gid=www-data,mfsymlinks //192.168.0.2/c$/users/martixy/srv/ /mnt/http_mount/nas/main
Initially, I had a small permissions issue - the server runs with user www-data, so I mount with uid=www-data
to not get 403 Forbidden responses from my shared folder.
That mount goes away when the server is restarted. So I have to run the command manually. How do I make it persistent? (I assume fstab will somehow be involved) Nvm, figured out that bit by myself.
But the bigger remaining issue is:
How do I share symlinked files?
Here’s a listing for the directory with a symlink:
lrwxr-xr-x 1 www-data www-data 47 Aug 29 22:50 'Killing Catgirls.gif' -> '/??/E:/DnD/Killing Catgirls.gif'
Searching on the internet seemed to indicate mfsymlinks
option might help, but it didn’t.
I want to be able to share files without having to copy them.
Alternatively, I am open to other home-lab cloud solutions
Also, I am looking for a recommendation for a different web server package (i.e. LEMP) - this webinoly thing is crazy poorly documented. I desperately want to get rid of it. (Actually I think the guy just decided to hide the docs behind a paywall. Then claim he’s “Making NGINX easy for everyone” on twitter. What an asshole. Thank god for the web archive.)