/JWT Token

JWT Token

2
v0.1.4

JWT Token

JWT Token is a middleware plugin for Traefik which verifies a jwt token and adds the payload as injected header to the request

Configuration

Start with command

command:
- "--experimental.plugins.jwt-token.modulename=github.com/toanz/jwt-token"
- "--experimental.plugins.jwt-token.version=v0.1.2"

Activate plugin in your config

apiVersion: traefik.containo.us/v1alpha1
kind: Middleware
meta:
spec:
plugin:
jwt-token:
secret: SECRET
proxyHeaderName: injectedPayload
authHeader: Authorization
headerPrefix: Bearer

Use as docker-compose label

labels:
- "traefik.http.routers.my-service.middlewares=my-jwt-token@file"