Skip to content

Commit

Permalink
Only "force" Token revoke on cert generation failure
Browse files Browse the repository at this point in the history
No point in attempting to revoke a Vault Token which was never
successfully issued.
  • Loading branch information
andreaso committed Nov 18, 2023
1 parent 4af3dbb commit d906165
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ runs:
TMPDIR: ${{ runner.temp }}

- name: Revoke Vault token
if: success() || failure()
if: success() || steps.generator.conclusion == 'failure'
shell: bash
run: |
curl --fail --silent --show-error --header "X-Vault-Token: ${VAULT_TOKEN}" --data "" "${VAULT_SERVER}/v1/auth/token/revoke-self"
Expand Down

0 comments on commit d906165

Please sign in to comment.