Skip to content

Commit

Permalink
Fix variable assertions after refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
marcransome committed Sep 27, 2024
1 parent e8f8eb0 commit 0e20236
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions roles/deploy/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,20 +17,15 @@
- scripts_artifact_path is defined and scripts_artifact_path | trim | length > 0
msg: "Required variable(s) empty or undefined"

- name: Check valid combination of services for deployment
ansible.builtin.fail:
msg: Deploy 'ois' services exclusively, or any combination of 'ceu', 'xml' or 'publ', not both
when: tuxedo_service | length > 1 and 'ois' in tuxedo_service

- name: Check valid combination of services for development or staging environment
ansible.builtin.fail:
msg: Cannot deploy services other than 'ois' to this environment
when: environment_name != "live" and "ois" not in tuxedo_service
when: environment_name != "live" and tuxedo_service != "ois"

- name: Check valid combination of services for live
ansible.builtin.fail:
msg: Cannot deploy 'ois' services to live; this is intended for development or staging only
when: environment_name == "live" and "ois" in tuxedo_service
when: environment_name == "live" and tuxedo_service == "ois"

- name: Set common Tuxedo fact for domain suffix
ansible.builtin.set_fact:
Expand Down

0 comments on commit 0e20236

Please sign in to comment.