-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcreate_ci.yml
More file actions
29 lines (26 loc) · 844 Bytes
/
Copy pathcreate_ci.yml
File metadata and controls
29 lines (26 loc) · 844 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
---
- name: creating a cmdb record
hosts: localhost
gather_facts: no
tasks:
- name: Create a configuration item
register: server_info
servicenow.itsm.configuration_item:
name: "{{ my_server }}"
state: present
short_description: Ansible Automation Platfrom demo
serial_number: "{{ my_instance_id }}"
asset_tag: "{{ my_ami_id }}"
sys_class_name: cmdb_ci_linux_server
assigned_to: hercules
environment: production
install_status: installed
category: Hardware
other:
model_number: "{{ my_instance_type }}"
assignment_group: "Ansible West Tigers"
ip_address: "{{ my_public_ip }}"
operational_status: operational
- name: print the result
ansible.builtin.debug:
var: server_info