Quantcast
Channel: Grafana k6 - Grafana Labs Community Forums
Viewing all articles
Browse latest Browse all 386

Writing logs to a persistent storage

$
0
0

Hi all.,
I am running k6 operator in argo workflows with multiple instances. I want to write /pipe all the logs generated by test pods to a persistent storage so that it can be later ingested into graylog.

Any suggestion on how to achieve this

name: run-k6
      inputs: {}
      outputs: {}
      metadata: {}
      resource:
        action: create
        manifest: |
          apiVersion: k6.io/v1alpha1
          kind: TestRun
          metadata:
            name: load-test   
          spec:
            parallelism: {{workflow.parameters.parallelism}}
            volumes:
            - name: k6-logs
              persistentVolumeClaim:
               claimName: k6-logs-pvc
            script:
              configMap:
                name: {{workflow.parameters.configMapName}}
                file: {{workflow.parameters.scriptFileName}}
            arguments: --tag testid={{workflow.parameters.testId}} --log-format raw --log-output=file=/var/log/kaarya/loadtest.log 
            runner:
              image: {{workflow.parameters.k6Image}}
              imagePullSecrets:
                - name: dockercred
              imagePullPolicy: IfNotPresent
              env:
                - name: K6_OUT
                  value: influxdb=<>
            
           

need to mount /var/log/kaarya/loadtest.log to host volume

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 386

Latest Images

Trending Articles



Latest Images