mirror of
https://github.com/ansible-middleware/keycloak.git
synced 2025-07-29 08:01:33 -07:00
refactor offline install, rhsso patch install
This commit is contained in:
parent
11fb2cc43b
commit
906ba3c577
5 changed files with 20 additions and 16 deletions
|
@ -5,19 +5,14 @@
|
|||
- keycloak_rhsso_enable
|
||||
quiet: true
|
||||
|
||||
- set_fact:
|
||||
rhn_download_url: "{{ keycloak_rhsso_base_url }}{{ rhsso_rhn_id }}"
|
||||
when:
|
||||
- rhsso_rhn_id is defined
|
||||
|
||||
- name: "Check zipfile dest directory {{ zipfile_dest }}"
|
||||
stat:
|
||||
path: "{{ zipfile_dest }}"
|
||||
register: archive_path
|
||||
|
||||
- name: "Download zipfile from RHN: {{ rhn_download_url }}"
|
||||
- name: "Download zipfile from RHN: {{ keycloak_rhsso_download_url }}"
|
||||
redhat_csp_download:
|
||||
url: "{{ rhn_download_url }}"
|
||||
url: "{{ keycloak_rhsso_download_url }}"
|
||||
dest: "{{ zipfile_dest }}"
|
||||
username: "{{ rhn_username }}"
|
||||
password: "{{ rhn_password }}"
|
||||
|
|
|
@ -10,11 +10,11 @@
|
|||
- name: Validate credentials
|
||||
assert:
|
||||
that:
|
||||
- (rhn_username is defined and rhsso_rhn_id is defined) or rhsso_rhn_id is not defined
|
||||
- (rhn_password is defined and rhsso_rhn_id is defined) or rhsso_rhn_id is not defined
|
||||
- (rhn_username is defined and keycloak_rhsso_enable) or not keycloak_rhsso_enable or keycloak_offline_install
|
||||
- (rhn_password is defined and keycloak_rhsso_enable) or not keycloak_rhsso_enable or keycloak_offline_install
|
||||
quiet: True
|
||||
fail_msg: "Cannot install Red Hat SSO without RHN credentials. Check rhn_username and rhn_password are defined"
|
||||
success_msg: "{{ 'Installing Red Hat Single Sign-On' if rhsso_rhn_id is defined else 'Installing keycloak.org' }}"
|
||||
success_msg: "{{ 'Installing Red Hat Single Sign-On' if keycloak_rhsso_enable else 'Installing keycloak.org' }}"
|
||||
|
||||
- name: Set required packages facts
|
||||
set_fact:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue