andrcuns / allure-publish-action

Allure report publish action
MIT License
1 stars 1 forks source link

allure-publish-action

GitHub action to publish allure report in cloud provider of choice using allure-report-publisher

By default this action will upload a test report to cloud provider bucket and add test result summary and link to report in the job summary

Inputs

Environment variables

Action requires 2 environment variables to be set up

Github auth token

Github auth token for pull request updates if updatePr is set to comment or description

env:
  GITHUB_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Cloud auth token

Depending on cloud provider used, one of the environment variables for authentication has to be set:

env:
  AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
  AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
env:
  GOOGLE_CLOUD_CREDENTIALS_JSON: ${{ secrets.GOOGLE_CLOUD_CREDENTIALS_JSON }}

Example

steps:
  - name: Publish allure report
    uses: andrcuns/allure-publish-action@v2.7.1
    env:
      GOOGLE_CLOUD_CREDENTIALS_JSON: ${{ secrets.GOOGLE_CLOUD_CREDENTIALS_JSON }}
      GITHUB_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
    with:
      storageType: gcs
      resultsGlob: "path/to/allure-results"
      bucket: allure-test-reports
      prefix: $GITHUB_REF
      copyLatest: true
      ignoreMissingResults: true