This is an automated archive made by the Lemmit Bot.

The original was posted on /r/selfhosted by /u/vicks9880 on 2023-11-25 14:13:14.


I have been self hosting from quite a while and recently I had to restart my server. After restarting, for some reason portainer didn’t recognise any of my stacks and all my stacks becaome “limited” and I lost all my docker_compose for all services. So decided to create this ansible script which keep all my configuration in one place in case I have to reinstall my server.

The script automates all my setup which used to take hours of work and now I can have everything up and running in minutes in case of failure.

Highlights:

  • setup debian with samba, docker, portainer
  • install all services as portainer stack using portainer API
  • uses cloudflare ddns and nginx for reverse proxy to access all my services
  • wg-easy for wireguard vpn setup with nice GUI to manage peers

I am currently working on backing up configuration files for all my docker services to Mega (free plan) using MegaCMD Backup, which keeps a rotational backup of the files ( last 10 days in my case).

Would like to share with all and hope to get some improvements/ideas: