community.general.scaleway – Scaleway inventory source¶
Note
This plugin is part of the community.general collection (version 1.3.6).
To install it use: ansible-galaxy collection install community.general
.
To use it in a playbook, specify: community.general.scaleway
.
Parameters¶
Parameter | Choices/Defaults | Configuration | Comments |
---|---|---|---|
hostnames
list
/ elements=string
|
["public_ipv4"]
|
List of preference about what to use as an hostname.
|
|
oauth_token
string
/ required
|
env:SCW_TOKEN
env:SCW_API_KEY
env:SCW_OAUTH_TOKEN
|
Scaleway OAuth token.
|
|
plugin
string
/ required
|
|
token that ensures this is a source file for the 'scaleway' plugin.
|
|
regions
list
/ elements=string
|
Default: ["ams1", "par1", "par2", "waw1"]
|
Filter results on a specific Scaleway region
|
|
tags
list
/ elements=string
|
Filter results on a specific tag
|
||
variables
dictionary
|
set individual variables: keys are variable names and values are templates. Any value returned by the Scaleway API can be used.
|
Examples¶
# scaleway_inventory.yml file in YAML format
# Example command line: ansible-inventory --list -i scaleway_inventory.yml
# use hostname as inventory_hostname
# use the private IP address to connect to the host
plugin: community.general.scaleway
regions:
- ams1
- par1
tags:
- foobar
hostnames:
- hostname
variables:
ansible_host: private_ip
state: state
# use hostname as inventory_hostname and public IP address to connect to the host
plugin: community.general.scaleway
hostnames:
- hostname
regions:
- par1
variables:
ansible_host: public_ip.address
Authors¶
Remy Leone (@sieben)