Skip to content

Commit

Permalink
Merge pull request #18 from p3ck/main-fixes
Browse files Browse the repository at this point in the history
Minor fixes
  • Loading branch information
p3ck authored Dec 18, 2024
2 parents a3ba954 + 7ffb754 commit eeb7ed1
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 11 deletions.
2 changes: 1 addition & 1 deletion extensions/patterns/manage_service/setup.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ controller_templates:
- infra.windows_ops
- manage_service_pattern
- run_manage_service
playbook: "extensions/patterns/manage_service/playbooks/run_manage_service.yml' }}"
playbook: "extensions/patterns/manage_service/playbooks/run_manage_service.yml"
project: Windows Operations / Project
survey_enabled: true
survey_spec: "{{ lookup('file', pattern.path.replace('setup.yml', '') + 'template_surveys/manage_service.yml') | from_yaml }}"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ spec:
question_description: "Set the startup mode for the Service"
required: false
variable: "service_start_mode"
type: "multplechoice"
type: "multiplechoice"
choices:
- "auto"
- "delayed"
Expand Down
2 changes: 1 addition & 1 deletion extensions/patterns/manage_updates/setup.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ controller_templates:
- infra.windows_ops
- manage_updates_pattern
- run_manage_updates
playbook: "extensions/patterns/manage_updates/playbooks/run_manage_updates.yml' }}"
playbook: "extensions/patterns/manage_updates/playbooks/run_manage_updates.yml"
project: Windows Operations / Project
survey_enabled: true
survey_spec: "{{ lookup('file', pattern.path.replace('setup.yml', '') + 'template_surveys/manage_updates.yml') | from_yaml }}"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,8 @@ spec:
- "Tools"
- "UpdateRollups"
- "Updates"
default:
- "CriticalUpdates"
- "SecurityUpdates"
default: "CriticalUpdates\nSecurityUpdates"
required: true

- type: "multiplechoice"
question_name: "Reboot after install?"
Expand All @@ -29,7 +28,8 @@ spec:
choices:
- "Yes"
- "No"
default: Yes
default: "Yes"
required: false

- type: "multiplechoice"
question_name: "Install updates, download or just search for updates?"
Expand All @@ -40,3 +40,4 @@ spec:
- "searched"
- "downloaded"
default: "searched"
required: true
12 changes: 9 additions & 3 deletions roles/windows_manage_iis/tasks/create.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@

- name: Reboot when Web-Server feature requires it
ansible.windows.win_reboot:
test_command: '(Get-Service -Name Netlogon).Status -ne "Running"'
when: windows_manage_iis_output.reboot_required

- name: Create site directory structure
Expand All @@ -26,10 +25,17 @@
ansible.builtin.set_fact:
windows_manage_iis_results: "{{ windows_manage_iis_results | default({}) | combine({'win_file': windows_manage_iis_output}) }}"

- name: Delete Default Site
- name: Check for existing site
ansible.windows.win_powershell:
script: |
Get-Website
register: powershell_result

- name: Delete existing Site
community.windows.win_iis_website:
name: "Default Web Site"
name: "{{ item.name }}"
state: absent
loop: "{{ powershell_result.output }}"

- name: Create IIS site
community.windows.win_iis_website:
Expand Down
1 change: 0 additions & 1 deletion roles/windows_manage_updates/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@

- name: Reboot when required and requested
ansible.windows.win_reboot:
test_command: '(Get-Service -Name Netlogon).Status -ne "Running"'
when:
- windows_manage_updates_output.reboot_required
- windows_manage_updates_reboot_server
Expand Down

0 comments on commit eeb7ed1

Please sign in to comment.