serversTransport reference within docker labels

How should I go ahead to apply the serversTransports dynamic configuration as I get error when trying to add it and reference it as a label in the docker compose file

{
  "container": "Apache-NiFi-nifi-yc1f8nc4eexm04p21jb6okeak",
  "level": "error",
  "msg": "field not found, node: serversTransport:nifiui",
  "providerName": "docker",
  "time": "2022-10-24T09:52:25Z"
}

I have the following configuration

Traefik.toml

#General
[api]  
    dashboard = true

[metrics]
  [metrics.prometheus]

[ping]

[log]
  level = "DEBUG"
  filepath = "/traefik/logs/traefik/traefik.log"
  format = "json"

[accessLog]
  filePath = "/traefik/logs/access/access.log"
  bufferingSize = 10

# Allows Traefik to skip the SSL Certificate verification on HTTPS Globally
# Note : Traefik documentation doesn't specify that this configuration needs to be 
# backed with the below label on the service
# - traefik.http.services.nifi-flow.loadbalancer.server.scheme=https

[serversTransport]
  insecureSkipVerify = false

# Allows Traefik to skip the SSL Certificate verification on HTTPS for a specific service

[http.serversTransports.nifiui]
  serverName = "mynifi"
  insecureSkipVerify = true

#ENTRYPOINTS

[entryPoints]
  [entryPoints.web]
    address = ":80"    
    [entryPoints.web.http]
      [entryPoints.web.http.redirections]
        [entryPoints.web.http.redirections.entryPoint]
          to = "websecure"
          scheme = "https"  

  [entryPoints.websecure]
    address = ":443"
    [entryPoints.websecure.forwardedHeaders]
      trustedIPs = ["<IP_Address>"] # f5
    [entryPoints.websecure.http.tls]

  [entryPoints.apiDashboard]
    address = ':70000'
    

#MIDDLEWARES
[http.middlewares]
  [http.middlewares.test-retry.retry]
     attempts = 4
  [http.middlewares.https-redirectscheme.redirectScheme]
    scheme = "https"
    permanent = true

#TLS
[[tls.certificates]]
  certFile = "/folder/cert.cer"
  keyFile = "/folder/cert.key"


#PROVIDERS
[providers]
  providersThrottleDuration = 2
  [providers.docker]
    watch = true
    endpoint = "unix:///var/run/docker.sock"
    exposedByDefault = true
    swarmMode = true
    swarmModeRefreshSeconds = 15
    network = "traefik_webgateway"
  [providers.file]
    filename = "/etc/traefik/traefik.toml"
    watch = true

Docker-Compose.yml

version: "3.7"
services:
    nifi:
        user: root
        hostname: mynifi
        image: apache/nifi:latest
        restart: on-failure
        environment:
            - NIFI_WEB_HTTPS_PORT=8443
            - NIFI_WEB_PROXY_HOST=$DOCKER_HOST_URL:443
            - NIFI_WEB_PROXY_CONTEXT_PATH=/
            - SINGLE_USER_CREDENTIALS_USERNAME=admin
            - SINGLE_USER_CREDENTIALS_PASSWORD=ctsBtRBKHRAx69EqUghvvgEvjnaLjFEB
            - NIFI_SECURITY.AUTORELOAD.ENABLED=true
        volumes:
            - nifi_database_repository:/opt/nifi/nifi-current/database_repository
            - nifi_flowfile_repository:/opt/nifi/nifi-current/flowfile_repository
            - nifi_content_repository:/opt/nifi/nifi-current/content_repository
            - nifi_provenance_repository:/opt/nifi/nifi-current/provenance_repository
            - nifi_state:/opt/nifi/nifi-current/state
            - nifi_logs:/opt/nifi/nifi-current/logs
            - nifi_conf:/opt/nifi/nifi-current/conf
        networks:
            - traefik_webgateway
        deploy:
            labels:
                # traefik
                - traefik.enable=true
                - "traefik.docker.lbswarm=true"
                # service
                - traefik.http.services.nifi-flow.loadbalancer.server.port=8443
                - traefik.http.services.nifi-flow.loadbalancer.server.scheme=https
                - "traefik.http.services.nifi-flow.loadBalancer.serversTransport:nifiui"
                # middlewares
                - "traefik.http.middlewares.nifi-headers.headers.customRequestHeaders.X-ProxyScheme=https"
                - "traefik.http.middlewares.nifi-headers.headers.customRequestHeaders.X-ProxyHost=$DOCKER_HOST_URL"
                - "traefik.http.middlewares.nifi-headers.headers.customRequestHeaders.X-ProxyPort=443"
                - "traefik.http.middlewares.nifi-headers.headers.customRequestHeaders.X-ProxyContextPath:/"
                # Routers
                - traefik.http.routers.nifi-flow.middlewares=nifi-headers
                - traefik.http.routers.nifi-flow.service=nifi-flow
                - traefik.http.routers.nifi-flow.entrypoints=$TRAEFIK_HTTPS_ENTRYPOINT
                - traefik.http.routers.nifi-flow.tls=true
                - traefik.http.routers.nifi-flow.rule=Host(`$DOCKER_HOST_URL`) && PathPrefix(`/nifi`)
            restart_policy:
                condition: on-failure
                delay: 120s
                max_attempts: 3
                window: 60s
networks:
  traefik_webgateway:
    external: true
      
volumes:
  nifi_conf: {external: true}
  nifi_database_repository: {external: true}
  nifi_flowfile_repository: {external: true}
  nifi_content_repository: {external: true}
  nifi_provenance_repository: {external: true}
  nifi_state: {external: true}
  nifi_logs: {external: true}

I have also tried using the @file at the end of the transportname, still with no luck

- "traefik.http.services.nifi-flow.loadBalancer.serversTransport:nifiui@file"

Ah my bad I was using : instead of the = on the labels. The labels are taking effect.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.