Configuration
Tip
Hover over any variable or label to reveal a 'copy to clipboard' button
Docker Secrets
PlugNPiN supports Docker Secrets for managing sensitive credentials and host URLs. This is the recommended approach for production deployments.
Precedence: Environment variables always take precedence over Docker Secrets.
Usage: Secrets' filenames must match the corresponding environment variable.
Environment Variables
Required
| Variable | Description | Notes |
|---|---|---|
ADGUARD_HOME_HOST0.8.0 |
The URL of your AdGuard Home instance | Only required if ADGUARD_HOME_DISABLED is set to false. Can be set using Docker Secrets |
ADGUARD_HOME_USERNAME0.8.0 |
Your AdGuard Home username | Only required if ADGUARD_HOME_DISABLED is set to false. Can be set using Docker Secrets |
ADGUARD_HOME_PASSWORD0.8.0 |
Your AdGuard Home password | Only required if ADGUARD_HOME_DISABLED is set to false. Can be set using Docker Secrets |
NGINX_PROXY_MANAGER_HOST0.1.0 |
The URL of your Nginx Proxy Manager instance. | Can be set using Docker Secrets |
NGINX_PROXY_MANAGER_USERNAME0.1.0 |
Your Nginx Proxy Manager username. | Can be set using Docker Secrets |
NGINX_PROXY_MANAGER_PASSWORD0.1.0 |
Your Nginx Proxy Manager password. Important: It is recommended to create a new non-admin user with only the "Proxy Hosts - Manage" permission. |
Can be set using Docker Secrets |
PIHOLE_HOST0.1.0 |
The URL of your Pi-Hole instance. | Only required if PIHOLE_DISABLED is set to false. Can be set using Docker Secrets |
PIHOLE_PASSWORD0.1.0 |
Your Pi-Hole password. Important: It is recommended to create an 'application password' rather than using your actual admin password. |
Only required if PIHOLE_DISABLED is set to false. Can be set using Docker Secrets |
Optional
| Variable | Description | Default |
|---|---|---|
ADGUARD_HOME_DISABLED0.8.0 |
Set to false to enable AdGuard Home functionality |
true |
DEBUG0.1.0 |
Set to true to enable DEBUG level logs |
false |
DOCKER_HOSTS0.9.0 |
Comma-separated list of multiple docker hosts to monitor, with an empty string meaning the default local host. For example DOCKER_HOSTS=,tcp://192.168.0.101:2375 |
"" |
DOCKER_HOST0.1.0 |
The URL of a docker socket proxy. If set, you don't need to mount the docker socket as a volume. Querying containers must be allowed (typically done by setting the CONTAINERS environment variable to 1). |
None |
METRICS1.0.0 |
Exposes a /metrics endpoint for Prometheus scraping. See Monitoring → Prometheus. |
false |
METRICS_SERVER_PORT1.0.0 |
Port for the metrics endpoint. See Monitoring → Prometheus. | 9100 |
PIHOLE_DISABLED0.6.0 |
Set to true to disable Pi-Hole functionality |
false |
RUN_INTERVAL0.1.0 |
The interval at which to scan for new containers, in Go's time.ParseDuration format. Set to 0 to run once and exit. |
1h |
TZ0.1.0 |
Customise the timezone. | "" |
Per Container Configuration
Use the following labels on your containers to enable specific features
General Options
| Label | Description | Default | Notes |
|---|---|---|---|
plugNPiN.options.createOnHealthy1.0.0 |
If set to true, PlugNPiN will wait for the container to become healthy before creating entries |
false |
This option requires the container to have a Docker Healthcheck defined. If no healthcheck is found, an error will be logged and no entries will be created |
AdGuard Home
| Label | Description | Default | Notes |
|---|---|---|---|
plugNPiN.adguardHomeOptions.targetDomain0.8.0 |
If provided, a CNAME DNS Rewrite will be created |
Nginx Proxy Manager
| Label | Description | Default | Notes |
|---|---|---|---|
plugNPiN.npmOptions.accessListName1.0.0 |
Access list to use for this host. Must already exist on the NPM instance | ||
plugNPiN.npmOptions.advancedConfig0.7.0 |
Advanced nginx configuration (referred to as Custom Nginx Configuration in NPM UI) |
If using a docker compose file make sure to use | so new lines will be respected, for example: |
|
plugNPiN.npmOptions.blockExploits0.4.0 |
Enables or disables the "Block Common Exploits" option on the proxy host. Set to true or false |
true |
|
plugNPiN.npmOptions.cachingEnabled0.4.0 |
Enables or disables the "Cache Assets" option on the proxy host. Set to true or false |
false |
|
plugNPiN.npmOptions.certificateName0.4.0 |
Certificate to use for this host. Must already exist on the NPM instance | ||
plugNPiN.npmOptions.forceSsl0.4.0 |
Force SSL | false |
|
plugNPiN.npmOptions.http2Support0.4.0 |
Enable HTTP/2 Support | false |
|
plugNPiN.npmOptions.hstsEnabled0.4.0 |
Enable HSTS | false |
|
plugNPiN.npmOptions.hstsSubdomains0.4.0 |
Enable HSTS Subdomains | false |
|
plugNPiN.npmOptions.scheme0.4.0 |
The scheme used to forward traffic to the container. Can be http or https |
http |
|
plugNPiN.npmOptions.websocketsSupport0.4.0 |
Enables or disables the "Allow Websocket Upgrade" option on the proxy host. Set to true or false |
false |
Pi-Hole
| Label | Description | Default | Notes |
|---|---|---|---|
plugNPiN.piholeOptions.targetDomain0.5.0 |
If provided, a CNAME record will be created instead of a DNS record |