Created
November 11, 2023 12:25
-
-
Save 3ng1n33r/e5daea627b49d7306429c8672d4c1daa to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
vault write auth/jwt/role/myproject-staging - <<EOF | |
{ | |
"role_type": "jwt", | |
"policies": ["myproject-staging"], | |
"token_explicit_max_ttl": 60, | |
"user_claim": "user_email", | |
"bound_claims": { | |
"project_id": "51459829", | |
"ref": "staging*", | |
"ref_type": "branch" | |
} | |
} | |
EOF | |
vault write auth/jwt/role/myproject-production - <<EOF | |
{ | |
"role_type": "jwt", | |
"policies": ["myproject-production"], | |
"token_explicit_max_ttl": 60, | |
"user_claim": "user_email", | |
"bound_claims_type": "glob", | |
"bound_claims": { | |
"project_id": "51459829", | |
"ref_protected": "true", | |
"ref_type": "branch", | |
"ref": "main" | |
} | |
} | |
EOF |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment