Skip to content
You're viewing an older version of this GitHub Action. Do you want to see the latest version instead?
copy

GitHub Action

loki-action

v2

loki-action

copy

loki-action

Send workflow logs to qryn/loki

Installation

Copy and paste the following snippet into your .yml file.

              

- name: loki-action

uses: metrico/loki-action@v2

Learn more about this action in metrico/loki-action

Choose a version

LogQL Push Action

Collect and ship logs from a Github Actions workflow to a LogQL Push API (qryn, loki)

Usage

some-job:
  runs-on: ubuntu-latest
  steps:
    - name: checkout
      uses: actions/checkout@v2
    - name: build
      run: this-will-fail
    - name: qryn-logs
      if: failure()
      uses: metrico/qryn-loki-logs@v1
      with:
        repo-token: ${{ secrets.GITHUB_TOKEN }}
        endpoint: ${{ secrets.LOGQL_ENDPOINT }}
        username: ${{ secrets.LOGQL_USER }}
        password: ${{ secrets.LOGQL_PASS }}
        job-names: build

Development

Install the dependencies

$ npm install

Lint and package it for distribution

$ npm run all

Acknowledgements

Loosely based on elastic-logs by masci