framework
This commit is contained in:
parent
60fe08f754
commit
e8436e6540
2
main.py
2
main.py
|
@ -1,7 +1,9 @@
|
||||||
import ng_openstack.auth
|
import ng_openstack.auth
|
||||||
|
import ng_openstack.keystone
|
||||||
import os
|
import os
|
||||||
|
|
||||||
token = ng_openstack.auth.getToken(os.getenv("OS_USERNAME"), os.getenv("OS_PASSWORD"),
|
token = ng_openstack.auth.getToken(os.getenv("OS_USERNAME"), os.getenv("OS_PASSWORD"),
|
||||||
os.getenv("OS_USER_DOMAIN_NAME"), os.getenv("OS_USER_DOMAIN_NAME"),
|
os.getenv("OS_USER_DOMAIN_NAME"), os.getenv("OS_USER_DOMAIN_NAME"),
|
||||||
os.getenv("OS_PROJECT_ID"))
|
os.getenv("OS_PROJECT_ID"))
|
||||||
print(token)
|
print(token)
|
||||||
|
print (ng_openstack.keystone.getCatalog())
|
|
@ -8,3 +8,8 @@ def getAllProjects():
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
def getCatalog():
|
||||||
|
catalogData=ng_openstack.openstackRequest.openstackRequest("GET", "v3/endpoints", "",
|
||||||
|
os.getenv("OS_AUTH_URL")).json()
|
||||||
|
return catalogData
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue