Uploaded image for project: 'OpenShift Logging'
  1. OpenShift Logging
  2. LOG-5980

The token is empty when setting `otlp.authentication.token.from: serviceAccount`.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Undefined Undefined
    • None
    • Logging 6.0.0
    • Log Collection
    • False
    • Hide

      None

      Show
      None
    • False
    • NEW
    • VERIFIED
    • Release Note Not Required
    • Log Collection - Sprint 258
    • Moderate

      Description of problem:

      When setting `otlp.authentication.token.from: serviceAccount`, the token in vector.toml is empty, and vector pods can't connect to the log store.

      CLF:

        apiVersion: observability.openshift.io/v1
        kind: ClusterLogForwarder
        metadata:
          annotations:
            observability.openshift.io/tech-preview-otlp-output: "enabled"
          name: instance
        spec:
          managementState: Managed
          outputs:
          - name: apps
            otlp:
              authentication:
                token:
                  from: serviceAccount
              url: https://lokistack-dev-gateway-http.openshift-logging.svc.cluster.local:8080/api/logs/v1/application/otlp/v1/logs
            tls:
              insecureSkipVerify: true
            type: otlp
          - name: audit
            otlp:
              authentication:
                token:
                  from: serviceAccount
              url: https://lokistack-dev-gateway-http.openshift-logging.svc.cluster.local:8080/api/logs/v1/audit/otlp/v1/logs
            tls:
              insecureSkipVerify: true
            type: otlp
          - name: infra
            otlp:
              authentication:
                token:
                  from: serviceAccount
              url: https://lokistack-dev-gateway-http.openshift-logging.svc.cluster.local:8080/api/logs/v1/infrastructure/otlp/v1/logs
            tls:
              insecureSkipVerify: true
            type: otlp
          pipelines:
          - inputRefs:
            - application
            name: apps
            outputRefs:
            - apps
          - inputRefs:
            - audit
            name: audit
            outputRefs:
            - audit
          - inputRefs:
            - infrastructure
            name: infra
            outputRefs:
            - infra
          serviceAccount:
            name: loki-otlp 

      In vector.toml.otlp:

       [sinks.output_apps.auth]
       strategy = "bearer"
       token = ""
      
       [sinks.output_audit.auth]
       strategy = "bearer"
       token = ""
      
       [sinks.output_infra.auth]
       strategy = "bearer"
       token = "" 

      Version-Release number of selected component (if applicable):

      openshift-logging/cluster-logging-rhel9-operator/images/v6.0.0-77

      How reproducible:

      Always

      Steps to Reproduce:

      1. Create CLF with above yaml
      2. Check configurations in vector.toml

      Actual results:

      Expected results:

      Additional info:

      No issue when setting `token.from.secret`.

              vparfono Vitalii Parfonov
              qitang@redhat.com Qiaoling Tang
              Qiaoling Tang Qiaoling Tang
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: