3 Commits

Author SHA1 Message Date
Matthew Fernandez
3400e73675 Rename Windows ec2 instance for #235 (#236)
pushed the EE's, merging
2025-04-29 13:05:13 -06:00
Todd Ruch
0b1904e727 Updated Windows job templates to use the Product Demos EE (#231)
Co-authored-by: Todd Ruch <truch@redhat.com>
2025-03-19 16:48:08 -04:00
Todd Ruch
53b180d43e Updated to include the available chart versions and add an instance deployment message (#230)
Co-authored-by: Todd Ruch <truch@redhat.com>
2025-03-12 14:28:47 -06:00
9 changed files with 54 additions and 9 deletions

View File

@@ -283,7 +283,7 @@ controller_workflows:
- identifier: Deploy Windows GUI Blueprint
unified_job_template: Cloud / AWS / Create VM
extra_data:
create_vm_vm_name: aws_dc
create_vm_vm_name: aws-dc
vm_blueprint: windows_full
success_nodes:
- Update Inventory

View File

@@ -285,4 +285,6 @@ controller_notifications:
http_method: POST
headers: {}
...
controller_settings:
- name: SESSION_COOKIE_AGE
value: 180000

View File

@@ -3,9 +3,10 @@ version: 3
images:
base_image:
name: registry.redhat.io/ansible-automation-platform-25/ee-minimal-rhel9:latest
dependencies:
galaxy: requirements-25.yml
system:
- python3.11-devel [platform:rpm]
python:
- pywinrm>=0.4.3
python_interpreter:

View File

@@ -27,6 +27,8 @@ collections:
- name: redhat.rhel_system_roles
version: ">=1.23.0"
# windows demos
- name: microsoft.ad
version: "1.9"
- name: ansible.windows
version: ">=2.3.0"
- name: chocolatey.chocolatey

View File

@@ -20,6 +20,8 @@ collections:
- name: redhat.rhel_system_roles
version: ">=1.23.0"
# windows
- name: microsoft.ad
version: "1.9"
- name: ansible.windows
version: ">=2.3.0"
- name: chocolatey.chocolatey

View File

@@ -101,6 +101,21 @@
retries: 10
delay: 30
- name: Get available charts from gitlab operator repo
register: gitlab_chart_versions
ansible.builtin.uri:
url: https://gitlab.com/gitlab-org/cloud-native/gitlab-operator/-/raw/master/CHART_VERSIONS?ref_type=heads
method: GET
return_content: true
- name: Debug gitlab_chart_versions
ansible.builtin.debug:
var: gitlab_chart_versions.content | from_yaml
- name: Get latest chart from available_chart_versions
ansible.builtin.set_fact:
gitlab_chart_version: "{{ (gitlab_chart_versions.content | split())[0] }}"
- name: Grab url for Gitlab spec
ansible.builtin.set_fact:
cluster_domain: "apps{{ lookup('ansible.builtin.env', 'K8S_AUTH_HOST') | regex_search('\\.[^:]*') }}"
@@ -133,3 +148,20 @@
route.openshift.io/termination: "edge"
certmanager-issuer:
email: "{{ cert_email | default('nobody@nowhere.nosite') }}"
- name: Print out warning and initial details about deployment
vars:
msg: |
If not immediately successful be aware that the Gitlab instance can take
a couple minutes to come up, so be patient.
URL for Gitlab instance:
https://gitlab.{{ cluster_domain }}
The initial login user is 'root', and the password can be found by logging
into the OpenShift cluster portal, and on the left hand side of the administrator
portal, under workloads, select Secrets and look for 'gitlab-gitlab-initial-root-password'
ansible.builtin.debug:
msg: "{{ msg.split('\n') }}"
...

View File

@@ -12,14 +12,17 @@
- name: Update the hostname
ansible.windows.win_hostname:
name: "{{ inventory_hostname.split('.')[0] }}"
register: r_rename_hostname
- name: Reboot to apply new hostname
# noqa no-handler
when: r_rename_hostname is changed
ansible.windows.win_reboot:
reboot_timeout: 3600
- name: Create new domain in a new forest on the target host
register: r_create_domain
ansible.windows.win_domain:
microsoft.ad.domain:
dns_domain_name: ansible.local
safe_mode_password: "{{ lookup('community.general.random_string', min_lower=1, min_upper=1, min_special=1, min_numeric=1) }}"
@@ -30,7 +33,7 @@
file: tasks/domain_services_check.yml
- name: Create some groups
community.windows.win_domain_group:
microsoft.ad.group:
name: "{{ item.name }}"
scope: global
loop:
@@ -41,7 +44,7 @@
delay: 10
- name: Create some users
community.windows.win_domain_user:
microsoft.ad.user:
name: "{{ item.name }}"
groups: "{{ item.groups }}"
password: "{{ lookup('community.general.random_string', min_lower=1, min_upper=1, min_special=1, min_numeric=1) }}"

View File

@@ -5,6 +5,12 @@
report_server: aws_win1
tasks:
- name: Assert that host is in webservers group
ansible.builtin.assert:
that: "'{{ report_server }}' in groups.os_windows"
msg: "Please run the 'Deploy Cloud Stack in AWS' Workflow Job Template first"
- name: Patch windows server
ansible.builtin.include_role:
name: demo.patching.patch_windows

View File

@@ -40,7 +40,6 @@ controller_templates:
inventory: "Demo Inventory"
project: "Ansible Product Demos"
playbook: "windows/patching.yml"
execution_environment: Default execution environment
notification_templates_started: Telemetry
notification_templates_success: Telemetry
notification_templates_error: Telemetry
@@ -86,7 +85,6 @@ controller_templates:
inventory: "Demo Inventory"
project: "Ansible Product Demos"
playbook: "windows/rollback.yml"
execution_environment: Default execution environment
notification_templates_started: Telemetry
notification_templates_success: Telemetry
notification_templates_error: Telemetry
@@ -111,7 +109,6 @@ controller_templates:
inventory: "Demo Inventory"
project: "Ansible Product Demos"
playbook: "windows/connect.yml"
execution_environment: Default execution environment
notification_templates_started: Telemetry
notification_templates_success: Telemetry
notification_templates_error: Telemetry