Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tradeshift/actions-coverage-upload
This is actions-coverage-upload
https://github.com/tradeshift/actions-coverage-upload
developer-productivity
Last synced: about 1 month ago
JSON representation
This is actions-coverage-upload
- Host: GitHub
- URL: https://github.com/tradeshift/actions-coverage-upload
- Owner: Tradeshift
- License: mit
- Created: 2021-06-25T09:09:52.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2024-11-18T10:46:05.000Z (about 2 months ago)
- Last Synced: 2024-11-18T10:53:25.232Z (about 2 months ago)
- Topics: developer-productivity
- Language: TypeScript
- Size: 2.36 MB
- Stars: 1
- Watchers: 4
- Forks: 7
- Open Issues: 12
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Codeowners: CODEOWNERS
Awesome Lists containing this project
README
# `actions-coverage-upload` GitHub Action
## Overview
`actions-coverage-upload` is an internal GitHub Action designed to upload code coverage reports to a Backstage server. This action is compatible with multiple types of code coverage reports, including Cobertura and Jacoco, and offers optional support for mutual TLS.
## Prerequisites
Ensure that you are using NodeJS 16.x or higher and npm 8.x or higher before running this action.
## Inputs
The action supports the following inputs:
- `server`: The URL of the Backstage server where the coverage report should be uploaded.
- `file`: The path to the coverage report file, usually in XML format.
- `name`: The name of the service for which the coverage report is uploaded.
- `type`: The type of code coverage report. Currently supported types are `cobertura` and `jacoco`.### Optional Inputs
- `ca-cert`: CA certificate for mutual TLS.
- `client-cert`: Client certificate for mutual TLS.
- `client-key`: Client key for mutual TLS.## Example Usage
Here is a sample GitHub Actions workflow demonstrating how to use `actions-coverage-upload`.
```yaml
on: [push]jobs:
coverage-upload:
runs-on: [self-hosted,ts-large-x64-docker-large]
steps:
- uses: tradeshift/actions-coverage-upload@v1
with:
server: http://backstage:7000
file: coverage.xml
name: servicename
type: [cobertura|jacoco]
# optional values for using mutual tls:
ca-cert: ${{ secrets.MTLS_CACERT }}
client-cert: ${{ secrets.MTLS_CERT }}
client-key: ${{ secrets.MTLS_KEY }}
```## Build and Development
To build the project you'll need NodeJS 16.x and npm 8.x or higher:
```bash
npm ci
npm run all
```