ANSIBLE.LINODE(3)

NAME
linode - create / delete / stop / restart an instance in Linode Public Cloud

DESCRIPTION

creates / deletes a Linode Public Cloud instance and optionally waits for it to be 'running'.

OPTIONS

api_key
    Linode API key

datacenter
    datacenter to create an instance in (Linode Datacenter)

distribution
    distribution to use for the instance (Linode Distribution)

linode_id
    Unique ID of a linode server

name
    Name to give the instance (alphanumeric, dashes, underscore)To keep sanity on the Linode Web Console, name is prepended with LinodeID_

password
    root password to apply to a new server (auto generated if missing)

payment_term
    payment term to use for the instance (payment term in months) Choices: yes,12,24. (default: yes

plan
    plan to use for the instance (Linode plan)

ssh_pub_key
    SSH public key applied to root user

state
    Indicate desired state of the resource Choices: present,active,started,absent',deleted,stopped,restarted. (default: present)

swap
    swap size in MB (default: 512)

wait
    wait for the instance to be in state 'running' before returning Choices: yes,no. (default: no)

wait_timeout
    how long before wait gives up, in seconds (default: 300).

NOTES

LINODE_API_KEY env variable can be used instead

EXAMPLES
# Create a server
- local_action:
     module: linode
     api_key: 'longStringFromLinodeApi'
     name: linode-test1
     plan: 1
     datacenter: 2
     distribution: 99
     password: 'superSecureRootPassword'
     ssh_pub_key: 'ssh-rsa qwerty'
     swap: 768
     wait: yes
     wait_timeout: 600
     state: present
# Ensure a running server (create if missing)
- local_action:
     module: linode
     api_key: 'longStringFromLinodeApi'
     name: linode-test1
     linode_id: 12345678
     plan: 1
     datacenter: 2
     distribution: 99
     password: 'superSecureRootPassword'
     ssh_pub_key: 'ssh-rsa qwerty'
     swap: 768
     wait: yes
     wait_timeout: 600
     state: present
# Delete a server
- local_action:
     module: linode
     api_key: 'longStringFromLinodeApi'
     name: linode-test1
     linode_id: 12345678
     state: absent
# Stop a server
- local_action:
     module: linode
     api_key: 'longStringFromLinodeApi'
     name: linode-test1
     linode_id: 12345678
     state: stopped
# Reboot a server
- local_action:
     module: linode
     api_key: 'longStringFromLinodeApi'
     name: linode-test1
     linode_id: 12345678
     state: restarted

AUTHOR
Vincent Viallet

SEE ALSO
ansible(1), http://ansible.github.com/modules.html#linode