Core
The Core stack contains essential containers for server infrastructure: core-npm and core-portainer.
| Service | URL | Purpose | Project |
|---|---|---|---|
| NPM | proxy.fjellhei.men | Reverse proxy | nginxproxymanager.com |
| Portainer | containers.fjellhei.men | Container management UI | portainer.io |
Nginx Proxy Manager
"Nginx Proxy Manager is a tool that lets you expose your private web services on your network with free SSL, Docker, and multiple users."
Custom domain
To use NPM as a reverse proxy with SSL, you should obtain a custom domain. FreeDNS providers that offer free domains are also a viable option.
At the core of the home server is Nginx Proxy Manager (NPM), a reverse proxy that routes requests to the applications. Most applications are isolated within the docker network proxy-network but remain accessible through NPM. NPM exposes ports 80/443 (HTTP/S), handles all requests to *.fjellhei.men and directs them to the appropriate container.
For guidance on setting up and configuring the reverse proxy based on your existing network, refer to the documentation.
Portainer
"Portainer is a lightweight service delivery platform for containerized applications that can be used to manage Docker, Swarm, Kubernetes and ACI environments."
SSH access to the server is restricted to devices with authorized keys, making server management tricky without ssh. Portainer fills the gap, by offering a web-UI for Docker container administration accessible in the browser.
docker-compose.yaml
---
name: core
services:
proxy:
image: jc21/nginx-proxy-manager:latest
container_name: core-npm
ports:
- '80:80'
- '81:81'
- '443:443'
volumes:
- /fjellheimen/core/data/npm/data:/data
- /fjellheimen/core/data/npm/letsencrypt:/etc/letsencrypt
networks:
- proxy-network
env_file:
- /fjellheimen/.env
healthcheck:
test: ["CMD", "/bin/check-health"]
interval: 10s
timeout: 3s
restart: unless-stopped
portainer:
image: portainer/portainer-ce:sts
container_name: core-portainer
volumes:
- /fjellheimen/core/data/portainer/data:/data
- /var/run/docker.sock:/var/run/docker.sock
networks:
- proxy-network
env_file:
- /fjellheimen/.env
privileged: true
restart: unless-stopped
networks:
proxy-network:
name: proxy-network