Created
January 26, 2017 15:18
-
-
Save mafonso/43a9ebdd78c2975c05790f4d9f249c23 to your computer and use it in GitHub Desktop.
This file contains 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
On Vault: | |
$ vault auth-enable aws-ec2 | |
Successfully enabled 'aws-ec2' at 'aws-ec2'! | |
vault write auth/aws-ec2/role/instance-worker bound_iam_role_arn=arn:aws:iam::000000000000:role/instance-nomad max_ttl=500h | |
bound_iam_role_arn | |
#Login | |
#vault auth | |
curl -X POST -d '{"role":"nomad-role","pkcs7":"'$(curl -s http://169.254.169.254/latest/dynamic/instance-identity/pkcs7 | tr -d '\n')'"}' | |
#Token Create | |
#vault token-create -role nomad-server | |
curl -X POST -H "X-Vault-Token:$VAULT_TOKEN" "https://vault.internal.domain:8200/v1/auth/token/create/nomad-server" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment