-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Not able to pass output from earlier step as text #14
Comments
Is this the content of your YAML file? jobs:
your-job:
runs-on: ubuntu-latest
steps:
- name: Read scan results summary
id: scan-results
run: |
SAST_SUMMARY=$(cat sast-summary.txt)
echo "::set-output name=SAST_SUMMARY::${SAST_SUMMARY}"
- name: Send a message to Microsoft Teams
if: ${{ steps.pipeline-scan.outcome == 'failure' }}
uses: aliencube/[email protected]
with:
webhook_uri: ${{env.WEBHOOK_URI}}
title: 'Veracode Pipeline Scan found vulnerabilities in ${{ env.REPOSITORY_NAME }}'
summary: 'Flaws Summary: '
text: 'Flaws text: ${{steps.scan-results.outputs.SAST_SUMMARY}}'
theme_color: a72828
actions: '[{ "@type": "OpenUri", "name": "View Results", "targets": [{ "os": "default", "uri": "https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}" }] }]' (I have added the Do you get any errors? From my experience the workflow files are pretty fragile when it comes to single and double quotes. If your output |
Thanks for your response. I can give a try with double quotes, but then if for some reason SAST_SUMMARY has double quotes, then it will fail again. |
Yup, unfortunately that is something one must be aware of. I think you should opt for either double or single quotes and then take every action you can think of to make sure that the quotes are properly escaped. |
Hello,
I'm trying to read a file and then send it in Text section but it's not working. Here is the sample:
id: scan-results
run: |
SAST_SUMMARY=$(cat sast-summary.txt)
echo "::set-output name=SAST_SUMMARY::${SAST_SUMMARY}"
if: ${{ steps.pipeline-scan.outcome == 'failure' }}
uses: aliencube/[email protected]
with:
webhook_uri: ${{env.WEBHOOK_URI}}
title: 'Veracode Pipeline Scan found vulnerabilities in ${{ env.REPOSITORY_NAME }}'
summary: 'Flaws Summary: '
text: 'Flaws text: ${{steps.scan-results.outputs.SAST_SUMMARY}}'
theme_color: a72828
actions: '[{ "@type": "OpenUri", "name": "View Results", "targets": [{ "os": "default", "uri": "https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}" }] }]'
Am I missing anything? Or this is not supported with the current version?
The text was updated successfully, but these errors were encountered: