Skip to content

A traefik middleware plugin to handle and manipulate cookie flags on the fly

License

Notifications You must be signed in to change notification settings

Lambda-IT/traefik-plugin-cookie-flags

Repository files navigation

traefik-plugin-cookie-flags

Configuration

Static

experimental:
  plugins:
    cookieFlags:
      modulename: "github.com/Lambda-IT/traefik-plugin-cookie-flags"
      version: "v0.1.0" #replace with newest version

Dynamic

To configure the plugin you should create a middleware in your dynamic configuration as explained here. The following example creates and uses the cookie path prefix middleware plugin to add the prefix "/foo" to the cookie paths:

http:
  routes:
    my-router:
      rule: "Host(`localhost`)"
      service: "my-service"
      middlewares:
        - "cookieFlags"
  services:
    my-service:
      loadBalancer:
        servers:
          - url: "http://127.0.0.1"
  middlewares:
    cookieFlags:
      plugin:
        cookieFlags:
          sameSite: "None"

Inspired by https://github.com/SchmitzDan/traefik-plugin-cookie-path-prefix

About

A traefik middleware plugin to handle and manipulate cookie flags on the fly

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published