Skip to content

Incorporate SARIF option and update CI test and docs #181

Incorporate SARIF option and update CI test and docs

Incorporate SARIF option and update CI test and docs #181

Workflow file for this run

name: test
on: push
jobs:
test:
runs-on: ubuntu-22.04
steps:
- name: Checkout this repository
uses: actions/checkout@v4
- name: Run Ansible scan with minimal possible example
uses: ./
env:
SPOTTER_TOKEN: ${{ secrets.SPOTTER_API_TOKEN }}
continue-on-error: true
- name: Run Ansible scan with different inputs
uses: ./
with:
endpoint: https://api.spotter.steampunk.si/api
api_token: ${{ secrets.SPOTTER_API_TOKEN }}
config: tests/config.yml
paths: tests/playbook-with-errors.yml
exclude_values: true
exclude_metadata: true
display_level: error
no_docs_url: true
no_scan_url: true
ansible_version: 2.16
profile: full
skip_checks: E001,E903[fqcn=sensu.sensu_go.user]
enforce_checks: E1300,E1301
continue-on-error: true
- name: Run Ansible scan with username and password (old auth method, without env vars)
uses: ./
with:
username: ${{ secrets.SPOTTER_USERNAME }}
password: ${{ secrets.SPOTTER_PASSWORD }}
continue-on-error: true
- name: Run Ansible scan with username and password (old auth method, with env vars)
uses: ./
env:
SPOTTER_USERNAME: ${{ secrets.SPOTTER_USERNAME }}
SPOTTER_PASSWORD: ${{ secrets.SPOTTER_PASSWORD }}
continue-on-error: true
- name: Run Ansible scan without errors
uses: ./
with:
paths: tests/playbook-no-errors.yml
ansible_version: 2.16
display_level: error
env:
SPOTTER_TOKEN: ${{ secrets.SPOTTER_API_TOKEN }}
- name: Run Ansible scan with debug
uses: ./
with:
endpoint: https://api.spotter.steampunk.si/api
api_token: ${{ secrets.SPOTTER_API_TOKEN }}
paths: tests/playbook-no-errors.yml
debug: true
continue-on-error: true
- name: Run Ansible scan with SARIF output
uses: ./
with:
sarif_file: example.sarif