mirror of
https://github.com/ansible-collections/hetzner.hcloud
synced 2024-11-10 06:34:13 +00:00
test: ensure location is used for tests (#541)
##### SUMMARY Make sure that the tests uses the `hcloud_location_name` variable for the tests.
This commit is contained in:
parent
0b8b44ec4c
commit
c6d7121e9e
13 changed files with 19 additions and 2 deletions
|
@ -4,5 +4,6 @@
|
||||||
name: "{{ hcloud_server_name }}"
|
name: "{{ hcloud_server_name }}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
state: stopped
|
state: stopped
|
||||||
register: test_server
|
register: test_server
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
name: "{{ hcloud_server_name }}"
|
name: "{{ hcloud_server_name }}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
labels:
|
labels:
|
||||||
firewall: "{{ hcloud_firewall_name }}"
|
firewall: "{{ hcloud_firewall_name }}"
|
||||||
state: stopped
|
state: stopped
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
name: "{{ hcloud_server_name }}"
|
name: "{{ hcloud_server_name }}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
labels:
|
labels:
|
||||||
key: value
|
key: value
|
||||||
state: stopped
|
state: stopped
|
||||||
|
|
|
@ -21,8 +21,8 @@
|
||||||
name: "{{ hcloud_server_name }}"
|
name: "{{ hcloud_server_name }}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
state: stopped
|
|
||||||
location: "{{ hcloud_location_name }}"
|
location: "{{ hcloud_location_name }}"
|
||||||
|
state: stopped
|
||||||
register: main_server
|
register: main_server
|
||||||
- name: verify setup server
|
- name: verify setup server
|
||||||
assert:
|
assert:
|
||||||
|
@ -34,6 +34,7 @@
|
||||||
name: "{{ hcloud_server_name }}2"
|
name: "{{ hcloud_server_name }}2"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
state: stopped
|
state: stopped
|
||||||
register: main_server2
|
register: main_server2
|
||||||
- name: verify setup another server
|
- name: verify setup another server
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
name: "{{ hcloud_server_name }}"
|
name: "{{ hcloud_server_name }}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
state: stopped
|
state: stopped
|
||||||
register: test_server
|
register: test_server
|
||||||
|
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
name: "{{ hcloud_server_name }}"
|
name: "{{ hcloud_server_name }}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
state: stopped
|
state: stopped
|
||||||
register: test_server
|
register: test_server
|
||||||
|
|
||||||
|
|
|
@ -6,8 +6,8 @@
|
||||||
name: "{{hcloud_server_name}}"
|
name: "{{hcloud_server_name}}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
state: stopped
|
|
||||||
location: "{{ hcloud_location_name }}"
|
location: "{{ hcloud_location_name }}"
|
||||||
|
state: stopped
|
||||||
register: server
|
register: server
|
||||||
- name: verify setup server
|
- name: verify setup server
|
||||||
assert:
|
assert:
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
name: "{{ hcloud_server_name }}"
|
name: "{{ hcloud_server_name }}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
state: stopped
|
state: stopped
|
||||||
enable_ipv4: false
|
enable_ipv4: false
|
||||||
enable_ipv6: false
|
enable_ipv6: false
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
name: "{{ hcloud_server_name }}"
|
name: "{{ hcloud_server_name }}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
state: present
|
state: present
|
||||||
register: test_server
|
register: test_server
|
||||||
|
|
||||||
|
|
|
@ -3,6 +3,7 @@
|
||||||
name: "{{ hcloud_server_name }}"
|
name: "{{ hcloud_server_name }}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
state: present
|
state: present
|
||||||
register: result
|
register: result
|
||||||
check_mode: true
|
check_mode: true
|
||||||
|
@ -16,6 +17,7 @@
|
||||||
name: "{{ hcloud_server_name}}"
|
name: "{{ hcloud_server_name}}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
enable_ipv6: False
|
enable_ipv6: False
|
||||||
state: started
|
state: started
|
||||||
register: main_server
|
register: main_server
|
||||||
|
@ -441,6 +443,7 @@
|
||||||
name: "{{ hcloud_server_name}}"
|
name: "{{ hcloud_server_name}}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
ssh_keys:
|
ssh_keys:
|
||||||
- "{{ hcloud_ssh_key_name }}"
|
- "{{ hcloud_ssh_key_name }}"
|
||||||
rescue_mode: "linux64"
|
rescue_mode: "linux64"
|
||||||
|
@ -470,6 +473,7 @@
|
||||||
name: "{{ hcloud_server_name}}"
|
name: "{{ hcloud_server_name}}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
ssh_keys:
|
ssh_keys:
|
||||||
- "{{ hcloud_ssh_key_name }}"
|
- "{{ hcloud_ssh_key_name }}"
|
||||||
labels:
|
labels:
|
||||||
|
@ -563,6 +567,7 @@
|
||||||
rebuild_protection: true
|
rebuild_protection: true
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
ssh_keys:
|
ssh_keys:
|
||||||
- "{{ hcloud_ssh_key_name }}"
|
- "{{ hcloud_ssh_key_name }}"
|
||||||
state: present
|
state: present
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
name: "{{ hcloud_server_name }}"
|
name: "{{ hcloud_server_name }}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
state: stopped
|
state: stopped
|
||||||
labels:
|
labels:
|
||||||
key: value
|
key: value
|
||||||
|
@ -14,6 +15,7 @@
|
||||||
name: "{{ hcloud_server_name }}2"
|
name: "{{ hcloud_server_name }}2"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
state: stopped
|
state: stopped
|
||||||
labels:
|
labels:
|
||||||
key: value
|
key: value
|
||||||
|
|
|
@ -20,5 +20,6 @@
|
||||||
name: "{{ hcloud_server_name }}"
|
name: "{{ hcloud_server_name }}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
state: stopped
|
state: stopped
|
||||||
register: test_server
|
register: test_server
|
||||||
|
|
|
@ -114,6 +114,7 @@
|
||||||
name: "{{ hcloud_server_name }}"
|
name: "{{ hcloud_server_name }}"
|
||||||
server_type: "{{ hcloud_server_type_name }}"
|
server_type: "{{ hcloud_server_type_name }}"
|
||||||
image: "{{ hcloud_image_name }}"
|
image: "{{ hcloud_image_name }}"
|
||||||
|
location: "{{ hcloud_location_name }}"
|
||||||
ssh_keys:
|
ssh_keys:
|
||||||
- "{{ hcloud_ssh_key_name }}"
|
- "{{ hcloud_ssh_key_name }}"
|
||||||
state: started
|
state: started
|
||||||
|
|
Loading…
Reference in a new issue