Skip to content

Commit

Permalink
oradb_facts: Skip oracledb_facts when db not reachable
Browse files Browse the repository at this point in the history
  • Loading branch information
Rendanic committed Nov 25, 2023
1 parent 18eea18 commit 7703157
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
3 changes: 3 additions & 0 deletions changelogs/fragments/dbfacts.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
minor_changes:
- "oradb_facts: Skip oracledb_facts when db not reachable (oravirt#387)"
2 changes: 2 additions & 0 deletions roles/oradb_facts/tasks/db_facts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@
ansible.builtin.set_fact:
cacheable: true
oracledb_facts: "{{ oracledb_facts | default({}) | combine(_db_facts | items2dict) }}"
when:
- ansible_facts['version'] is defined
vars:
_db_facts:
- key: "{{ odb[0]['oracle_db_unique_name'] | default(odb[0]['oracle_db_name']) }}"
Expand Down

0 comments on commit 7703157

Please sign in to comment.