# action.yml
name: 'Fixinator Action'
author: 'Foundeo Inc.'
description: 'Scans your code for CFML / ColdFusion security issues.'
branding:
  icon: 'check-square'
  color: 'green'
inputs:
  fixinator_api_key:  # id of input
    description: 'The fixinator api key'
    required: true
    default: ''
  path:
    description: 'The file, folder, or file globber pattern to scan'
    default: '.'
  confidence:
    description: 'The confidence level: high, medium or low'
    default: 'high'
  severity:
    description: 'Possible values are: low, medium or high. Filter by severity of the issues found.'
    default: 'low'
  ignorePaths:
    description: 'A file globber pattern of paths to ignore from the scan.'
    default: ''
  failOnIssues:
    description: 'Set to false if you do not want a failing scan to fail the workflow'
    default: 'true'

runs:
  using: 'docker'
  image: 'docker://ghcr.io/foundeo/fixinator-docker/fixinator:latest'
  env:
    FIXINATOR_API_KEY: ${{ inputs.fixinator_api_key }}
  entrypoint: /opt/box/box
  args: 
    - fixinator
    - path=${{ inputs.path }}
    - confidence=${{ inputs.confidence }}
    - severity=${{ inputs.severity }}
    - ignorePaths=${{ inputs.ignorePaths }}
    - failOnIssues=${{ inputs.failOnIssues }}