Hey guys,

Currently im just running calibre and nextcloud docker containers over the web, with a ddns from noip and a cloudflare domain. But i also want to setup a vaultwarden container too, so now i need to really consider the security of my server. What are the main things to watch out for? Calibre and nextcloud are just using subdomains, is it okay to have a subdomain to connect to vaultwarden? Am i better off just trusting bitwarden and sticking with them?

Thanks!

28 points

IMO if you are asking such question - stick to Bitwarden cloud.

Passwords, at least to me, is something I don’t want to lose. I don’t trust myself I could provide a proper uptime & security, so I just use cloud version.

permalink
report
reply
4 points
*

I recently switched to cloud from vaultwarden. I was comfortable enough with the security, but when I started to actually plan disaster recovery, it was something I literally could not afford to get wrong.

So bitwarden is the one service I don’t, and have no plans to, self host.

permalink
report
parent
reply
3 points

Bitwarden’s official self hosting stack (not a single container) ships with nightly encrypted database dumps. And their backup page mentions just needing to backup the ‘bwdata’ folder which has worked great for me.

https://bitwarden.com/help/install-on-premise-linux/

permalink
report
parent
reply
1 point

That’s great. For me, at least, getting a server restored from backup on something like aws without access to passwords was going to require more preparation than I was willing to deal with.

Definitely worth exploring if you’re prepared to handle that though.

permalink
report
parent
reply

Yeah that was something i was worried about too, not like my server is an proper rig. Its just a shitty laptop with a slow ass HDD, and who knows how much life its got

permalink
report
parent
reply
19 points

Is there a reason you can’t just VPN in and expose only the VPN gateway? My preferred security is not exposing a bunch of random applications to the internet and hoping each doesn’t ever have any vulnerabilities.

permalink
report
reply

Yeah i could definitely do that, however would that cause much trouble regarding using the nextcloud android app, or my ereader which uses OPDS to get books from calibre? I get thatd id have to sign into the VPN, but i already use mullvad on everything.

Sorry, just dont know much about personal VPNs

permalink
report
parent
reply
3 points

As long as you’re connected to the VPN it probably shouldn’t. I use the automate app on my phone to automatically connect to my home wireguard server whenever I’m off my wi-fi, and it works great.

You’re going to run into an issue of only being able to have one VPN connected on Android at a time though if you’re already running mullvad on it, but as long as you have a decent connection at home and no data cap, you could just route all of your traffic through your home network, and then split tunnel your private IPs to connect directly, and anything else through mullvad.

permalink
report
parent
reply
3 points

Head scale would be a self-hosted way of doing this as well.

  • You’d install headscale publicly accessible on your VPS or port-forwarded server.
  • You’d configure your phone and any laptop you travel with using the tailscale apps with the special hidden setting to use your custom control-server.
  • Now any apps you want to access yourself but not for the public unauthenticated internet to see, you bind to tailscale/headscale interfaces rather than public interfaces.
  • Anything you DO want publicly accessible (for example immich for image sharing to friends who aren’t on your tailscale network) you host the normal way by binding to a public interface.

You could also do this with regular tailscale and cut the self-hosted headscale out of the picture.

But by doing this or another private VPN setup, you take the listeners for some of your apps off the internet and reduce your attack-surface. It obviously doesn’t help for WordPress or other stuff you actually want to share publicly, but it can give some peace of mind for personal services like bitwarden or Jellyfin.

permalink
report
parent
reply
14 points
Removed by mod
permalink
report
reply
13 points
*
Deleted by creator
permalink
report
reply

Have you got any resources regarding setting up a firewall? I forgot about fail2ban though, gotta set that up soon

permalink
report
parent
reply
3 points
*
Deleted by creator
permalink
report
parent
reply

Sorry, but I sincerely hope you just don’t selfhost Vaultwarden.

Are you saying this because i dont know much about firewalls and VPNs right now? Or because i dont have a good backup solution? Or something else?

Currently my backup solution might not be the nicest, but im taking regular backups on the same laptop, copying those onto an external HD, and syncing that onto my main PC, hopefully whoch should be enough

permalink
report
parent
reply
12 points

Personally I trust Bitwarden more than myself to keep all my passwords secure AND available. They’ve got a good track record as far as I’m aware.

For general security hardening though…

I use Shodan to help me identify if anything is misconfigured and what is visible from the web. You can pick up an account for usually $1 for life when they run a deal, then you can just monitor your DDNS, domain, and IP address and have it email you when any new services are detected.

Cloudflare Tunnels, to remove the need for a nginx reverse proxy (with the added benefit of easy failover as well as simplifying your stack). Then I’m utilizing Cloudflare’s WAF to handle filtering out known malicious, foreign IP addresses, and other malicious traffic.

Another route you can go is a Nginx/haproxy reverse proxy behind something like Suricata. Then you can utilize something like fail2ban or crowdsec.

Authentik. Get everything behind a SSO experience and don’t expose your backend services to unauthenticated local traffic (utilize http basic auth with header passthrough in authentik). So many people setup auth wrong and then have something like auth.domain.com going through auth but then mistakenly have their external IP address setup to allow traffic in authenticated.

permalink
report
reply

Selfhosted

!selfhosted@lemmy.world

Create post

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don’t control.

Rules:

  1. Be civil: we’re here to support and learn from one another. Insults won’t be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it’s not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don’t duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

Community stats

  • 5.2K

    Monthly active users

  • 3.7K

    Posts

  • 81K

    Comments