File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change 22
22
- name : Generate SSH client certificate
23
23
if : github.ref == 'refs/heads/main'
24
24
id : ssh_cert
25
- uses : andreaso/vault-oidc-ssh-cert-action@v0.6
25
+ uses : andreaso/vault-oidc-ssh-cert-action@v0.7
26
26
with :
27
27
vault_server : https://vault.example.com:8200
28
28
oidc_backend : github-oidc
Original file line number Diff line number Diff line change 50
50
shell : python
51
51
52
52
- name : Authenticate towards Vault
53
+ id : vault_auth
53
54
uses : hashicorp/vault-action@v2.7.0
54
55
with :
55
56
method : jwt
@@ -58,20 +59,20 @@ runs:
58
59
url : ${{ inputs.vault_server }}
59
60
path : ${{ inputs.oidc_backend }}
60
61
role : ${{ inputs.oidc_role }}
61
- exportToken : true
62
+ outputToken : true
62
63
63
64
- name : Generate and sign SSH client certificate
64
65
id : generator
65
66
shell : bash
66
67
run : ${{ github.action_path }}/generate-and-sign
67
68
env :
68
69
VAULT_SERVER : ${{ inputs.vault_server }}
70
+ VAULT_TOKEN : ${{ steps.vault_auth.outputs.vault_token }}
69
71
SSH_BACKEND : ${{ inputs.ssh_backend }}
70
72
SSH_ROLE : ${{ inputs.ssh_role }}
71
73
RUNNER_TEMP : ${{ runner.temp }}
72
74
73
75
- name : Revoke Vault token
74
76
shell : bash
75
77
run : |
76
- curl --fail --silent --show-error --header "X-Vault-Token: $VAULT_TOKEN" --data "" "${{ inputs.vault_server }}/v1/auth/token/revoke-self"
77
- echo "VAULT_TOKEN=revoked" >> "$GITHUB_ENV"
78
+ curl --fail --silent --show-error --header "X-Vault-Token: ${{ steps.vault_auth.outputs.vault_token }}" --data "" "${{ inputs.vault_server }}/v1/auth/token/revoke-self"
You can’t perform that action at this time.
0 commit comments