Files
ansible-middleware.keycloak/molecule/quarkus_devmode/verify.yml
T
Aleksandr ManginandClaude Opus 5.5 68a1f3d28b molecule: make scenarios work on containerized CI runners
Since the molecule jobs moved to self-hosted container runners, molecule
talks to a Docker daemon that does not share the runner's filesystem or
network namespace:

- quarkus_ha*: drop the postgresql.conf bind mount (the workspace path
  does not exist on the daemon side) and pass listen_addresses via -c
- quarkus, quarkus_devmode: fetch the openid configuration from the
  instance with ansible.builtin.uri instead of curl | jq on the runner,
  and drop the fixed host published_ports that are no longer needed
- quarkus_nohost: add the missing roles symlink

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 09:44:24 +01:00

42 lines
1.6 KiB
YAML

---
- name: Verify
hosts: all
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 we are running on requested JAVA_HOME # noqa blocked_modules command-instead-of-module
ansible.builtin.shell: |
set -o pipefail
ps -ef | grep '/opt/openjdk' | grep -v grep
args:
executable: /bin/bash
changed_when: False
- name: Set internal envvar
ansible.builtin.set_fact:
hera_home: "{{ lookup('env', 'HERA_HOME') }}"
- 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