microsoft / microsoft/security-devops-action
Error with specifying template analyzer environment variables
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 164
- Forks
- 62
- PR merge metrics
- No merged PRs in 30d
Description
I am trying to use the action to analyze a single template, so I specified env variables that seem to correspond to the usage described in https://github.com/Azure/template-analyzer:
- name: Run Microsoft Security DevOps Analysis
uses: microsoft/security-devops-action@preview
env:
GDN_TEMPLATEANALYZER_VERBOSE: 1
GDN_TEMPLATEANALYZER_ANALYZETEMPLATE: "infra/main.json"
GDN_TEMPLATEANALYZER_PARAMETERSFILEPATH: "infra/main.parameters.json"
id: msdo
with:
tools: templateanalyzer
However that results in a poorly formed command and subsequent error:
Analyze:
Using environment variable override: AnalyzeTemplate=infra/main.json
Using environment variable override: ParametersFilePath=infra/main.parameters.json
Using environment variable override: Verbose=1
Running ARM Template Best Practice Analyzer 0.4.0
------------------------------------------------------------------------------
/home/runner/work/_msdo/packages/nuget/Azure.Templates.Analyzer.CommandLine.linux-x64.0.4.0/tools/TemplateAnalyzer analyze-directory /home/runner/work/simple-fastapi-container/simple-fastapi-container --report-format sarif --output-file-path /home/runner/work/simple-fastapi-container/simple-fastapi-container/.gdn/.r/templateanalyzer/001/templateanalyzer.sarif analyze-template infra/main.json --parameters-file-path infra/main.parameters.json --verbose
Unrecognized command or argument 'analyze-template'
Unrecognized command or argument 'infra/main.json'
analyze-directory:
Unrecognized command or argument '--parameters-file-path'
Unrecognized command or argument 'infra/main.parameters.json'
Here's the full workflow:
https://github.com/pamelafox/simple-fastapi-container/actions/runs/4485952792/jobs/7887991866?pr=6
Can you clarify proper usage?
Thanks!
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the workflow shown in the issue and the templateanalyzer entry point selected by tools: templateanalyzer. Compare the environment-variable-derived arguments with the analyzer's supported command syntax; done means a single-template workflow runs without unrecognized-argument errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github-actions
- Domain
- devops, security
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100