taskmedia / ddns-whitelist

A Traefik plugin / middleware to whitelist dynamic DNS addresses
https://plugins.traefik.io/plugins/66fbe453573cd7803d65cb10/ddns-whitelist
Apache License 2.0
0 stars 0 forks source link
traefik-plugin

DDNS whitelist - Traefik plugin

Dynamic DNS whitelist plugin for Traefik.

About

The ddns-whitelist plugin for Traefik allows you to whitelist dynamic DNS (DDNS) hosts. Requests from IP addresses that do not resolve to the specified DDNS hosts will be denied.

The existing plugins can be browsed into the Plugin Catalog.

Installation

To install the ddns-whitelist plugin, add the following configuration to your Traefik static configuration:

experimental:
  plugins:
    ddns-whitelist:
      moduleName: "github.com/taskmedia/ddns-whitelist"
      version: v1.2.1

Configuration

Add the ddns-whitelist middleware to your Traefik dynamic configuration:

# Dynamic configuration

http:
  routers:
    my-router:
      rule: host(`demo.localhost`)
      service: service-foo
      entryPoints:
        - web
      middlewares:
        - ddns-whitelist-router

  services:
    service-foo:
      loadBalancer:
        servers:
          - url: http://127.0.0.1:5000

  middlewares:
    ddns-whitelist-router:
      plugin:
        ddns-whitelist:
          hostList: # hosts to dynamically whitelist via DNS lookup
            - my.router.ddns.tld
          ipList: # optional IP addresses to whitelist
            - 1.2.3.4