02 - Core Infrastructure

Proxmox VE

Proxmox VE

Purpose

Proxmox VE is the primary hypervisor for the Bytek homelab.

Proxmox hosts and manages:

Proxmox is a critical management system and must remain accessible independently of Pi-hole, Traefik, and Authentik.


Service Information

Setting Value
Private hostname pve.bytek.ca
Private IP address 192.168.2.254
Web interface port TCP 8006
SSH port TCP 22
Access scope Home LAN or trusted VPN
Normal authentication Authentik OIDC
Emergency authentication root@pam
General DNS resolver 9.9.9.9
Backup storage pve-backup
Primary VM storage local-lvm
Large-data storage user-data

Management interface:

Open Proxmox VE


Access Policy

The Proxmox management interface must remain private.

Approved access paths include:

The following access methods are prohibited:

Pi-hole resolves pve.bytek.ca directly to 192.168.2.254.


DNS Design

The Proxmox host intentionally uses Quad9 at 9.9.9.9 instead of Pi-hole.

This prevents the hypervisor from depending on a guest VM or LXC for its own DNS service.

The DNS behavior differs depending on the requester:

Requester Hostname Result
LAN workstation using Pi-hole pve.bytek.ca 192.168.2.254
Proxmox using Quad9 portal.bytek.ca 38.29.213.101
LAN workstation using Pi-hole portal.bytek.ca 192.168.2.182

Proxmox may therefore reach Authentik through the public VPS, WireGuard, and Traefik path.

If that path becomes unreliable for OIDC, a single static entry can map portal.bytek.ca to 192.168.2.182 in the Proxmox /etc/hosts file without changing the general DNS resolver.


Browser DNS Requirement

The private hostname pve.bytek.ca exists only in Pi-hole.

Firefox-based browsers such as Zen may bypass Pi-hole when enhanced DNS protection or DNS over HTTPS is forced.

If the private hostname does not load but the IP address works, verify browser DNS protection before changing Proxmox.

Useful Windows checks:

Expected results:


Authentication Model

Normal Authentication

Normal administration uses native OpenID Connect with Authentik.

OIDC Setting Value
Realm authentik
Issuer https://portal.bytek.ca/application/o/proxmox/
Username claim username
Scopes email profile
Automatically create users Enabled
Default realm Optional after validation

The matching Authentik provider requires:

Required Authentik bindings:

A user must satisfy both the group and policy requirements.


Authentik Scope Mappings

The Proxmox Authentik provider must include the following selected scope mappings:

Missing scope mappings can allow the browser authorization step to succeed while causing Proxmox to fail at the Authentik userinfo endpoint.

A previously observed failure was:

Selecting the expected mappings in the Authentik provider resolved the authentication flow.


Authentication and Authorization Are Separate

Successful Authentik authentication creates the Proxmox user but does not grant access to VMs, containers, nodes, or storage.

A newly created OIDC user may initially see an empty interface.

The user requires an explicit Proxmox access-control entry.

For the primary administrator:

Permission Setting Value
Path /
Role Administrator
Propagate Enabled
User Authentik-created Proxmox user

The username normally ends with the realm:

Do not accidentally grant the permission to the PAM version of the username.


Break-Glass Authentication

The local Proxmox PAM account must remain available.

Setting Value
Account root@pam
Authentication source Proxmox host PAM
Purpose Emergency recovery
Password storage Password manager
Removal permitted No

Never:

The root@pam account should be tested periodically in a private browser session.


Web Service Health

The Proxmox web interface is provided by pveproxy.

Check service state with:

systemctl is-active pveproxy

Expected result:

Check the listener with:

ss -lntp | grep ':8006'

Expected result:

Test locally with:

curl -k https://127.0.0.1:8006/

A 501 method HEAD not available response from a command using curl -I does not indicate an outage. That response confirms the HTTPS service was reached, but the endpoint does not support the HTTP HEAD method.


Network Validation

Test from another LAN VM:

nc -zv -w 5 192.168.2.254 8006

A successful result confirms TCP reachability.

Test HTTPS by IP:

curl -k https://192.168.2.254:8006/

Test HTTPS by private hostname:

curl -k https://pve.bytek.ca:8006/

If the hostname fails but the IP works, investigate DNS rather than pveproxy.


OIDC Validation

Verify that Proxmox can retrieve Authentik discovery information:

curl -fsS https://portal.bytek.ca/application/o/proxmox/.well-known/openid-configuration

The response should contain OIDC metadata such as:

A request to the userinfo endpoint without a bearer token should return an authentication error.

That response is expected and proves the endpoint is reachable.


OIDC Troubleshooting

Review recent Proxmox authentication logs with:

journalctl -u pvedaemon --since "10 minutes ago" --no-pager

Look for terms such as:

Authentication Failure 401

Possible causes include:

Failed to Contact Userinfo Endpoint

Check:

  1. Authentik readiness.
  2. OIDC discovery.
  3. The userinfo endpoint.
  4. Selected Authentik email and profile mappings.
  5. Proxmox realm scopes.
  6. VPS and WireGuard connectivity.
  7. Traefik routing.

Login Works but No VMs Appear

The OIDC user has not been assigned a Proxmox ACL.

Assign the required role at / with propagation enabled.

Private Hostname Does Not Resolve

Check:

  1. Pi-hole record.
  2. Workstation DNS server.
  3. Browser DNS over HTTPS.
  4. Active VPN.
  5. Browser proxy.
  6. Windows DNS cache.

Firewall Policy

Proxmox TCP port 8006 should accept traffic only from approved management sources.

Potential management sources include:

Do not create an internet-wide accept rule for TCP 8006.

SSH should use:


Storage Attached to Proxmox

Storage ID Type Primary Role
local Directory ISOs, templates, and selected local content
local-lvm LVM-thin VM and LXC operating-system disks
user-data LVM-thin Large application and user-data disks
pve-backup Directory on ext4 VZDump backup files

Review storage state using:

pvesm status

All required storage should show as active.


Backup System

Proxmox uses its built-in scheduled backup system.

Backups are written to:

The general job uses:

The backup mount uses mount-point validation to prevent writing backup data to the Proxmox root filesystem if the HDD is unavailable.


Snapshots

Snapshots are used only for short-term rollback.

Appropriate snapshot cases include:

Snapshots are not backups.

Delete snapshots after the associated change has been validated.

Long-lived snapshots consume thin-pool capacity and increase storage risk.


Planned GPU Passthrough

The RTX 2060 is planned for a dedicated Plex VM.

Before passthrough:

  1. Confirm VT-d and IOMMU.
  2. Identify GPU and audio PCI functions.
  3. Review the IOMMU group.
  4. Confirm the group contains no critical host devices.
  5. Create a Proxmox backup.
  6. Preserve console recovery.
  7. Use a Q35 and OVMF Plex VM.
  8. Attach all required RTX 2060 functions.
  9. Keep the GPU non-primary for the headless Plex VM.

A VM with passed-through hardware cannot use normal live migration.


Proxmox Recovery

If Authentik authentication fails:

  1. Open the Proxmox login page.
  2. Select the PAM realm.
  3. Sign in as root@pam.
  4. Verify Authentik readiness.
  5. Verify the Authentik Proxmox provider.
  6. Verify selected scope mappings.
  7. Verify the Proxmox realm.
  8. Review pvedaemon logs.
  9. Verify the OIDC user ACL.
  10. Retest from a private browser session.

If the web interface fails:

  1. Access the Proxmox console or SSH.
  2. Verify the Proxmox IP address.
  3. Verify pveproxy.
  4. Verify TCP port 8006.
  5. Review firewall rules.
  6. Verify storage.
  7. Restart pveproxy only if the service is unhealthy.

If the system disk fails:

  1. Preserve the user-data NVMe and backup HDD.
  2. Reinstall Proxmox on replacement system storage.
  3. Restore networking and storage definitions.
  4. Reconnect user-data.
  5. Remount pve-backup.
  6. Restore guests from backup.
  7. Recreate the Authentik realm.
  8. Verify root@pam.
  9. Test OIDC only after local management works.

Validation Checklist


Document Control

Public VPS Ingress

Purpose

The public VPS is the internet-facing entry point for applications hosted on the Bytek home network.

The VPS prevents individual home services from being exposed directly through the Bell router. Public HTTPS traffic reaches the VPS first, then travels through an encrypted WireGuard tunnel to the home network.

The VPS provides:


Service Information

Setting Value
Public IPv4 address 38.29.213.101
Primary purpose Public HTTPS ingress
Public application port TCP 443
Home-network transport WireGuard
Administration SSH key authentication
SSH port Confirm current hardened SSH port
Operating system Confirm current Linux distribution
Hosting provider Confirm current VPS provider
Public DNS provider WHC cPanel
Monitoring Uptime Kuma

Architecture Role

The VPS does not host the main Bytek applications.

The VPS forwards approved traffic to the home network.

The primary traffic path is:

  1. A client opens a public application hostname.
  2. WHC DNS resolves the hostname to 38.29.213.101.
  3. The client establishes HTTPS to the VPS on TCP port 443.
  4. The VPS forwards the permitted connection through WireGuard.
  5. The home WireGuard gateway receives the traffic.
  6. The gateway forwards the request to Traefik at 192.168.2.182.
  7. Traefik selects the correct application backend.

The VPS must not have direct access to all home-LAN services unless a specific rule requires it.


Public Hostnames

The following public DNS records point to the VPS:

Service Hostname Public Destination
Nextcloud cloud.bytek.ca 38.29.213.101
BookStack docs.bytek.ca 38.29.213.101
Authentik portal.bytek.ca 38.29.213.101
Vikunja projects.bytek.ca 38.29.213.101
Traefik dashboard proxy.bytek.ca 38.29.213.101
Uptime Kuma status.bytek.ca 38.29.213.101

The public hostname pve.bytek.ca must not point to the VPS.

Proxmox remains available only through the LAN or a trusted remote-access method.


Public HTTPS Flow

External HTTPS requests follow this sequence:

  1. WHC public DNS returns 38.29.213.101.
  2. The incoming connection reaches the VPS on TCP port 443.
  3. VPS firewall rules verify that the connection targets an approved public entry point.
  4. The VPS forwards the traffic through the WireGuard tunnel.
  5. The home WireGuard gateway forwards the connection to Traefik.
  6. Traefik terminates HTTPS or processes the forwarded connection according to the configured design.
  7. Traefik routes the request by hostname.

The VPS does not need separate public ports for every HTTPS application because Traefik distinguishes applications by hostname.


WireGuard Connection

The VPS maintains a WireGuard peer relationship with the home WireGuard gateway.

The tunnel is used for:

The existing VPS tunnel must remain separate from any future laptop or phone VPN.

Do not reuse:


WireGuard Health

Review the tunnel using:

sudo wg show

Verify:

A recent handshake confirms peer connectivity but does not prove that application forwarding works.

Test the complete application path separately.


VPS Firewall Policy

The VPS firewall should allow only required public and administrative traffic.

Required Public Access

Traffic That Must Remain Private

Do not expose the following home ports through the VPS:

Service Port
Proxmox VE TCP 8006
Pi-hole DNS administration Private management port
Nextcloud AIO management TCP 8080
Nextcloud AIO backend TCP 11000
Uptime Kuma backend TCP 3001
Authentik backend TCP 9000
Vikunja backend TCP 3456
BookStack backend TCP 6875
Docker API Any Docker API listener
Home service SSH TCP 22

New public ports must be documented before being added.


SSH Administration

VPS management uses SSH key authentication.

Confirm the current SSH listener using:

ss -lntp

Confirm SSH service health using:

systemctl is-active ssh

Expected result:

Do not place the private SSH key in BookStack.


Public DNS Management

Public DNS records are managed through WHC cPanel.

When adding a new public application:

  1. Create an A record for the new hostname.
  2. Point the record to 38.29.213.101.
  3. Use a short TTL during the initial deployment.
  4. Create the matching Pi-hole split-DNS record.
  5. Create the Traefik router and service.
  6. Confirm the application backend is reachable from Traefik.
  7. Confirm certificate issuance.
  8. Test internally.
  9. Test externally using cellular data or another external network.
  10. Add Uptime Kuma monitoring.
  11. Update BookStack documentation.

Do not point public DNS directly to:


Public Application Onboarding Checklist

Before exposing a new application through the VPS, confirm:


Service Validation

Confirm the VPS Public Address

Verify that public DNS resolves application hostnames to:

Confirm the WireGuard Tunnel

Use:

sudo wg show

Expected:

Confirm Public Port 443

Use:

ss -lntp

Confirm that the intended ingress service or forwarding mechanism is listening on TCP port 443.

Confirm Routing to the Home Network

Test the intended WireGuard peer or private tunnel address.

A successful tunnel ping confirms network reachability but not application-level routing.

Confirm an Application Through the VPS

From an external connection, open a public application such as:

Open Authentik

The request should reach Authentik without exposing the private backend port.


External Testing

External testing must use a network outside the home LAN.

Suitable test methods include:

Testing from the home LAN may use Pi-hole split DNS and therefore bypass the VPS.

To validate public ingress, confirm the client resolves the hostname to 38.29.213.101.


Monitoring

Monitor Target
VPS host Public VPS address
Public HTTPS TCP 443 on the VPS
WireGuard peer Home tunnel peer
Authentik external route portal.bytek.ca
Nextcloud external route cloud.bytek.ca
BookStack external route docs.bytek.ca
Vikunja external route projects.bytek.ca

Monitoring should distinguish:

A successful ping does not prove HTTPS or WireGuard forwarding is functioning.


Logging

Review logs for:

Useful sources may include:

Do not copy active tokens, private keys, or full authentication headers into BookStack.


Failure Impact

If the VPS is unavailable:

The VPS is therefore critical for external access but not for normal LAN access.


Common Failure Scenarios

Public DNS Resolves Incorrectly

Symptoms:

Check:

WireGuard Handshake Is Missing

Symptoms:

Check:

Tunnel Works but Application Fails

Symptoms:

Check:

Internal Access Works but External Access Fails

This usually indicates a problem with:

Internal split DNS bypasses those components.

External Access Works but Internal Access Fails

This usually indicates a problem with:


Recovery Procedure

If all public applications become unavailable:

  1. Confirm the VPS is running through the hosting-provider console.
  2. Confirm the public IP is still 38.29.213.101.
  3. Confirm SSH access.
  4. Confirm the WireGuard interface.
  5. Confirm the latest home-peer handshake.
  6. Confirm transfer counters.
  7. Confirm IP forwarding and firewall rules.
  8. Confirm TCP 443 is listening.
  9. Confirm the home WireGuard gateway is running.
  10. Confirm Traefik is running.
  11. Test one application directly from Traefik.
  12. Test the public hostname from an external network.
  13. Review logs before changing configuration.

If SSH is unavailable:

  1. Use the VPS provider console.
  2. Verify the SSH service.
  3. Verify the VPS firewall.
  4. Verify disk space.
  5. Verify the network interface.
  6. Restore SSH configuration from a known-good backup if required.

Backup and Recovery Data

Preserve the following VPS information:

Private keys must remain in a password manager or encrypted backup.

BookStack should record the location of secrets, not the secret values.


Security Review Checklist


Document Control

WireGuard Gateway

Purpose

The WireGuard gateway connects the public VPS to the Bytek home network through an encrypted tunnel.

The gateway allows public HTTPS traffic to reach Traefik without exposing individual home services directly through the Bell router.

The WireGuard gateway provides:


Service Information

Setting Value
Service name WireGuard Gateway
Private IP address 192.168.2.64
Primary role VPS-to-home tunnel gateway
Home LAN 192.168.2.0/24
Default gateway 192.168.2.1
Public peer VPS at 38.29.213.101
Administrative access SSH key authentication
Public exposure WireGuard port only
Backup coverage Proxmox scheduled backup
Guest type Confirm VM or LXC
Proxmox guest ID Confirm current VM or CT ID

Architecture Role

The WireGuard gateway sits between the public VPS and the home LAN.

When an external user opens a hosted application:

  1. Public DNS resolves the application hostname to the VPS.
  2. The client connects to the VPS.
  3. The VPS forwards the approved connection through WireGuard.
  4. The WireGuard gateway receives the encrypted traffic.
  5. The gateway applies forwarding and firewall rules.
  6. The gateway sends the request to Traefik at 192.168.2.182.
  7. Traefik routes the request to the correct internal application.

The WireGuard gateway does not host the applications.

The gateway only provides secure transport and controlled forwarding.


Primary Traffic Flow

The normal public application path includes:

Stage Component
Public DNS WHC cPanel
Public entry point VPS at 38.29.213.101
Encrypted transport WireGuard
Home tunnel endpoint WireGuard gateway at 192.168.2.64
HTTPS routing Traefik at 192.168.2.182
Application backend Private VM or LXC

Only required application traffic should pass through this path.


WireGuard Interface

The WireGuard interface contains:

The existing interface name, tunnel subnet, listening port, and peer address should be recorded after checking the active configuration.

Useful checks:

If the interface is not named wg0, replace wg0 with the actual interface name.

Do not copy the private key into BookStack.


Key Management

WireGuard authentication uses public and private key pairs.

Gateway Private Key

The gateway private key:

Gateway Public Key

The gateway public key may be stored in documentation.

The public key identifies the gateway to the VPS peer.

VPS Public Key

The gateway configuration contains the VPS public key.

The VPS private key remains only on the VPS.

Key Rotation

If a private key is exposed:

  1. Generate a new key pair on the affected peer.
  2. Update the opposite peer with the new public key.
  3. Restart or reload the affected WireGuard interface.
  4. Confirm a new handshake.
  5. Revoke the compromised key.
  6. Update the encrypted recovery record.
  7. Document the rotation date.

Allowed IPs

WireGuard Allowed IPs control routing and peer address validation.

The gateway and VPS must use narrow Allowed IP entries.

Allowed IPs should contain only:

Avoid using overly broad routes unless the architecture requires them.

Do not add the full home LAN to a peer merely for convenience without reviewing the security impact.


IP Forwarding

The gateway requires IPv4 forwarding.

Check the current value with:

sysctl net.ipv4.ip_forward

Expected result:

The persistent setting should be stored in a file under /etc/sysctl.d/.

If forwarding is disabled, the WireGuard handshake may succeed while application traffic still fails.


Network Address Translation

The gateway may use NAT when home-LAN devices do not have a route back to the WireGuard tunnel subnet.

NAT allows an internal destination to see the connection as originating from the WireGuard gateway’s LAN address.

Advantages:

Limitations:

NAT rules should be narrow and limited to required source networks, destinations, and ports.


Firewall Policy

The WireGuard gateway must permit only required tunnel traffic.

Required Traffic

Typical required traffic includes:

Restricted Traffic

The VPS should not automatically receive unrestricted access to:

Each additional route should have a documented purpose.


Traefik Forwarding

The primary application destination behind the WireGuard gateway is Traefik.

Destination Value
Traefik address 192.168.2.182
Public application port TCP 443
Purpose HTTPS routing to internal applications

The gateway should forward approved public HTTPS traffic to Traefik rather than directly to individual application VMs.

This keeps public routing centralized.


Proxmox Management Through the Tunnel

Proxmox management is not part of the normal public ingress path.

If emergency Proxmox access through the VPS is intentionally enabled, use a narrow route such as:

Do not expose Proxmox TCP 8006 directly on the VPS public interface.

The preferred long-term remote-management method is a dedicated road-warrior VPN for the administrator’s laptop or phone.


Separation From a Future Remote-User VPN

The current WireGuard connection is used for VPS ingress.

A future laptop or phone VPN must use:

Do not reuse the VPS key pair or peer configuration for remote-user devices.

The VPS tunnel and a road-warrior VPN serve different purposes.


Service Startup

The WireGuard gateway should start early after a host reboot.

Preferred dependency order:

  1. Proxmox VE.
  2. Pi-hole.
  3. WireGuard gateway.
  4. Authentik.
  5. Traefik.
  6. Public applications.

The WireGuard service should be enabled at boot.

Check the active service using:

systemctl status wg-quick@wg0 --no-pager

If the interface name differs, replace wg0 with the correct name.

Expected service state:


Health Validation

Confirm the Interface

Use:

sudo wg show

Confirm:

Confirm Tunnel Addressing

Use:

ip -br addr

The WireGuard interface should show the expected tunnel address.

Confirm Routes

Use:

ip route

The required tunnel and LAN routes should be present.

Confirm Forwarding

Use:

sysctl net.ipv4.ip_forward

Expected:

Confirm Firewall

If UFW is used:

sudo ufw status numbered

If iptables NAT is used:

sudo iptables -t nat -L -n -v --line-numbers

If nftables is used:

sudo nft list ruleset

Review only the firewall system actually used by the gateway.


End-to-End Validation

A successful WireGuard handshake does not prove application forwarding works.

Validate the complete path.

From the VPS

Test the home WireGuard peer or tunnel gateway address.

Then test Traefik through the tunnel on the intended destination and port.

From an External Client

Use:

Open a public application such as:

Open Authentik

The application should load through:

From the Home LAN

The same hostname should resolve through Pi-hole and bypass the VPS.

This verifies that public and private paths both work.


Monitoring

Monitor Target
Gateway VM or LXC Ping 192.168.2.64
WireGuard tunnel peer Tunnel address or supported monitor
Public VPS 38.29.213.101
Traefik through tunnel Approved tunnel path
Public Authentik portal.bytek.ca
Public Nextcloud cloud.bytek.ca

Monitoring should distinguish between:


Common Failure Scenarios

Handshake Is Missing

Possible causes:

Handshake Exists but Applications Fail

Possible causes:

Internal Applications Work but Public Applications Fail

This usually indicates a problem with:

One Public Application Fails

If other public applications work, the tunnel is probably healthy.

Check:

Tunnel Stops After a Power Failure

Check startup order:

  1. Confirm the gateway booted.
  2. Confirm WireGuard started.
  3. Confirm the network interface has its LAN address.
  4. Confirm the VPS peer.
  5. Confirm forwarding.
  6. Confirm firewall rules loaded.
  7. Confirm a new handshake.
  8. Confirm Traefik is available.

Troubleshooting Order

When public ingress fails:

  1. Confirm the VPS is running.
  2. Confirm the WireGuard gateway is running.
  3. Confirm the gateway LAN IP is 192.168.2.64.
  4. Confirm the WireGuard interface exists.
  5. Confirm the latest handshake.
  6. Confirm transfer counters.
  7. Confirm IPv4 forwarding.
  8. Confirm forwarding firewall rules.
  9. Confirm NAT rules.
  10. Confirm Traefik at 192.168.2.182.
  11. Test a Traefik backend directly.
  12. Test the public hostname externally.
  13. Review logs before changing keys.

Do not regenerate WireGuard keys as an early troubleshooting step.


Logging

Useful log sources include:

Review the WireGuard unit using:

journalctl -u wg-quick@wg0 --since "30 minutes ago" --no-pager

Replace the interface name if necessary.

Look for:


Configuration Backup

Protect the following gateway data:

The VM or LXC is included in the Proxmox backup system.

The WireGuard private key should also exist in an encrypted recovery location.

Do not put the private key directly into BookStack.


Recovery Procedure

If the gateway VM or LXC is corrupted:

  1. Use Proxmox to identify the most recent good backup.
  2. Restore under a temporary guest ID if testing is required.
  3. Keep the restored guest disconnected from the LAN during initial inspection.
  4. Verify the WireGuard configuration and private key.
  5. Verify the LAN address.
  6. Verify forwarding and firewall rules.
  7. Shut down the failed production guest.
  8. Assign the expected production identity and network configuration.
  9. Start the replacement.
  10. Confirm a WireGuard handshake.
  11. Confirm Traefik reachability.
  12. Test an application externally.

If the key is unavailable:

  1. Generate a new gateway key pair.
  2. Update the VPS peer with the new gateway public key.
  3. Preserve the VPS key.
  4. Restart the WireGuard interfaces.
  5. Confirm the new handshake.
  6. Store the new private key securely.

Security Checklist


Validation Checklist


Document Control

Pi-hole

Purpose

Pi-hole provides DNS services for the Bytek home network.

Pi-hole is responsible for:

Pi-hole is foundational infrastructure. Pi-hole must remain accessible independently of Traefik and Authentik so DNS can be repaired during an application or identity outage.


Service Information

Setting Value
Service name Pi-hole
Private IP address 192.168.2.65
LAN subnet 192.168.2.0/24
DNS ports TCP and UDP 53
Primary role LAN DNS and split DNS
Secondary role DHCP reservations
Management scope Home LAN or trusted VPN
Authentication Local Pi-hole credentials
Proxmox guest type LXC
Proxmox guest ID Confirm current CT ID
Backup coverage Proxmox scheduled backup

Architecture Role

Pi-hole provides DNS to home-LAN clients and selected infrastructure containers.

When a LAN device opens a Bytek application:

  1. The device asks Pi-hole to resolve the application hostname.
  2. Pi-hole returns Traefik’s private address, 192.168.2.182.
  3. The client connects directly to Traefik.
  4. Traefik routes the request to the correct private application backend.

This allows the same hostname and HTTPS certificate to be used internally and externally.

Pi-hole is not part of the public application path for external users.

External users resolve Bytek applications through WHC public DNS instead.


DNS Responsibilities

Pi-hole provides two types of DNS resolution.

Public Internet Resolution

Pi-hole forwards normal public DNS queries to its configured upstream resolvers.

Examples include:

Local Bytek Resolution

Pi-hole answers selected Bytek application hostnames using private addresses.

These local records create the split-DNS design.


Split-DNS Records

Hostname Internal Destination Purpose
cloud.bytek.ca 192.168.2.182 Nextcloud through Traefik
docs.bytek.ca 192.168.2.182 BookStack through Traefik
portal.bytek.ca 192.168.2.182 Authentik through Traefik
projects.bytek.ca 192.168.2.182 Vikunja through Traefik
proxy.bytek.ca 192.168.2.182 Traefik dashboard
status.bytek.ca 192.168.2.182 Uptime Kuma through Traefik
pve.bytek.ca 192.168.2.254 Direct Proxmox management

Application hostnames point internally to Traefik.

Proxmox is the exception because Proxmox does not sit behind Traefik.


Public and Private DNS Comparison

Hostname Public WHC Result Internal Pi-hole Result
cloud.bytek.ca 38.29.213.101 192.168.2.182
docs.bytek.ca 38.29.213.101 192.168.2.182
portal.bytek.ca 38.29.213.101 192.168.2.182
projects.bytek.ca 38.29.213.101 192.168.2.182
proxy.bytek.ca 38.29.213.101 192.168.2.182
status.bytek.ca 38.29.213.101 192.168.2.182
pve.bytek.ca No public record 192.168.2.254

The split-DNS model provides:


Proxmox DNS Exception

The Proxmox host intentionally does not use Pi-hole as its general DNS resolver.

Proxmox uses:

This prevents the hypervisor from depending on a guest LXC for DNS.

As a result:

Do not change the Proxmox resolver to Pi-hole without reviewing the dependency impact.

If Proxmox eventually needs a direct local route to Authentik, use a specific /etc/hosts entry for portal.bytek.ca instead of replacing the general resolver.


DHCP Reservations

Infrastructure guests should receive stable addresses through DHCP reservations.

Reservations are based on the virtual NIC MAC address assigned by Proxmox.

Known Reservations

Service Reserved Address
Nextcloud AIO 192.168.2.100
Uptime Kuma 192.168.2.115
Vikunja 192.168.2.121
Authentik 192.168.2.162
Traefik 192.168.2.182
BookStack Confirm current address
Plex Confirm after deployment
Future game server Confirm after deployment

The WireGuard gateway uses 192.168.2.64.

Confirm whether the WireGuard address is configured through a reservation or static guest networking before editing it.


Why Stable Addresses Matter

Infrastructure addresses are referenced by:

An unexpected address change can break several services simultaneously.

Always reserve a service address before treating the address as permanent.


Finding a Guest MAC Address

For a Proxmox VM, inspect the net0 entry using:

qm config <VMID>

For an LXC, inspect the network entry using:

pct config <CTID>

Record the MAC address in Pi-hole when creating the reservation.

Do not manually duplicate a MAC address between guests.


DNS Clients

Pi-hole may provide DNS to:

Not every infrastructure host must use Pi-hole.

Proxmox intentionally uses Quad9.

Other critical systems may also use an independent resolver if avoiding a dependency on Pi-hole is more important than split-DNS access.


Docker DNS

Some application containers require explicit Pi-hole DNS.

This is particularly important for containers that must resolve private Bytek hostnames.

Traefik

The Traefik container explicitly uses:

This was added after Docker’s embedded resolver failed to resolve the Let’s Encrypt ACME endpoint following a power interruption.

Uptime Kuma

The Uptime Kuma container explicitly uses:

This allows Kuma to monitor private Bytek application hostnames.

BookStack

BookStack may use Pi-hole explicitly so the container can resolve Authentik at portal.bytek.ca.

Nextcloud

Nextcloud containers must be able to resolve portal.bytek.ca for Authentik OIDC.

If the host resolves a name but the container does not, inspect the container’s Docker DNS configuration.


Docker DNS Validation

Confirm a container’s configured DNS servers using:

sudo docker inspect --format='DNS={{json .HostConfig.Dns}}' <container-name>

Test hostname resolution from inside a container using:

sudo docker exec <container-name> getent hosts portal.bytek.ca

Expected internal result:

If the command returns no output, container DNS is failing.

Do not change OIDC client IDs or secrets before DNS is proven healthy.


Browser DNS Over HTTPS

Firefox-based browsers, including Zen, can bypass Pi-hole through DNS over HTTPS.

This previously prevented access to:

Pi-hole correctly resolved the private hostname, but Zen attempted to use protected public DNS instead.

If a private hostname works by IP but not by name:

  1. Check the hostname from the operating system.
  2. Query Pi-hole directly.
  3. Disable forced browser DNS over HTTPS.
  4. Clear the operating-system DNS cache.
  5. Clear the browser DNS cache.
  6. Close idle browser sockets.
  7. Restart the browser.

Useful Windows commands include:


DNS Validation

Test an Internal Application Record

Use:

nslookup portal.bytek.ca 192.168.2.65

Expected result:

Test Proxmox Resolution

Use:

nslookup pve.bytek.ca 192.168.2.65

Expected result:

Test Public Resolution

Use:

nslookup google.com 192.168.2.65

Expected result:

Test DNS Over TCP

Use:

nc -zv -w 3 192.168.2.65 53

Test DNS Over UDP

Use:

nc -zvu -w 3 192.168.2.65 53

Both TCP and UDP DNS should be available to approved LAN clients.


Service Health

Confirm that the Pi-hole LXC is running from Proxmox.

Confirm the guest address using:

ip -br -4 addr

Confirm DNS listeners using:

ss -lntup | grep ':53'

Confirm the Pi-hole DNS service using the appropriate service command for the installed Pi-hole version.

Review recent service logs if DNS queries fail.


Management Access

Pi-hole management should remain private.

Approved access paths include:

Do not route Pi-hole administration through:


Why Pi-hole Is Not Behind Authentik

Pi-hole is part of the dependency chain for internal Authentik and application resolution.

If Pi-hole management depended on Authentik, the following circular failure could occur:

  1. Pi-hole DNS fails.
  2. Authentik’s hostname stops resolving internally.
  3. Authentik login fails.
  4. Pi-hole administration is protected by Authentik.
  5. The administrator cannot reach Pi-hole to repair DNS.

Pi-hole therefore uses local credentials and private network access.


Upstream DNS

Pi-hole forwards non-local queries to configured upstream resolvers.

The chosen upstream resolver configuration should be documented after verification.

When changing upstream DNS:

  1. Record the current configuration.
  2. Change only one resolver setting at a time.
  3. Test public DNS.
  4. Test internal local records.
  5. Test DNSSEC if enabled.
  6. Test IPv4 and IPv6 behavior separately.
  7. Confirm application containers still resolve external services.

Do not assume that an upstream failure means Pi-hole itself is unavailable.


IPv6 Considerations

The Bytek homelab mainly uses IPv4 addressing.

If IPv6 is not intentionally configured end to end:

An incorrect public AAAA record can cause clients to attempt an unavailable path before falling back to IPv4.


Firewall Policy

Pi-hole must accept DNS from approved clients.

Typical requirements include:

Avoid exposing DNS publicly.

A publicly accessible recursive DNS resolver can be abused.

The Bell router must not forward public TCP or UDP port 53 to Pi-hole.


Monitoring

Monitor Target
Pi-hole guest Ping 192.168.2.65
Pi-hole DNS UDP 192.168.2.65:53
Pi-hole DNS TCP 192.168.2.65:53
Internal Authentik record portal.bytek.ca
Internal Proxmox record pve.bytek.ca
Public DNS resolution Selected external hostname

Monitoring should distinguish between:


Common Failure Scenarios

Pi-hole Guest Is Down

Symptoms:

Check:

Public DNS Fails but Local Records Work

Possible causes:

Local Records Fail but Public DNS Works

Possible causes:

VM Host Resolves but Container Does Not

Possible causes:

Recovery may require recreating the container after Pi-hole is working.

One Host Uses the Wrong Address

Possible causes:


Power-Failure Recovery

After an electrical outage, Pi-hole should start before applications that depend on split DNS.

  1. Confirm Proxmox is running.
  2. Confirm the Pi-hole LXC started.
  3. Confirm Pi-hole owns 192.168.2.65.
  4. Confirm TCP and UDP port 53.
  5. Confirm one local record.
  6. Confirm one public hostname.
  7. Start or validate Traefik.
  8. Validate Authentik.
  9. Restart affected containers whose DNS remained broken.
  10. Confirm Uptime Kuma monitors recover.

Application containers may need to be recreated or restarted if Docker cached a broken DNS path during startup.


Backup

The Pi-hole LXC is included in the Proxmox scheduled backup job.

The backup should preserve:

A Pi-hole configuration export may be maintained in addition to the Proxmox backup.

The export should be stored securely because it may contain internal network details.


Recovery Procedure

If Pi-hole is unavailable:

  1. Open Proxmox using 192.168.2.254 if private DNS is unavailable.
  2. Confirm the Pi-hole LXC is running.
  3. Open the LXC console.
  4. Confirm the interface owns 192.168.2.65.
  5. Confirm the default route.
  6. Confirm TCP and UDP port 53.
  7. Confirm the Pi-hole DNS service.
  8. Test a local record from inside the LXC.
  9. Test a public record.
  10. Review logs.
  11. Restore from a Proxmox backup if the configuration is damaged.

If Pi-hole is restored under a temporary CT ID:


Address-Change Procedure

Changing Pi-hole’s address would affect most of the environment.

Before changing 192.168.2.65:

  1. Document the current state.
  2. Update the Bell router or DHCP DNS settings.
  3. Update Docker Compose files with explicit DNS.
  4. Update Uptime Kuma.
  5. Update future VPN client DNS.
  6. Update firewall rules.
  7. Update service documentation.
  8. Flush client DNS caches.
  9. Recreate containers that use explicit Docker DNS.
  10. Test all split-DNS applications.

Avoid changing Pi-hole’s address unless required.


Security Checklist


Validation Checklist


Document Control

Traefik

Purpose

Traefik is the central HTTPS reverse proxy for the Bytek homelab.

Traefik receives HTTPS requests, selects the correct application according to the requested hostname, and forwards the request to the appropriate private backend.

Traefik provides:


Service Information

Setting Value
Service name Traefik
Private IP address 192.168.2.182
HTTPS entry point TCP 443
Public dashboard hostname proxy.bytek.ca
Deployment directory /opt/traefik
Container DNS 192.168.2.65
Certificate authority Let’s Encrypt
ACME challenge type DNS-01
DNS automation WHC cPanel API
Normal dashboard authentication Authentik ForwardAuth
Secondary dashboard authentication Basic Auth while retained
Backup coverage Proxmox scheduled backup
Proxmox VM ID Confirm current VM ID

Dashboard:

Open the Traefik Dashboard


Architecture Role

Traefik is the common application-routing layer for both external and internal clients.

External Request Path

  1. WHC public DNS resolves the application hostname to the VPS at 38.29.213.101.
  2. The VPS receives HTTPS traffic.
  3. The VPS forwards the traffic through WireGuard.
  4. The home WireGuard gateway sends the request to Traefik at 192.168.2.182.
  5. Traefik examines the requested hostname.
  6. Traefik forwards the request to the matching private backend.

Internal Request Path

  1. A LAN client queries Pi-hole.
  2. Pi-hole resolves the application hostname to 192.168.2.182.
  3. The client connects directly to Traefik.
  4. Traefik forwards the request to the matching private backend.

The same application hostname is used internally and externally.


Application Routing Reference

Hostname Backend Destination Authentication
portal.bytek.ca 192.168.2.162:9000 Authentik native authentication
cloud.bytek.ca 192.168.2.100:11000 Nextcloud native OIDC
projects.bytek.ca 192.168.2.121:3456 Vikunja native OIDC
docs.bytek.ca BookStack private IP on TCP 6875 BookStack native OIDC
status.bytek.ca Uptime Kuma or Authentik embedded outpost Authentik Proxy Provider
proxy.bytek.ca Traefik internal dashboard service Authentik ForwardAuth

The BookStack private address must be confirmed and added to this page.


Configuration Locations

Purpose Location
Docker Compose file /opt/traefik/compose.yml
Static Traefik configuration /opt/traefik/traefik.yml
Environment variables /opt/traefik/.env
Dynamic configuration /opt/traefik/dynamic/
Certificate state /opt/traefik/data/acme.json
Traefik log /opt/traefik/logs/traefik.log
Access log Confirm current path
Additional persistent data /opt/traefik/data/

The exact certificate and log paths should be confirmed against the current Compose file before relying on them during recovery.


Dynamic Configuration

Each application normally has its own dynamic configuration file.

Known files include:

File Purpose
authentik.yml Authentik router and service
authentik-forwardauth.yml Shared Authentik middleware and outpost service
bookstack.yml BookStack router and service
dashboard.yml Traefik dashboard router
nextcloud.yml Nextcloud router and service
uptime-kuma.yml Uptime Kuma router and service
vikunja.yml Vikunja router and service

Separating services into individual files makes configuration changes easier to review and reverse.

Before editing a working file:

  1. Create a dated or descriptive backup copy.
  2. Change only the required section.
  3. Validate the YAML indentation.
  4. Check the Traefik log.
  5. Test the route locally.
  6. Test the route from the LAN.
  7. Test the route externally if the service is public.
  8. Remove obsolete backup files after the change is documented.

Static Configuration

The static Traefik configuration defines platform-level settings such as:

Static configuration changes normally require a Traefik container restart or recreation.

Dynamic routing changes are usually detected automatically by the file provider when file watching is enabled.


Docker DNS

The Traefik container explicitly uses Pi-hole at 192.168.2.65.

This configuration was added after Docker’s embedded resolver failed to resolve the Let’s Encrypt ACME API following a power interruption.

The observed error reported that the Docker resolver at 127.0.0.11 was misbehaving.

Explicit Pi-hole DNS allows Traefik to resolve:

Verify the configured Docker DNS using:

sudo docker inspect --format='DNS={{json .HostConfig.Dns}}' traefik

Expected result:

The container’s internal resolver file may still show Docker’s embedded resolver at 127.0.0.11.

That is normal when Docker forwards requests to the explicitly configured upstream DNS server.


Container Management

Move to the deployment directory before running Compose commands:

cd /opt/traefik

Check the stack:

sudo docker compose ps

View recent logs:

sudo docker compose logs --tail 100 traefik

Follow logs live:

sudo docker compose logs -f traefik

Validate the Compose file:

sudo docker compose config --quiet

Apply normal Compose changes:

sudo docker compose up -d

Recreate Traefik after changing container-level settings such as DNS:

sudo docker compose up -d --force-recreate traefik

Restart Traefik after a static configuration change:

sudo docker compose restart traefik

A normal restart does not apply changes to Docker-level settings such as container DNS, network mode, volume mounts, or environment variables. Those changes require container recreation.


Naming and Routing Standard

Every Traefik application should have:

A route should not contain Authentik ForwardAuth if the application already uses native OIDC and requires direct API or client access.


Applications That Must Not Use ForwardAuth

Do not attach Authentik ForwardAuth to:

Nextcloud

Nextcloud mobile clients, desktop clients, WebDAV, CalDAV, CardDAV, and application authentication must reach Nextcloud directly.

Nextcloud uses native OIDC.

Vikunja

Vikunja uses native Authentik OIDC.

BookStack

BookStack uses native Authentik OIDC.

Authentik

Authentik must never depend on its own ForwardAuth middleware.

Proxmox VE

Proxmox uses native OIDC and remains outside Traefik.

Plex

Plex clients use Plex authentication and Plex-specific APIs.


Applications That Use Authentik Proxy Integration

Traefik Dashboard

The Traefik dashboard uses single-application ForwardAuth.

The dashboard request is validated by the Authentik embedded outpost before access is granted.

Uptime Kuma

Uptime Kuma uses an Authentik Proxy Provider because Uptime Kuma does not provide the same native OIDC integration as the other applications.

Selected status-page and monitoring endpoints may bypass authentication when public access is intentionally required.


Traefik Dashboard Authentication

The dashboard is available at:

Open the Traefik Dashboard

Access is restricted by:

During the initial ForwardAuth validation, Traefik Basic Auth remains enabled as a second authentication layer.

The expected initial flow is:

  1. The administrator opens proxy.bytek.ca.
  2. Traefik invokes Authentik ForwardAuth.
  3. Authentik validates the user and MFA.
  4. Authentik checks the application bindings.
  5. Traefik receives the authenticated request.
  6. Traefik presents the existing Basic Auth challenge.
  7. The administrator enters the Traefik Basic Auth credentials.
  8. The dashboard opens.

Basic Auth may be removed only after ForwardAuth and recovery procedures are fully tested.


Authentik ForwardAuth Middleware

The ForwardAuth middleware sends authentication requests to the Authentik embedded outpost.

The outpost backend is hosted by Authentik at 192.168.2.162 on TCP port 9000.

The middleware should trust the forwarded request headers and return Authentik identity headers to the protected application.

Typical identity headers include:

Do not log full authentication headers in a location accessible to untrusted users.


Authentik Outpost Callback Route

The path under /outpost.goauthentik.io/ must remain reachable without the ForwardAuth middleware.

If the callback path is protected by the same middleware, an authentication loop can occur.

The callback router should:

Test the outpost with:

curl -k -I https://proxy.bytek.ca/outpost.goauthentik.io/ping

Expected result:

A normal browser link is not useful for this endpoint because an HTTP 204 response intentionally contains no page content.


Certificate Management

Traefik obtains HTTPS certificates from Let’s Encrypt.

The current design uses:

Each public router should reference the correct certificate resolver.

A router without the certificate resolver may use the Traefik default certificate instead of requesting the intended hostname certificate.


ACME DNS-01 Flow

Certificate issuance follows this sequence:

  1. A Traefik router requests a certificate.
  2. Traefik contacts the Let’s Encrypt ACME API.
  3. Traefik creates the required DNS challenge through the WHC API.
  4. Let’s Encrypt validates the challenge.
  5. Traefik receives the certificate.
  6. Traefik stores the certificate state in acme.json.
  7. Traefik serves the certificate for the matching hostname.

Traefik must have working DNS before this process can succeed.


Certificate Storage

Certificate state is stored in:

/opt/traefik/data/acme.json

The file must:

Deleting acme.json can remove all stored certificates and account state.

That may trigger unnecessary reissuance and certificate-rate-limit risk.


Certificate Validation

Inspect a certificate served by Traefik using:

openssl s_client -connect 127.0.0.1:443 -servername projects.bytek.ca </dev/null 2>/dev/null | openssl x509 -noout -subject -issuer -dates -ext subjectAltName

Verify:

Repeat with the relevant hostname when validating another service.


Certificate Troubleshooting

Certificate Missing From the Dashboard

Check:

  1. The dynamic router exists.
  2. The hostname rule is correct.
  3. TLS is enabled.
  4. The certificate resolver is named correctly.
  5. Traefik DNS works.
  6. The WHC API credentials work.
  7. The ACME log contains the hostname.
  8. The DNS challenge was validated.

ACME DNS Failure

A previously observed error reported:

The correction was to configure the Traefik container to use Pi-hole explicitly and recreate the container.

Wrong Certificate Served

Possible causes include:


Application Onboarding

When adding a new public application:

  1. Confirm the application backend works directly.
  2. Reserve the VM or LXC IP in Pi-hole.
  3. Add the public WHC A record pointing to 38.29.213.101.
  4. Add the Pi-hole local DNS record pointing to 192.168.2.182.
  5. Create a dynamic Traefik configuration file.
  6. Add the hostname router.
  7. Add the private backend service.
  8. Enable TLS with the correct resolver.
  9. Validate YAML formatting.
  10. Confirm Traefik loaded the router.
  11. Confirm certificate issuance.
  12. Test from the Traefik VM.
  13. Test from the home LAN.
  14. Test from an external network.
  15. Add Uptime Kuma monitors.
  16. Update BookStack documentation.

Backend Validation

Before troubleshooting an application through Traefik, test the direct backend from the Traefik VM.

Examples:

Nextcloud

nc -zv -w 5 192.168.2.100 11000

Vikunja

curl -i http://192.168.2.121:3456/health

Authentik

curl -I http://192.168.2.162:9000/-/health/ready/

BookStack

Use the confirmed BookStack IP on TCP port 6875.

A direct backend failure must be resolved before changing the Traefik router.


Local Router Validation

Traefik can be tested locally without relying on public DNS.

Example for Vikunja:

curl -k --resolve projects.bytek.ca:443:127.0.0.1 https://projects.bytek.ca/health

This forces the requested hostname to the local Traefik listener.

A successful response confirms:


Logging

Review the main Traefik log using:

sudo tail -n 100 /opt/traefik/logs/traefik.log

Filter common issues using:

sudo grep -iE 'error|acme|certificate|middleware|service|router|dns' /opt/traefik/logs/traefik.log | tail -n 100

Look for:

If access logging is enabled, use it to distinguish:

Do not copy session cookies, bearer tokens, or authorization headers into BookStack.


YAML Validation

YAML indentation must use spaces, not tabs.

Check dynamic configuration files using:

sudo grep -RnP '\t' /opt/traefik/dynamic/

Expected result:

Review a specific file using:

sudo cat /opt/traefik/dynamic/<filename>.yml

Common YAML problems include:


IP Address Changes

If an application IP changes:

  1. Confirm the new reservation in Pi-hole.
  2. Confirm the VM owns the new address.
  3. Update the Traefik backend.
  4. Search /opt/traefik for the old address.
  5. Update Proxmox firewall rules.
  6. Update Authentik internal hosts if applicable.
  7. Update Uptime Kuma monitors.
  8. Test the direct backend.
  9. Test the local Traefik route.
  10. Test the public route.
  11. Update BookStack documentation.

A stale backend address causes gateway errors even when the application itself is healthy.


Firewall Requirements

The Traefik VM must accept:

Application VM firewalls must permit Traefik to reach their backend ports.

Known requirements include:

Destination Source Port
Nextcloud 192.168.2.182 TCP 11000
Vikunja 192.168.2.182 TCP 3456
Authentik 192.168.2.182 TCP 9000
BookStack 192.168.2.182 TCP 6875
Uptime Kuma direct route, if retained 192.168.2.182 TCP 3001

Do not allow public clients to connect directly to these backend ports.


Monitoring

Monitor Target
Traefik VM Ping 192.168.2.182
Traefik HTTPS TCP 443
Authentik route portal.bytek.ca readiness endpoint
Nextcloud route Nextcloud status endpoint
Vikunja route Vikunja health endpoint
BookStack route BookStack login endpoint
Certificate expiry Each important public hostname
Public VPS to Traefik path External application monitor

Monitoring should distinguish between:


Power-Failure Recovery

After a power interruption:

  1. Confirm Pi-hole is running.
  2. Confirm the WireGuard gateway is running.
  3. Confirm Authentik is ready.
  4. Confirm the Traefik VM owns 192.168.2.182.
  5. Confirm Docker is active.
  6. Confirm the Traefik container is running.
  7. Confirm the container uses Pi-hole DNS.
  8. Review Traefik logs for DNS errors.
  9. Confirm routers loaded.
  10. Confirm certificates are present.
  11. Test Authentik locally.
  12. Test an application locally.
  13. Test a public application externally.
  14. Restart or recreate Traefik only if required.

If Traefik started before Pi-hole and DNS remains broken, recreate the Traefik container after Pi-hole is healthy.


Backup

The Traefik VM is included in the Proxmox scheduled backup job.

Protect the following paths:

Secrets must remain in a password manager or encrypted backup.

BookStack should document the secret location, not the secret itself.


Recovery Procedure

If Traefik configuration is broken:

  1. SSH into the Traefik VM.
  2. Confirm Docker is active.
  3. Confirm the Traefik container state.
  4. Review the most recent log entries.
  5. Identify the most recently changed dynamic file.
  6. Restore the known-good backup copy.
  7. Confirm the file provider reloads the configuration.
  8. Test the affected router locally.
  9. Restart Traefik only if the static configuration changed or reload failed.
  10. Confirm certificates remain present.
  11. Test from the LAN.
  12. Test externally.

If the VM must be restored:

  1. Restore the most recent Proxmox backup under a temporary VM ID.
  2. Disconnect the restored VM network adapter.
  3. Verify /opt/traefik.
  4. Verify acme.json.
  5. Verify environment and dynamic configuration.
  6. Shut down the failed production VM.
  7. Assign the expected network identity.
  8. Start the restored VM.
  9. Confirm 192.168.2.182.
  10. Confirm Docker and Traefik.
  11. Test all routers.
  12. Reconnect public traffic only after validation.

Security Checklist


Validation Checklist


Document Control

Authentik

Purpose

Authentik provides centralized identity and access management for the Bytek homelab.

Authentik allows users to access multiple applications with one account while applying consistent authentication, multi-factor authentication, group membership, and access policies.

Authentik provides:


Service Information

Setting Value
Service name Authentik
Private IP address 192.168.2.162
Backend port TCP 9000
Public hostname portal.bytek.ca
Public access Traefik
Deployment directory /opt/authentik
Database PostgreSQL
Supporting service Redis
Proxy component Embedded outpost
Normal user group bytek-users
Administrator group bytek-admin
Backup coverage Proxmox scheduled backup
Proxmox VM ID Confirm current VM ID

Authentik portal:

Open Authentik


Architecture Role

Authentik is the trusted identity provider for the Bytek environment.

Applications rely on Authentik to answer these questions:

Authentik does not normally replace application-specific permissions.

For example:


Request Flow

A normal OIDC login follows this process:

  1. The user opens an application.
  2. The application redirects the browser to portal.bytek.ca.
  3. Traefik forwards the request to Authentik at 192.168.2.162:9000.
  4. Authentik identifies the requested application.
  5. Authentik requests credentials if no valid session exists.
  6. Authentik requests MFA according to the authentication flow.
  7. Authentik evaluates the application’s group and policy bindings.
  8. Authentik issues a signed authorization response.
  9. Authentik redirects the browser to the application callback.
  10. The application validates the response and creates or matches the local account.
  11. The application applies its own permissions.

Core Components

Authentik Server

The Authentik server provides:

Authentik Worker

The worker performs background tasks such as:

PostgreSQL

PostgreSQL stores Authentik configuration and identity data.

PostgreSQL contains critical information including:

PostgreSQL is the most important Authentik data component to protect.

Redis

Redis supports Authentik’s runtime and task-processing requirements.

Redis is required for normal stack operation but PostgreSQL remains the authoritative persistent data source.

Embedded Outpost

The embedded outpost provides:


Application Portal

The Authentik user portal displays applications available to the signed-in user.

The portal should show only applications that the user is allowed to access.

Normal users may see:

Administrators may additionally see:

Application visibility is controlled by:


Group Model

bytek-users

The bytek-users group grants access to normal user-facing applications.

Applications using this group include:

Users should be added to bytek-users only when access to normal Bytek applications is required.

bytek-admin

The bytek-admin group grants access to administrative applications.

Applications using this group include:

Membership in bytek-admin must be limited to trusted infrastructure administrators.

Administrator Membership

An administrator may belong to both groups:

This allows access to both normal applications and administrative interfaces.


Shared Email-Domain Policy

Applications also use the policy:

The policy validates the user according to the configured Bytek email-domain rules.

The application policy engine is normally set to ALL.

For a normal application, access requires:

For an administrative application, access requires:


Policy Engine Mode

Authentik applications normally use policy engine mode ALL.

With ALL, every enabled binding must pass.

A normal application should therefore have:

Binding Type Binding
Group bytek-users
Policy Allow bytek.ca users

An administrative application should have:

Binding Type Binding
Group bytek-admin
Policy Allow bytek.ca users

Do not attach both bytek-users and bytek-admin to the same application using ALL unless every permitted user must belong to both groups.

An earlier access-denied event occurred because both groups were attached to the same application with ALL.


Application Integration Matrix

Application Integration Type Required Group
Nextcloud Native OIDC bytek-users
Vikunja Native OIDC bytek-users
BookStack Native OIDC bytek-users
Proxmox VE Native OIDC bytek-admin
Traefik dashboard Single-application ForwardAuth bytek-admin
Uptime Kuma Proxy Provider bytek-admin

Native OIDC Applications

Nextcloud

Setting Value
Application slug nextcloud
Integration OpenID Connect user backend
Callback https://cloud.bytek.ca/apps/user_oidc/code
Subject mode User UUID
Scopes openid profile email
Required group bytek-users

Nextcloud uses native OIDC so desktop clients, mobile clients, WebDAV, CalDAV, and CardDAV can communicate directly with Nextcloud.

Do not add ForwardAuth to the Nextcloud Traefik router.

Vikunja

Setting Value
Application slug vikunja
Integration Native OIDC
Callback https://projects.bytek.ca/auth/openid/authentik
Subject mode User UUID
Scopes openid profile email
Required group bytek-users

Vikunja creates or matches users after a successful Authentik login.

BookStack

Setting Value
Application slug bookstack
Integration Native OIDC
Callback https://docs.bytek.ca/oidc/callback
Subject mode User UUID
Required group bytek-users
Signing RSA signing key
Token encryption Disabled

BookStack does not automatically link users solely by matching email addresses.

The local BookStack administrator must use a different email address from the normal Authentik account unless the account is deliberately linked using the correct external authentication ID.

Proxmox VE

Setting Value
Application slug proxmox
Integration Native OIDC
Callback https://pve.bytek.ca:8006
Subject mode User UUID
Required group bytek-admin
Selected scopes openid, email, and profile

Proxmox authentication and authorization are separate.

Authentik allows the user to authenticate, but Proxmox requires a separate ACL before the user can see or manage VMs.


OIDC Provider Standard

New OIDC providers should normally use:

Provider Setting Standard Value
Client type Confidential
Subject mode Based on the user’s UUID
Authorization flow Default implicit-consent provider flow
Signing key Selected
Encryption key None
Redirect type Strict Authorization
Policy engine ALL

A signing key is required so applications can validate tokens.

An encryption key should remain empty unless the target application explicitly supports encrypted OIDC tokens.

BookStack login failed when an encryption key was selected.

Clearing the encryption key while retaining the RSA signing key resolved the token-validation failure.


OIDC Scope Mappings

Providers must include the scopes required by the application.

Common scopes include:

The mapping names may appear as Authentik default OAuth scope mappings.

Missing scope mappings can allow the initial browser authorization to complete while causing the application to fail later when requesting profile or userinfo data.

Proxmox Scope Issue

Proxmox initially returned an authentication failure because the Authentik provider did not have the expected scopes selected.

The detailed Proxmox log reported a failure while contacting the userinfo endpoint.

Selecting the required mappings resolved the issue.

Scope Review Procedure

When an OIDC application fails:

  1. Open the Authentik provider.
  2. Review selected scope mappings.
  3. Confirm openid.
  4. Confirm email.
  5. Confirm profile.
  6. Review any application-specific mappings.
  7. Save the provider.
  8. Retry in a completely new private browser session.
  9. Review the application log.

Redirect URI Requirements

Redirect URIs must match the application exactly.

A mismatch can cause:

Known Redirect URIs

Application Strict Authorization URI
Nextcloud https://cloud.bytek.ca/apps/user_oidc/code
Vikunja https://projects.bytek.ca/auth/openid/authentik
BookStack https://docs.bytek.ca/oidc/callback
Proxmox VE https://pve.bytek.ca:8006

Do not add unneeded wildcard redirect URIs.

Strict redirect matching is preferred.


Post-Logout Redirects

Where supported, providers should include approved post-logout destinations.

BookStack uses destinations such as:

Post-logout redirects must use the actual production hostname.

Do not use obsolete provisional hostnames such as wiki.bytek.ca.


ForwardAuth Applications

Traefik Dashboard

The Traefik dashboard uses a Proxy Provider configured for single-application ForwardAuth.

Setting Value
Application slug traefik-dashboard
External host https://proxy.bytek.ca
Required group bytek-admin
Shared policy Allow bytek.ca users
Outpost Embedded outpost

The Traefik middleware sends authentication checks to Authentik.

The callback path under /outpost.goauthentik.io/ must remain reachable without applying the same ForwardAuth middleware.

The outpost ping endpoint should return HTTP 204.

Uptime Kuma

Uptime Kuma uses an Authentik Proxy Provider.

Setting Value
Application slug uptime-kuma
External host https://status.bytek.ca
Internal host http://192.168.2.115:3001
Required group bytek-admin
Shared policy Allow bytek.ca users
Outpost Embedded outpost

Public status-page, badge, push, and asset paths may require selected unauthenticated-path exceptions.

Do not disable Uptime Kuma’s local authentication until the Authentik proxy path has been tested successfully.


Embedded Outpost

The embedded outpost handles Authentik proxy integrations.

Applications assigned to the embedded outpost include:

The outpost must be able to reach each protected application backend.

For Uptime Kuma, Authentik at 192.168.2.162 must be permitted to reach 192.168.2.115 on TCP port 3001.

The outpost callback path must remain accessible through Traefik.


Outpost Health

The outpost health endpoint should return HTTP 204.

For the Traefik dashboard, test:

curl -k -I https://proxy.bytek.ca/outpost.goauthentik.io/ping

Expected result:

A 204 response contains no page body and is expected.

If the endpoint redirects to login or loops repeatedly, review:


Reverse-Proxy Requirements

Traefik must preserve the original request information for Authentik.

Important forwarded values include:

Incorrect forwarded headers can cause:

An Authentik CSRF error previously reported that the CSRF cookie was not set.

When diagnosing a CSRF error, review:


DNS Requirements

Authentik must be reachable from:

Internal Resolution

LAN clients using Pi-hole resolve:

Proxmox Resolution

Proxmox uses Quad9 and normally resolves:

This sends Proxmox’s server-to-server OIDC requests through:

  1. VPS.
  2. WireGuard.
  3. Traefik.
  4. Authentik.

Container Resolution

Application containers that require private split DNS should use Pi-hole at 192.168.2.65.

If an OIDC discovery endpoint becomes unreachable after a power failure, verify DNS from inside the application container before changing provider credentials.


Health Endpoints

Direct Readiness

Direct backend:

http://192.168.2.162:9000/-/health/ready/

Expected result:

Routed Readiness

Public hostname:

Open Authentik Readiness

Expected result:

Embedded Outpost

The outpost ping endpoint should return:


Container Management

Move to the Authentik deployment directory:

cd /opt/authentik

Check container state:

sudo docker compose ps

List Compose service names:

sudo docker compose config --services

View recent logs:

sudo docker compose logs --tail 100

View server logs:

sudo docker compose logs --tail 100 server

View worker logs:

sudo docker compose logs --tail 100 worker

The exact service names should be confirmed using the Compose service listing before running service-specific commands.


Expected Container State

The Authentik stack should have healthy or running equivalents of:

The server should not be considered ready until PostgreSQL and Redis are available.

