diff --git a/roles/deploy/tasks/setup.yml b/roles/deploy/tasks/setup.yml index b395143..7f131c5 100644 --- a/roles/deploy/tasks/setup.yml +++ b/roles/deploy/tasks/setup.yml @@ -14,18 +14,17 @@ - name: Debug active_path debug: var: active_path + + - name: Handle error if active_path is null + fail: + msg: "The IIS site active path could not be determined." + when: active_path.stdout is null # Chuẩn hóa giá trị của active_path - name: Normalize active_path set_fact: - active_path: "{{ active_path.stdout | default('') | trim }}" - - -# Debug Debug active_path -- name: Debug active_path - debug: - var: active_path + active_path: "{{ active_path.stdout | trim }}" - name: Debug blue_path debug: