Proudly serving the GTHA

Networking guide

Self-hosted architecture and pfSense best practices

An overview of a self-hosted environment built around a pfSense router: the servers, the software behind each function, and the router settings we apply.

The architecture

From the ak'tu' Consulting video series (revision 1.0, September 22, 2024).

The environment is built around a pfSense router. Behind it sit a DNS server, an email gateway, a reverse proxy, a web server, an email server, a Nextcloud server and a management server.

Software components

Each function, the software that provides it, and what it runs on:

E-mail server: Mailcow, on Docker E-mail gateway: Proxmox Mail Gateway (PMG), in an LXC container on Proxmox DNS: BIND9, on Docker Reverse proxy: Nginx Proxy Manager (NPM), on Docker Cloud storage: Nextcloud, on Docker Web server: nginx, on Docker Orchestration and standardization: Ansible Office suite: OnlyOffice, on Docker alongside Nextcloud Central database: MariaDB, on Docker Conferencing: Jitsi, on Docker

pfSense router settings

SSH: turn on SSH, which is needed to set up CrowdSec.

Security: install CrowdSec to block scans from the internet.

Backup: turn on automatic configuration backup so every pfSense change is saved.

HTTPS: enable HTTPS for the web interface.

Outbound NAT: enable Hybrid Outbound NAT, which makes future configurations easier.

DNS: add system DNS servers for the WAN. Examples: Cloudflare 1.1.1.1 and 1.0.0.1, or OpenDNS 208.67.222.222 and 208.67.220.220.

Want this built and looked after for you?

We design, secure and support self-hosted environments for businesses of all sizes, wherever you are. Book a free consultation and we will look at what you have today.

Guide revision 1.0 (September 2024), produced by ak'tu' Media Inc.

Take a copy with you

Prefer to keep this guide offline? Download the PDF version.

Free consultation

Need help putting this into practice?

We can review your setup and help you apply it safely.