A running Docker container does not necessarily mean the application is ready.

Use the readiness endpoint for application-level validation.


User Administration

When creating a user:

  1. Create or confirm the user’s email address.
  2. Add the user to the required groups.
  3. Confirm MFA enrollment.
  4. Confirm the user appears in the application portal.
  5. Test one user-facing application.
  6. Test application logout.
  7. Confirm no duplicate account is created.
  8. Review application-specific permissions.

Do not add normal users to bytek-admin.


Administrator Administration

An Authentik administrator should:

Administrative group membership should be reviewed periodically.


MFA

Authentik provides MFA for applications using OIDC or proxy authentication.

MFA should be required for:

Preserve recovery codes or backup authentication devices.

Do not rely on one physical authenticator without a documented recovery method.


Local Application Recovery Accounts

Authentik must not be the only recovery path.

Proxmox

Use:

Nextcloud

Use:

BookStack

Switch:

Then sign in using the dedicated local administrator.

Uptime Kuma

Restore direct private access and re-enable local authentication.

Traefik

Restore a known-good dashboard file or use retained Basic Auth.


Common Failure Scenarios

Application Shows Permission Denied

Possible causes:

Review the Authentik denial explanation.

A binding shown as None in the explanation may correspond to a direct group-membership check.

Discovery Endpoint Is Unreachable

Possible causes:

Test discovery from the application host and container.

Possible causes:

Test using a new private browser window.

Token Payload Cannot Be Parsed

Possible cause:

Correction:

User’s Email Is Already Taken

The application may not automatically link an OIDC account to a local account based only on email.

For BookStack:

Authentication Works but Application Is Empty

Authentication succeeded, but application authorization is missing.

For Proxmox:


OIDC Troubleshooting Order

When an OIDC application fails:

  1. Keep the local administrator session open.
  2. Confirm Authentik readiness.
  3. Confirm Traefik routing.
  4. Confirm the application provider.
  5. Confirm the application slug.
  6. Confirm client ID and client secret.
  7. Confirm redirect URI.
  8. Confirm selected scope mappings.
  9. Confirm signing key.
  10. Confirm encryption key is empty.
  11. Confirm user group membership.
  12. Confirm policy results.
  13. Test the discovery endpoint.
  14. Test DNS from the application container.
  15. Review the application log.
  16. Review Authentik events.
  17. Retry from a completely new private browser session.

Do not recreate the provider until the detailed failure is understood.


Monitoring

Monitor Target
Authentik VM Ping 192.168.2.162
Direct readiness http://192.168.2.162:9000/-/health/ready/
Routed readiness https://portal.bytek.ca/-/health/ready/
Authentik certificate portal.bytek.ca
PostgreSQL availability Internal service-level check
Embedded outpost Outpost ping endpoint

Monitoring should distinguish between:

Uptime Kuma

Purpose

Uptime Kuma provides availability monitoring for the Bytek homelab.

Uptime Kuma monitors services at multiple layers so an outage can be isolated quickly.

Monitoring can determine whether a failure is caused by:


Service Information

Setting Value
Service name Uptime Kuma
Private IP address 192.168.2.115
Backend port TCP 3001
Public hostname status.bytek.ca
Deployment directory /opt/uptime-kuma
Container name uptime-kuma
Persistent data /app/data inside the container
Database Embedded MariaDB
Container DNS 192.168.2.65
Public routing Traefik
Target authentication Authentik Proxy Provider
Required Authentik group bytek-admin
Backup coverage Proxmox scheduled backup
Proxmox VM ID Confirm current VM ID

Dashboard:

Open Uptime Kuma


Architecture Role

Uptime Kuma monitors both private backends and routed application hostnames.

A routed monitor follows this path:

  1. Uptime Kuma resolves the application hostname through Pi-hole.
  2. Pi-hole returns Traefik’s private IP address, 192.168.2.182.
  3. Uptime Kuma connects to Traefik.
  4. Traefik selects the application router.
  5. Traefik forwards the request to the private backend.
  6. Uptime Kuma records the response status and latency.

A direct backend monitor bypasses Traefik and connects directly to the application VM.

Using both monitor types helps distinguish infrastructure failures from reverse-proxy failures.


Monitoring Layers

Each important service should have up to three monitoring layers.

VM or LXC Monitor

A ping monitor verifies that the guest is reachable on the network.

A successful ping proves:

A successful ping does not prove that the application is healthy.

Direct Backend Monitor

A direct backend monitor connects to the private application address and port.

A successful backend monitor proves:

A direct backend monitor bypasses:

Routed Application Monitor

A routed monitor uses the normal HTTPS application hostname.

A successful routed monitor proves:


Failure Interpretation

VM Monitor Backend Monitor Routed Monitor Likely Failure
Down Down Down VM, LXC, Proxmox, or network failure
Up Down Down Docker, application, database, or backend firewall failure
Up Up Down Pi-hole, Traefik, TLS, router, or Authentik failure
Up Up Up Service is operating normally
Up Down Up Monitor target or direct-backend firewall configuration may be incorrect
Down Up Up ICMP is blocked, but the application is available

A failed ping monitor does not always mean the VM is down. The guest or Proxmox firewall may block ICMP while allowing application traffic.


Docker Deployment

The Uptime Kuma deployment is managed using Docker Compose.

Deployment directory:

/opt/uptime-kuma

Before running Compose commands, move into the deployment directory using:

cd /opt/uptime-kuma

Check container state using:

sudo docker compose ps

View recent logs using:

sudo docker compose logs --tail 100 uptime-kuma

Follow logs live using:

sudo docker compose logs -f uptime-kuma

Validate the Compose configuration using:

sudo docker compose config --quiet

Apply normal configuration changes using:

sudo docker compose up -d

Recreate the container after changing Docker-level settings such as DNS, volumes, environment variables, or networking using:

sudo docker compose up -d --force-recreate uptime-kuma


Persistent Data

Uptime Kuma stores its application data under /app/data inside the container.

The persistent host mapping should be confirmed from the current Compose file.

The persistent data includes information such as:

The persistent-data directory must remain mounted across container recreation.

Never remove the persistent volume while troubleshooting a container-startup problem.


Database

The current Uptime Kuma deployment uses embedded MariaDB.

Database health is reported by the container health check.

The container should not be considered fully healthy until the database is available.

Check container health using:

sudo docker inspect --format='{{.State.Health.Status}}' uptime-kuma

Expected result:

If the result is starting, allow the health check to continue while reviewing logs.

If the result is unhealthy, inspect the Uptime Kuma logs before restarting or recreating the container.


Docker DNS

The Uptime Kuma container explicitly uses Pi-hole at 192.168.2.65.

This allows Uptime Kuma to resolve internal split-DNS records.

Verify container DNS using:

sudo docker inspect --format='DNS={{json .HostConfig.Dns}}' uptime-kuma

Expected result:

Test an internal hostname from inside the container using:

sudo docker exec uptime-kuma getent hosts portal.bytek.ca

Expected result:

Test another internal hostname using:

sudo docker exec uptime-kuma getent hosts projects.bytek.ca

Expected result:


DNS Failure After a Power Interruption

Docker DNS previously failed after an electrical outage.

Symptoms included:

  1. Confirm Pi-hole is running.
  2. Confirm Pi-hole owns 192.168.2.65.
  3. Confirm the Uptime Kuma VM resolves internal hostnames.
  4. Confirm the Uptime Kuma container resolves internal hostnames.
  5. Verify the container’s explicit DNS configuration.
  6. Restart the Uptime Kuma container.
  7. Recreate the container if Docker-level DNS configuration changed.
  8. Confirm the monitors recover.

Do not rebuild Uptime Kuma or delete persistent data because of a DNS-only failure.


Public Dashboard Routing

The Uptime Kuma dashboard is available at:

Open Uptime Kuma

Internal clients resolve status.bytek.ca to Traefik at 192.168.2.182.

External clients resolve status.bytek.ca to the public VPS at 38.29.213.101.

The public path includes:

  1. WHC public DNS.
  2. Public VPS.
  3. WireGuard.
  4. Home WireGuard gateway.
  5. Traefik.
  6. Authentik embedded outpost when enabled.
  7. Uptime Kuma at 192.168.2.115:3001.

Authentication Design

Uptime Kuma does not use the same native OIDC design as Nextcloud, Vikunja, BookStack, and Proxmox.

The target design uses an Authentik Proxy Provider.

The expected authentication flow is:

  1. The administrator opens status.bytek.ca.
  2. Traefik forwards the request to the Authentik embedded outpost.
  3. Authentik checks the existing authentication session.
  4. Authentik requests credentials and MFA if required.
  5. Authentik evaluates the application bindings.
  6. Authentik proxies the request to Uptime Kuma.
  7. Uptime Kuma displays the dashboard.

Authentik Application

Setting Value
Application name Uptime Kuma
Application slug uptime-kuma
Provider type Proxy Provider
Provider mode Proxy
External host https://status.bytek.ca
Internal host http://192.168.2.115:3001
Required group bytek-admin
Required policy Allow bytek.ca users
Policy engine ALL
Outpost Authentik Embedded Outpost

Only users who satisfy both the group and policy requirements should reach the dashboard.


Embedded Outpost Connectivity

The embedded outpost runs through the Authentik service at 192.168.2.162.

Authentik must be able to reach Uptime Kuma at:

The Uptime Kuma VM firewall must allow:

Test from the Authentik VM using:

curl -I http://192.168.2.115:3001/

A healthy Uptime Kuma response may redirect to /dashboard.


Authentication Migration Safety

Do not disable Uptime Kuma’s local authentication before the Authentik proxy works.

Use this migration order:

  1. Create the Authentik application and Proxy Provider.
  2. Assign the application to the embedded outpost.
  3. Allow Authentik to reach TCP port 3001.
  4. Route status.bytek.ca through the outpost.
  5. Test Authentik authentication.
  6. Confirm the Uptime Kuma local login still appears behind Authentik.
  7. Test with the bytek-admin account.
  8. Test denial with a non-administrator account.
  9. Confirm public status pages still work if required.
  10. Disable Uptime Kuma local authentication.
  11. Enable Trust Proxy.
  12. Restrict direct TCP 3001 access.
  13. Test recovery.

During the intermediate state, both Authentik and Uptime Kuma authentication may appear.

That is intentional until the Authentik path is validated.


Disabling Local Authentication

Only disable local Uptime Kuma authentication after Authentik is proven reliable.

Before disabling local authentication:

After disabling local authentication:


Direct Backend Security

When Uptime Kuma local authentication is disabled, direct access to 192.168.2.115:3001 must be restricted.

Otherwise, a LAN client could bypass Authentik and reach an unauthenticated dashboard.

The final firewall should permit TCP port 3001 only from approved sources such as:

Source Purpose
192.168.2.162 Authentik embedded outpost
Administrative workstation during testing Temporary recovery access
Approved monitoring source Only if required

Remove temporary direct access after validation.


Public Status Pages

Some Uptime Kuma status pages may be intended for unauthenticated public viewing.

Authentik Proxy Provider exclusions may be required for:

Unauthenticated-path exclusions must be as narrow as practical.

Do not exclude the entire Uptime Kuma API.

After configuring exclusions:

  1. Open a public status page in a private browser.
  2. Confirm no Authentik login is required.
  3. Open the dashboard.
  4. Confirm Authentik login is required.
  5. Test a push monitor.
  6. Test a status badge if used.
  7. Review Authentik and Traefik logs.

Push Monitors

Push monitors rely on a unique URL that an external process calls to report success.

If Uptime Kuma sits behind Authentik, the push path must remain reachable without an interactive login.

Protect push-monitor URLs as secrets.

Do not publish push URLs in BookStack.

If a push monitor stops updating after enabling Authentik:

  1. Confirm the push path is excluded.
  2. Confirm Traefik routes the request correctly.
  3. Confirm the unique token is unchanged.
  4. Review the Uptime Kuma monitor history.
  5. Review Traefik access logs.
  6. Review Authentik outpost logs.

Monitor Naming Standard

Use consistent names so the dashboard is easy to scan.

Examples:


Core Infrastructure Monitors

Monitor Suggested Type Target
Proxmox VE HTTPS or TCP 192.168.2.254:8006
Pi-hole VM or LXC Ping 192.168.2.65
Pi-hole DNS TCP TCP 192.168.2.65:53
Pi-hole DNS UDP UDP or DNS 192.168.2.65:53
WireGuard gateway Ping 192.168.2.64
Public VPS Ping or TCP 38.29.213.101
Public VPS HTTPS TCP 38.29.213.101:443
Traefik VM Ping 192.168.2.182
Traefik HTTPS TCP 192.168.2.182:443
Authentik direct HTTP Direct readiness endpoint
Authentik routed HTTPS Routed readiness endpoint

Nextcloud Monitors

Monitor Type Target
Nextcloud VM Ping 192.168.2.100
Nextcloud AIO Apache TCP 192.168.2.100:11000
Nextcloud Through Traefik HTTPS https://cloud.bytek.ca/status.php

Expected routed status:


Vikunja Monitors

Monitor Type Target
Vikunja VM Ping 192.168.2.121
Vikunja Backend Direct HTTP http://192.168.2.121:3456/health
Vikunja Through Traefik HTTPS https://projects.bytek.ca/health

Expected health status:

The Vikunja VM firewall must allow Uptime Kuma at 192.168.2.115 to reach TCP port 3456.


BookStack Monitors

Monitor Type Target
BookStack VM Ping Confirm BookStack IP
BookStack Backend Direct HTTP BookStack IP on port 6875
BookStack Through Traefik HTTPS https://docs.bytek.ca/login

Use accepted status codes from 200 through 399 if the application redirects to authentication.

The BookStack VM firewall must allow Uptime Kuma at 192.168.2.115 to reach TCP port 6875.


Authentik Monitors

Monitor Type Target
Authentik VM Ping 192.168.2.162
Authentik Direct Readiness HTTP http://192.168.2.162:9000/-/health/ready/
Authentik Routed Readiness HTTPS https://portal.bytek.ca/-/health/ready/
Authentik Certificate Certificate portal.bytek.ca
Authentik Outpost HTTP Outpost ping endpoint

Expected results:


Traefik Monitors

Monitor Type Target
Traefik VM Ping 192.168.2.182
Traefik HTTPS TCP 192.168.2.182:443
Traefik Dashboard HTTPS https://proxy.bytek.ca/
Traefik Certificate Certificate proxy.bytek.ca

The dashboard monitor must account for Authentik and Basic Auth redirects if those protections are enabled.

Do not store Basic Auth credentials in BookStack.


Proxmox Monitor Considerations

Proxmox may return a response that is valid but not HTTP 200 for some request methods.

Avoid relying on an unsupported HTTP HEAD request.

A TCP monitor on port 8006 can verify listener availability.

An HTTPS monitor can verify the login page if configured with an appropriate method and accepted status range.

Proxmox remains private and should be monitored using its private address.


Certificate Monitoring

Important public hostnames should have certificate-expiry monitoring.

Certificate monitoring should alert before expiration.

A valid application response does not guarantee that certificate renewal automation remains healthy.


Notification Channels

Uptime Kuma can notify administrators when a monitor changes state.

The configured notification methods should be recorded after verification.

Potential channels may include:

Notification credentials must remain outside BookStack.

BookStack should document:


Notification Policy

Critical Infrastructure

Immediate notification for:

Applications

Notify after enough failed checks to avoid alerts from brief application restarts.

Maintenance

Create maintenance windows before:

This prevents expected maintenance from generating unnecessary alerts.


Monitor Timing

Monitor intervals should balance timely detection with unnecessary load.

Suggested principles:

These values should be tuned after observing false positives and actual recovery behavior.


Status Pages

Status pages provide a consolidated view of selected monitors.

A public status page should include only services appropriate for public disclosure.

Avoid publishing:

A private administrative status page may include more detail behind Authentik.


Maintenance Windows

Use maintenance windows for planned outages.

Common maintenance events include:

Record:


Firewall Requirements

Uptime Kuma requires outbound access to monitored services.

Application firewalls may require narrow inbound rules from:

Known direct-monitor requirements include:

Destination Port
Pi-hole TCP and UDP 53
Proxmox VE TCP 8006
Traefik TCP 443
Authentik TCP 9000
Nextcloud TCP 11000
Vikunja TCP 3456
BookStack TCP 6875

ICMP must be allowed if ping monitors are used.

A failed ping monitor with a healthy HTTP monitor normally indicates blocked ICMP rather than a service outage.


Health Validation

Check the VM address using:

ip -br -4 addr

Check the container state using:

sudo docker compose ps

Check container health using:

sudo docker inspect --format='{{.State.Health.Status}}' uptime-kuma

Confirm direct access using:

curl -I http://192.168.2.115:3001/

Confirm DNS inside the container using:

sudo docker exec uptime-kuma getent hosts portal.bytek.ca

Confirm the public route using:

curl -I https://status.bytek.ca/

Interpret redirects according to the currently enabled authentication layers.


Logging

Review Uptime Kuma logs using:

sudo docker compose logs --tail 100 uptime-kuma

Follow logs live using:

sudo docker compose logs -f uptime-kuma

Review logs for:

Do not paste access tokens, notification secrets, cookies, or push-monitor URLs into BookStack.


Common Failure Scenarios

Many Hostname Monitors Fail Simultaneously

Likely causes:

Check direct IP monitors before assuming every application failed.

Direct Backends Work but Routed Monitors Fail

Likely causes:

VM Ping Fails but HTTP Works

Likely cause:

The VM is likely available.

Kuma Dashboard Works by IP but Not by Hostname

Check:

Authentik Login Works but Kuma Is Unreachable

Check:

Public Status Page Requires Login

Check:

Push Monitor Stops Working

Check:


Power-Failure Recovery

After a power interruption:

  1. Confirm Proxmox.
  2. Confirm Pi-hole.
  3. Confirm the WireGuard gateway.
  4. Confirm Authentik.
  5. Confirm Traefik.
  6. Confirm the Uptime Kuma VM owns 192.168.2.115.
  7. Confirm Docker.
  8. Confirm the container.
  9. Confirm container DNS.
  10. Confirm embedded MariaDB health.
  11. Confirm direct dashboard access.
  12. Confirm the routed dashboard.
  13. Confirm monitors recover.
  14. Restart or recreate the container only if DNS remains broken.

Uptime Kuma should start after the core DNS, identity, and routing services when practical.


Backup

The Uptime Kuma VM is included in the Proxmox scheduled backup job.

Protect:

A stopped Proxmox backup provides the strongest whole-VM consistency for a baseline.

Snapshot-mode backup may be used for routine operation where downtime is undesirable.


Recovery Procedure

If Uptime Kuma is corrupted or unavailable:

  1. Confirm the VM is running.
  2. Confirm 192.168.2.115.
  3. Confirm Docker.
  4. Confirm the persistent-data mount.
  5. Confirm the container.
  6. Review logs.
  7. Confirm embedded database health.
  8. Test direct TCP port 3001.
  9. Test Pi-hole DNS.
  10. Test the Traefik route.
  11. Test the Authentik proxy.

If the VM must be restored:

  1. Restore the latest backup under a temporary VM ID.
  2. Disconnect the restored VM network adapter.
  3. Verify Docker and persistent data.
  4. Verify monitor configuration.
  5. Shut down the failed production VM.
  6. Assign the expected network identity.
  7. Start the restored VM.
  8. Confirm 192.168.2.115.
  9. Confirm the dashboard.
  10. Confirm notifications and monitors.
  11. Reconnect the Authentik route.

Authentik Recovery

If the Authentik proxy prevents access:

  1. Restore the known-good direct Traefik route.
  2. Temporarily permit the administrative workstation to reach TCP 3001.
  3. Access Uptime Kuma using the private IP.
  4. Re-enable Uptime Kuma local authentication.
  5. Repair the Authentik Proxy Provider.
  6. Test Authentik with a private browser.
  7. Confirm bytek-admin access.
  8. Confirm a normal user is denied.
  9. Disable local authentication again only after validation.
  10. Restrict TCP 3001 again.

Record the original administrator password securely even after local authentication is disabled.


Security Checklist


Validation Checklist


Document Control