Hello,
I guess your are trying to convert a Traefik v1 configuration that you have found somewhere.
Because you mixed v1 and v2 configuration.
- In the v2 the static configuration and the dynamic configuration cannot be mixed by default: you have to create 2 files.
- Like with v1, the file provider must be enable to read dynamic configuration from a file.
I recommend to read: