-
Notifications
You must be signed in to change notification settings - Fork 164
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* The ome_application_network_webserver module allows the configuration of the network web server. * The ome_application_network_time module allows the configuration of network time. * The module ome_application_network_address is updated to include the following: - A specific NIC can be selected in case of multiple NICs, - A NIC can be enabled or disabled using the option enable_nic, - Support for the configuration of a management vLAN. * The module idrac_firmware is enhanced to support FQDN input format for share details. Co-Authored-By: Felix Stephen <[email protected]> Co-Authored-By: Sajna Shetty <[email protected]>
- Loading branch information
1 parent
5839034
commit 077fba1
Showing
39 changed files
with
2,504 additions
and
402 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
60 changes: 60 additions & 0 deletions
60
examples/ome/application/ome_application_network_address_with_job_tracking.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
--- | ||
- hosts: hosts | ||
vars: | ||
retries_count: 50 | ||
polling_interval: 5 # in seconds | ||
connection: local | ||
name: OME - Complete network settings with details tracking | ||
gather_facts: False | ||
|
||
tasks: | ||
- name: Complete network settings | ||
ome_application_network_address: | ||
hostname: "{{hostname}}" | ||
username: "{{username}}" | ||
password: "{{password}}" | ||
ipv4_configuration: | ||
enable: true | ||
enable_dhcp: false | ||
static_ip_address: 192.168.0.2 | ||
static_subnet_mask: 255.255.254.0 | ||
static_gateway: 192.168.0.3 | ||
use_dhcp_for_dns_server_names: false | ||
static_preferred_dns_server: 192.168.0.4 | ||
static_alternate_dns_server: 192.168.0.5 | ||
ipv6_configuration: | ||
enable: true | ||
enable_auto_configuration: true | ||
static_ip_address: 2626:f2f2:f081:9:1c1c:f1f1:4747:1 | ||
static_prefix_length: 10 | ||
static_gateway: 2626:f2f2:f081:9:1c1c:f1f1:4747:2 | ||
use_dhcp_for_dns_server_names: true | ||
static_preferred_dns_server: 2626:f2f2:f081:9:1c1c:f1f1:4747:3 | ||
static_alternate_dns_server: 2626:f2f2:f081:9:1c1c:f1f1:4747:4 | ||
dns_configuration: | ||
register_with_dns: true | ||
use_dhcp_for_dns_domain_name: false | ||
dns_name: "MX-SVCTAG" | ||
dns_domain_name: "localdomainname" | ||
reboot_delay: 1 | ||
register: facts_result | ||
|
||
# To end play when no job_info | ||
- name: "End the play when no job_info" | ||
meta: end_play | ||
when: | ||
- facts_result.changed == false | ||
- "'job_info' not in facts_result" | ||
|
||
- name: "Get job details using job id from network address config task." | ||
ome_job_info: | ||
hostname: "{{ hostname }}" | ||
username: "{{ username }}" | ||
password: "{{ password }}" | ||
job_id: "{{ facts_result.job_info.Id }}" | ||
register: job_result | ||
failed_when: job_result.job_info.LastRunStatus.Name == 'Failed' | ||
changed_when: job_result.job_info.LastRunStatus.Name == 'Completed' | ||
until: job_result.job_info.LastRunStatus.Name == 'Completed' or job_result.job_info.LastRunStatus.Name == 'Failed' | ||
retries: "{{ retries_count }}" | ||
delay: "{{ polling_interval }}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
--- | ||
- hosts: hosts | ||
connection: local | ||
name: Dell OpenManage Ansible Application network time setting. | ||
gather_facts: False | ||
|
||
tasks: | ||
- name: Configure system time. | ||
ome_application_network_time: | ||
hostname: "{{hostname}}" | ||
username: "{{username}}" | ||
password: "{{password}}" | ||
enable_ntp: false | ||
system_time: "2020-03-31 21:35:18" | ||
time_zone: "TZ_ID_11" | ||
tags: time_setting1 | ||
|
||
- name: Configure NTP server for time synchronization. | ||
ome_application_network_time: | ||
hostname: "{{hostname}}" | ||
username: "{{username}}" | ||
password: "{{password}}" | ||
time_zone: "TZ_ID_66" | ||
enable_ntp: true | ||
primary_ntp_address: "192.168.0.2" | ||
secondary_ntp_address1: "192.168.0.3" | ||
secondary_ntp_address2: "192.168.0.4" | ||
tags: time_setting2 |
29 changes: 29 additions & 0 deletions
29
examples/ome/application/ome_application_network_time_zone_info.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
--- | ||
- | ||
connection: local | ||
gather_facts: false | ||
hosts: hosts | ||
name: "Ome application network time zone informaion - Ansible Module" | ||
vars: | ||
time_zone_uri: "/api/ApplicationService/Network/TimeZones" | ||
|
||
tasks: | ||
- name: "Get list of all available times zones along with information specific to each time zone." | ||
uri: | ||
url: "https://{{ baseuri }}{{ time_zone_uri }}" | ||
user: "{{ username }}" | ||
password: "{{ password }}" | ||
method: "GET" | ||
use_proxy: yes | ||
status_code: 200 | ||
validate_certs: no | ||
force_basic_auth: yes | ||
register: time_zone_result | ||
failed_when: "'value' not in time_zone_result.json" | ||
|
||
- name: Get specific time zone ID using time zone name | ||
with_items: | ||
- "{{ time_zone_result.json.value }}" | ||
debug: | ||
msg: "{{item['Id']}}" | ||
when: item['Name']=='(GMT+05:30) Sri Jayawardenepura' |
34 changes: 34 additions & 0 deletions
34
examples/ome/application/ome_application_network_webserver.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
--- | ||
- hosts: hosts | ||
connection: local | ||
name: Dell OME Application network webserver settings. | ||
gather_facts: False | ||
|
||
tasks: | ||
- name: Update webserver port and session time out configuration. | ||
ome_application_network_webserver: | ||
hostname: "{{ hostname }}" | ||
username: "{{ username }}" | ||
password: "{{ password }}" | ||
webserver_port: 443 | ||
webserver_timeout: 10 | ||
tags: | ||
- port_timeout_update | ||
|
||
- name: Update session time out | ||
ome_application_network_webserver: | ||
hostname: "{{ hostname }}" | ||
username: "{{ username }}" | ||
password: "{{ password }}" | ||
webserver_timeout: 30 | ||
tags: | ||
- timeout_update | ||
|
||
- name: Update web server port. | ||
ome_application_network_webserver: | ||
hostname: "{{ hostname }}" | ||
username: "{{ username }}" | ||
password: "{{ password }}" | ||
webserver_port: 8443 | ||
tags: | ||
- port_update |
57 changes: 57 additions & 0 deletions
57
examples/ome/application/ome_application_network_webserver_port_changed_tracking.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
--- | ||
- hosts: hosts | ||
connection: local | ||
name: "Dell OME Application network webserver port change and track web | ||
server till the service restarts." | ||
gather_facts: False | ||
vars: | ||
# 5 minutes wait max | ||
retries_count: 30 | ||
polling_interval: 10 | ||
webserver_uri: "/api/ApplicationService/Network/WebServerConfiguration" | ||
|
||
tasks: | ||
# Update web server configuration | ||
- name: Update webserver port and timeout of OME | ||
ome_application_network_webserver: | ||
hostname: "{{hostname}}" | ||
username: "{{username}}" | ||
password: "{{password}}" | ||
port: "{{ ome_webserver_port }}" | ||
webserver_port: "{{ new_port }}" | ||
webserver_timeout: 21 | ||
register: result | ||
|
||
# To end play when no port change or failure | ||
- name: "End the play when no port change" | ||
meta: end_play | ||
when: | ||
- result.changed == false | ||
- "'webserver_configuration' not in result" | ||
|
||
# Loop till OME webserver is active by using the new port and webserver config GET call | ||
- name: "Pause play until webserver URL is reachable from this host with new port" | ||
uri: | ||
url: "https://{{ hostname }}:{{ result.webserver_configuration.PortNumber | ||
}}{{ webserver_uri }}" | ||
user: "{{ username }}" | ||
password: "{{ password }}" | ||
method: "GET" | ||
use_proxy: yes | ||
return_content: yes | ||
validate_certs: no | ||
force_basic_auth: yes | ||
headers: | ||
Content-Type: "application/json" | ||
Accept: "application/json" | ||
register: webport_result | ||
until: "'PortNumber' in webport_result or webport_result.status == 200" | ||
retries: "{{ retries_count }}" | ||
delay: "{{ polling_interval }}" | ||
|
||
# Output the webserver_configuration values to be used further | ||
- name: "Output the webserver config" | ||
vars: | ||
webserver_configuration: "{{ webport_result.json }}" | ||
debug: | ||
var: webserver_configuration |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.