-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcavn1.yml
More file actions
30 lines (28 loc) · 867 Bytes
/
cavn1.yml
File metadata and controls
30 lines (28 loc) · 867 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
30
---
- name: BUILDING THE AZURE NETWORK
connection: local
gather_facts: no
hosts: all
tasks:
- name: CREATING VIRTUAL NETWORK
azure_rm_virtualnetwork:
name: "{{ my_vm_name }}-VN"
state: present
resource_group: MyResourceGroup
subscription_id: "{{ my_subscription_id }}"
client_id: "{{ my_client_id }}"
secret: "{{ my_secret }}"
tenant: "{{ my_tenant }}"
address_prefixes_cidr: "10.1.0.0/16"
dns_servers: "8.8.8.8"
- name: CREATING SUBNET
azure_rm_subnet:
subscription_id: "{{ my_subscription_id }}"
client_id: "{{ my_client_id }}"
secret: "{{ my_secret }}"
tenant: "{{ my_tenant }}"
name: "{{ my_vm_name }}-SN"
state: present
virtual_network_name: "{{ my_vm_name }}-VN"
resource_group: MyResourceGroup
address_prefix_cidr: "10.1.18.0/24"