--- - name: Verify hosts: all vars: keycloak_quarkus_bootstrap_admin_user: "remembertochangeme" keycloak_uri: "http://localhost:{{ 8080 + ( keycloak_jboss_port_offset | default(0) ) }}" keycloak_management_port: "http://localhost:{{ 9990 + ( keycloak_jboss_port_offset | default(0) ) }}" keycloak_jboss_port_offset: 10 tasks: - name: Populate service facts ansible.builtin.service_facts: - name: Check if keycloak service started ansible.builtin.assert: that: - ansible_facts.services["keycloak.service"]["state"] == "running" - ansible_facts.services["keycloak.service"]["status"] == "enabled" - name: Verify openid config block: - name: Fetch openID config ansible.builtin.uri: url: http://localhost:8080/realms/master/.well-known/openid-configuration register: openid_config - name: Verify endpoint URLs ansible.builtin.assert: that: - openid_config.json["backchannel_authentication_endpoint"] == 'http://localhost:8080/realms/master/protocol/openid-connect/ext/ciba/auth' - openid_config.json['issuer'] == 'http://localhost:8080/realms/master' - openid_config.json['authorization_endpoint'] == 'http://localhost:8080/realms/master/protocol/openid-connect/auth' - openid_config.json['token_endpoint'] == 'http://localhost:8080/realms/master/protocol/openid-connect/token' when: - hera_home is defined - hera_home | length == 0