Post-Platform Digital Publishing Toolkit

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
guides:self-hosting_guide [2025/02/21 14:57] wgpguides:self-hosting_guide [2025/02/23 11:45] (current) wgp
Line 18: Line 18:
   * [[https://github.com/hintjen/selfhosted-gateway|Self-hosted Gateway]] - A self-hosted VPS solution   * [[https://github.com/hintjen/selfhosted-gateway|Self-hosted Gateway]] - A self-hosted VPS solution
   * [[https://www.wireguard.com/|WireGuard]] (or [[https://tailscale.com/|Tailscale]], a proprietary alternative based on WireGuard, or [[https://netbird.io/|Netbird]]) - A VPN like WireGuard does not solve the problem by itself, but more on that later.   * [[https://www.wireguard.com/|WireGuard]] (or [[https://tailscale.com/|Tailscale]], a proprietary alternative based on WireGuard, or [[https://netbird.io/|Netbird]]) - A VPN like WireGuard does not solve the problem by itself, but more on that later.
 +
 +{{:guides:self-hosting_flowchart.jpg?nolink|}}
  
 At Well Gedacht Publishing, we also had this issue with the ISP sharing an IP address with multiple households, and were able to get a dedicated IP—yet a dynamic one—after calling their customer service. Currently, our self-hosted websites and services run on our home server, without any VPS or another type of solution to the dynamic IP address problem. This means that once our ISP decides to change our IP address, for example if we restart our router, or the electricity goes out etc, our IP address changes too, and in that case, we would need to update the DNS records on our registrars ourselves; also meaning that our websites will be inaccessible, if we don't update the IP address on the DNS records, which is something we are OK with. Every once in a while, your websites might have some downtime, and if you are OK with this, you can even self-host with your dynamic IP address. There are also tools for monitoring the uptime of your sites, like [[https://github.com/louislam/uptime-kuma|this one]]. At Well Gedacht Publishing, we also had this issue with the ISP sharing an IP address with multiple households, and were able to get a dedicated IP—yet a dynamic one—after calling their customer service. Currently, our self-hosted websites and services run on our home server, without any VPS or another type of solution to the dynamic IP address problem. This means that once our ISP decides to change our IP address, for example if we restart our router, or the electricity goes out etc, our IP address changes too, and in that case, we would need to update the DNS records on our registrars ourselves; also meaning that our websites will be inaccessible, if we don't update the IP address on the DNS records, which is something we are OK with. Every once in a while, your websites might have some downtime, and if you are OK with this, you can even self-host with your dynamic IP address. There are also tools for monitoring the uptime of your sites, like [[https://github.com/louislam/uptime-kuma|this one]].
Line 56: Line 58:
 </code> </code>
   - //Optional step//: You can run Docker on the terminal, but if you prefer to have a GUI to manage your Docker containers, you can install [[https://www.portainer.io/|Portainer]]. For deploying the Portainer as a Docker container, you can: <code> sudo docker run -d -p 9000:9000 --restart always -v /var/run/docker.sock:/var/run/docker.sock portainer/portainer-ce:latest </code>   - //Optional step//: You can run Docker on the terminal, but if you prefer to have a GUI to manage your Docker containers, you can install [[https://www.portainer.io/|Portainer]]. For deploying the Portainer as a Docker container, you can: <code> sudo docker run -d -p 9000:9000 --restart always -v /var/run/docker.sock:/var/run/docker.sock portainer/portainer-ce:latest </code>
-  - Next step is to deploy the Nginx web server container. For that, we simply type: <code> sudo docker run -it --rm -d -p 8080:80 --name web -v ~/site-content:/usr/share/nginx/html nginx </code> This command tells this Nginx container to listen for upcoming traffic on the port 8080, and the content of your website, such as the index.html goes to the directory ~/site-content, and the name of the container is "web." You can check if Nginx is succesfully deployed and running by typing your-computer's-IP-address:8080 on your brower, and it will show you this page: {{ :guides:install_nginx_welcome.png?nolink&400 |}}+  - Create a directory where you will place the index.html file, named site-content: <code> mkdir ~/site-content </code> 
 +  - Next step is to deploy the Nginx web server container. For that, we simply type: <code> sudo docker run -it --restart always -d -p 8080:80 --name web -v ~/site-content:/usr/share/nginx/html nginx </code> This command tells this Nginx container to listen for upcoming traffic on the port 8080, and the content of your website, such as the index.html goes to the directory ~/site-content, and the name of the container is "web." You can check if Nginx is succesfully deployed and running by typing your-computer's-IP-address:8080 on your brower, and it will show you this page: {{ :guides:install_nginx_welcome.png?nolink&400 |}}
   - Now, we need to deploy the Nginx Proxy Manager container, which is a very nice reverse proxy manager. With it you can expose the ports 80 and 443 of your router to outside traffic, and then direct the incoming traffic to the web server you deployed in the previous step. It also helps you with getting SSL encryption certificates with Let's Encrypt and use https on your website very easily. First, create a new directory called npm: <code>mkdir -p npm   - Now, we need to deploy the Nginx Proxy Manager container, which is a very nice reverse proxy manager. With it you can expose the ports 80 and 443 of your router to outside traffic, and then direct the incoming traffic to the web server you deployed in the previous step. It also helps you with getting SSL encryption certificates with Let's Encrypt and use https on your website very easily. First, create a new directory called npm: <code>mkdir -p npm
 cd npm</code> Then, create a Docker compose file there: <code># Create a docker-compose configuration file cd npm</code> Then, create a Docker compose file there: <code># Create a docker-compose configuration file
guides/self-hosting_guide.1740149861.txt.gz · Last modified: 2025/02/21 14:57 by wgp