This is an automated email from the ASF dual-hosted git repository.
lfrolov pushed a commit to branch DATALAB-2409
in repository https://gitbox.apache.org/repos/asf/incubator-datalab.git
The following commit(s) were added to refs/heads/DATALAB-2409 by this push:
new 0b2c554 [DATALAB-2409]: added output to configure_keycloak
0b2c554 is described below
commit 0b2c55406ff1ffc5be904deccd5d91d039cf4af8
Author: leonidfrolov <[email protected]>
AuthorDate: Wed Oct 13 11:25:21 2021 +0300
[DATALAB-2409]: added output to configure_keycloak
---
infrastructure-provisioning/src/base/scripts/configure_keycloak.py | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/infrastructure-provisioning/src/base/scripts/configure_keycloak.py
b/infrastructure-provisioning/src/base/scripts/configure_keycloak.py
index 614b812..d5df582 100644
--- a/infrastructure-provisioning/src/base/scripts/configure_keycloak.py
+++ b/infrastructure-provisioning/src/base/scripts/configure_keycloak.py
@@ -47,8 +47,8 @@ args = parser.parse_args()
##############
if __name__ == "__main__":
try:
- print('[CONFIGURE KEYCLOAK]')
logging.info('[CONFIGURE KEYCLOAK]')
+ print(args)
keycloak_auth_server_url =
'{}/realms/master/protocol/openid-connect/token'.format(
args.keycloak_auth_server_url)
keycloak_auth_data = {
@@ -70,7 +70,6 @@ if __name__ == "__main__":
keycloak_client_id = str(uuid.uuid4())
if args.hostname == '':
keycloak_redirectUris =
'https://{0}/*,http://{0}/*'.format(args.instance_public_ip).lower().split(',')
- print(keycloak_redirectUris)
else:
keycloak_redirectUris =
'https://{0}/*,http://{0}/*,https://{1}/*,http://{1}/*'.format(
args.instance_public_ip, args.hostname).lower().split(',')
@@ -89,10 +88,11 @@ if __name__ == "__main__":
try:
keycloak_token = requests.post(keycloak_auth_server_url,
data=keycloak_auth_data, verify=False).json()
-
+ print(keycloak_token)
keycloak_client = requests.post(keycloak_client_create_url,
json=keycloak_client_data,
headers={"Authorization": "Bearer
" + keycloak_token.get("access_token"),
"Content-Type":
"application/json"}, verify=False)
+ print(keycloak_client)
except Exception as err:
append_result("Failed to configure keycloak.")
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]