mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-25 11:51:26 -07:00
Examples syntax batch6 (#5623)
* Change example syntax on os_auth module * Change example syntax on os_client_config module * Change example syntax on os_image_facts module * Change example syntax on os_networks_facts module * Change example syntax on os_nova_flavor module * Change example syntax on os_object module * Change example syntax on os_server module * Change example syntax on os_subnet_facts module * Change example syntax on rax_files module * Change example syntax on rax_files_objects module * Change example syntax on mysql_db module * Change example syntax on file module * Change example syntax on uri module * Change example syntax on cl_bond module * Change example syntax on cl_bridge module * Change example syntax on cl_img_install module * Change example syntax on cl_interface module * Change example syntax on cl_license module * Change example syntax on cl_ports module * Remove trailing colon
This commit is contained in:
parent
4c3f8cbd92
commit
895179929c
19 changed files with 456 additions and 318 deletions
|
@ -205,12 +205,11 @@ requirements:
|
|||
'''
|
||||
|
||||
EXAMPLES = '''
|
||||
# Creates a new instance and attaches to a network and passes metadata to
|
||||
# the instance
|
||||
- os_server:
|
||||
- name: Create a new instance and attaches to a network and passes metadata to the instance
|
||||
os_server:
|
||||
state: present
|
||||
auth:
|
||||
auth_url: https://region-b.geo-1.identity.hpcloudsvc.com:35357/v2.0/
|
||||
auth_url: 'https://region-b.geo-1.identity.hpcloudsvc.com:35357/v2.0/'
|
||||
username: admin
|
||||
password: admin
|
||||
project_name: admin
|
||||
|
@ -226,99 +225,98 @@ EXAMPLES = '''
|
|||
hostname: test1
|
||||
group: uge_master
|
||||
|
||||
# Creates a new instance in HP Cloud AE1 region availability zone az2 and
|
||||
# Create a new instance in HP Cloud AE1 region availability zone az2 and
|
||||
# automatically assigns a floating IP
|
||||
- name: launch a compute instance
|
||||
hosts: localhost
|
||||
tasks:
|
||||
- name: launch an instance
|
||||
os_server:
|
||||
state: present
|
||||
auth:
|
||||
auth_url: https://region-b.geo-1.identity.hpcloudsvc.com:35357/v2.0/
|
||||
username: username
|
||||
password: Equality7-2521
|
||||
project_name: username-project1
|
||||
name: vm1
|
||||
region_name: region-b.geo-1
|
||||
availability_zone: az2
|
||||
image: 9302692b-b787-4b52-a3a6-daebb79cb498
|
||||
key_name: test
|
||||
timeout: 200
|
||||
flavor: 101
|
||||
security_groups: default
|
||||
auto_ip: yes
|
||||
- name: launch an instance
|
||||
os_server:
|
||||
state: present
|
||||
auth:
|
||||
auth_url: 'https://region-b.geo-1.identity.hpcloudsvc.com:35357/v2.0/'
|
||||
username: username
|
||||
password: Equality7-2521
|
||||
project_name: username-project1
|
||||
name: vm1
|
||||
region_name: region-b.geo-1
|
||||
availability_zone: az2
|
||||
image: 9302692b-b787-4b52-a3a6-daebb79cb498
|
||||
key_name: test
|
||||
timeout: 200
|
||||
flavor: 101
|
||||
security_groups: default
|
||||
auto_ip: yes
|
||||
|
||||
# Creates a new instance in named cloud mordred availability zone az2
|
||||
# Create a new instance in named cloud mordred availability zone az2
|
||||
# and assigns a pre-known floating IP
|
||||
- name: launch a compute instance
|
||||
hosts: localhost
|
||||
tasks:
|
||||
- name: launch an instance
|
||||
os_server:
|
||||
state: present
|
||||
cloud: mordred
|
||||
name: vm1
|
||||
availability_zone: az2
|
||||
image: 9302692b-b787-4b52-a3a6-daebb79cb498
|
||||
key_name: test
|
||||
timeout: 200
|
||||
flavor: 101
|
||||
floating_ips:
|
||||
- 12.34.56.79
|
||||
- name: launch an instance
|
||||
os_server:
|
||||
state: present
|
||||
cloud: mordred
|
||||
name: vm1
|
||||
availability_zone: az2
|
||||
image: 9302692b-b787-4b52-a3a6-daebb79cb498
|
||||
key_name: test
|
||||
timeout: 200
|
||||
flavor: 101
|
||||
floating_ips:
|
||||
- 12.34.56.79
|
||||
|
||||
# Creates a new instance with 4G of RAM on Ubuntu Trusty, ignoring
|
||||
# Create a new instance with 4G of RAM on Ubuntu Trusty, ignoring
|
||||
# deprecated images
|
||||
- name: launch a compute instance
|
||||
hosts: localhost
|
||||
tasks:
|
||||
- name: launch an instance
|
||||
os_server:
|
||||
name: vm1
|
||||
state: present
|
||||
cloud: mordred
|
||||
region_name: region-b.geo-1
|
||||
image: Ubuntu Server 14.04
|
||||
image_exclude: deprecated
|
||||
flavor_ram: 4096
|
||||
- name: launch an instance
|
||||
os_server:
|
||||
name: vm1
|
||||
state: present
|
||||
cloud: mordred
|
||||
region_name: region-b.geo-1
|
||||
image: Ubuntu Server 14.04
|
||||
image_exclude: deprecated
|
||||
flavor_ram: 4096
|
||||
|
||||
# Creates a new instance with 4G of RAM on Ubuntu Trusty on a Performance node
|
||||
# Create a new instance with 4G of RAM on Ubuntu Trusty on a Performance node
|
||||
- name: launch a compute instance
|
||||
hosts: localhost
|
||||
tasks:
|
||||
- name: launch an instance
|
||||
os_server:
|
||||
name: vm1
|
||||
cloud: rax-dfw
|
||||
state: present
|
||||
image: Ubuntu 14.04 LTS (Trusty Tahr) (PVHVM)
|
||||
flavor_ram: 4096
|
||||
flavor_include: Performance
|
||||
- name: launch an instance
|
||||
os_server:
|
||||
name: vm1
|
||||
cloud: rax-dfw
|
||||
state: present
|
||||
image: Ubuntu 14.04 LTS (Trusty Tahr) (PVHVM)
|
||||
flavor_ram: 4096
|
||||
flavor_include: Performance
|
||||
|
||||
# Creates a new instance and attaches to multiple network
|
||||
- name: launch a compute instance
|
||||
hosts: localhost
|
||||
tasks:
|
||||
- name: launch an instance with a string
|
||||
os_server:
|
||||
auth:
|
||||
auth_url: https://region-b.geo-1.identity.hpcloudsvc.com:35357/v2.0/
|
||||
username: admin
|
||||
password: admin
|
||||
project_name: admin
|
||||
name: vm1
|
||||
image: 4f905f38-e52a-43d2-b6ec-754a13ffb529
|
||||
key_name: ansible_key
|
||||
timeout: 200
|
||||
flavor: 4
|
||||
nics: "net-id=4cb08b20-62fe-11e5-9d70-feff819cdc9f,net-id=542f0430-62fe-11e5-9d70-feff819cdc9f..."
|
||||
- name: launch an instance with a string
|
||||
os_server:
|
||||
auth:
|
||||
auth_url: 'https://region-b.geo-1.identity.hpcloudsvc.com:35357/v2.0/'
|
||||
username: admin
|
||||
password: admin
|
||||
project_name: admin
|
||||
name: vm1
|
||||
image: 4f905f38-e52a-43d2-b6ec-754a13ffb529
|
||||
key_name: ansible_key
|
||||
timeout: 200
|
||||
flavor: 4
|
||||
nics: "net-id=4cb08b20-62fe-11e5-9d70-feff819cdc9f,net-id=542f0430-62fe-11e5-9d70-feff819cdc9f..."
|
||||
|
||||
# Creates a new instance and attaches to a network and passes metadata to
|
||||
# the instance
|
||||
- os_server:
|
||||
- name: Creates a new instance and attaches to a network and passes metadata to the instance
|
||||
os_server:
|
||||
state: present
|
||||
auth:
|
||||
auth_url: https://region-b.geo-1.identity.hpcloudsvc.com:35357/v2.0/
|
||||
auth_url: 'https://region-b.geo-1.identity.hpcloudsvc.com:35357/v2.0/'
|
||||
username: admin
|
||||
password: admin
|
||||
project_name: admin
|
||||
|
@ -332,51 +330,51 @@ EXAMPLES = '''
|
|||
- net-name: another_network
|
||||
meta: "hostname=test1,group=uge_master"
|
||||
|
||||
# Creates a new instance and attaches to a specific network
|
||||
- os_server:
|
||||
state: present
|
||||
auth:
|
||||
auth_url: https://region-b.geo-1.identity.hpcloudsvc.com:35357/v2.0/
|
||||
username: admin
|
||||
password: admin
|
||||
project_name: admin
|
||||
name: vm1
|
||||
image: 4f905f38-e52a-43d2-b6ec-754a13ffb529
|
||||
key_name: ansible_key
|
||||
timeout: 200
|
||||
flavor: 4
|
||||
network: another_network
|
||||
- name: Creates a new instance and attaches to a specific network
|
||||
os_server:
|
||||
state: present
|
||||
auth:
|
||||
auth_url: 'https://region-b.geo-1.identity.hpcloudsvc.com:35357/v2.0/'
|
||||
username: admin
|
||||
password: admin
|
||||
project_name: admin
|
||||
name: vm1
|
||||
image: 4f905f38-e52a-43d2-b6ec-754a13ffb529
|
||||
key_name: ansible_key
|
||||
timeout: 200
|
||||
flavor: 4
|
||||
network: another_network
|
||||
|
||||
# Creates a new instance with 4G of RAM on a 75G Ubuntu Trusty volume
|
||||
# Create a new instance with 4G of RAM on a 75G Ubuntu Trusty volume
|
||||
- name: launch a compute instance
|
||||
hosts: localhost
|
||||
tasks:
|
||||
- name: launch an instance
|
||||
os_server:
|
||||
name: vm1
|
||||
state: present
|
||||
cloud: mordred
|
||||
region_name: ams01
|
||||
image: Ubuntu Server 14.04
|
||||
flavor_ram: 4096
|
||||
boot_from_volume: True
|
||||
volume_size: 75
|
||||
- name: launch an instance
|
||||
os_server:
|
||||
name: vm1
|
||||
state: present
|
||||
cloud: mordred
|
||||
region_name: ams01
|
||||
image: Ubuntu Server 14.04
|
||||
flavor_ram: 4096
|
||||
boot_from_volume: True
|
||||
volume_size: 75
|
||||
|
||||
# Creates a new instance with 2 volumes attached
|
||||
- name: launch a compute instance
|
||||
hosts: localhost
|
||||
tasks:
|
||||
- name: launch an instance
|
||||
os_server:
|
||||
name: vm1
|
||||
state: present
|
||||
cloud: mordred
|
||||
region_name: ams01
|
||||
image: Ubuntu Server 14.04
|
||||
flavor_ram: 4096
|
||||
volumes:
|
||||
- photos
|
||||
- music
|
||||
- name: launch an instance
|
||||
os_server:
|
||||
name: vm1
|
||||
state: present
|
||||
cloud: mordred
|
||||
region_name: ams01
|
||||
image: Ubuntu Server 14.04
|
||||
flavor_ram: 4096
|
||||
volumes:
|
||||
- photos
|
||||
- music
|
||||
'''
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue