Skip to content

Instantly share code, notes, and snippets.

@dan1
Last active August 29, 2015 14:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dan1/70a8fdde98d09a7f7476 to your computer and use it in GitHub Desktop.
Save dan1/70a8fdde98d09a7f7476 to your computer and use it in GitHub Desktop.
curl commands for Cloud Admin account
curl -i \
-X POST \
-H "Content-Type: application/json" \
-d '{
"auth": {
"id": "bd7213bbaf6341f3bcc821e4ad052384",
"passwordCredentials": {
"username": "admin",
"password": "pass"
}
}
}' \
http://192.168.85.125:5000/v2.0/tokens
curl -s -H "X-Auth-Token: 2d9679ebd24949f092c4cfb23584e774" -X PUT http://192.168.85.125:5000/v3/domains/default/users/0b4a5067f39945af9c30a2ce230cb409/roles/c3d7c0bd57e84babaf9d8c8a3d317118
(v2 admin token) (domain) (admin tenant_id) (admin role)
curl -i -H "Content-Type: application/json" \
-d '
{ "auth": {
"identity": {
"methods": ["password"],
"password": {
"user": {
"name": "admin",
"domain": { "id": "default" },
"password": "pass"
}
}
},
"scope": {
"domain": {
"id": "default"
}
}
}
}' \
http://192.168.85.125:5000/v3/auth/tokens ; echo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment