community.general.linode_v4 module – Manage instances on the Linode cloud
Note
This module is part of the community.general collection (version 10.7.5).
You might already have this collection installed if you are using the ansible package.
It is not included in ansible-core.
To check whether it is installed, run ansible-galaxy collection list.
To install it, use: ansible-galaxy collection install community.general.
You need further requirements to be able to use this module,
see Requirements for details.
To use it in a playbook, specify: community.general.linode_v4.
Synopsis
- Manage instances on the Linode cloud. 
Requirements
The below requirements are needed on the host that executes this module.
- linode_api4 >= 2.0.0 
Parameters
| Parameter | Comments | 
|---|---|
| The Linode API v4 access token. It may also be specified by exposing the  See https://www.linode.com/docs/api#access-and-authentication. | |
| A list of SSH public key parts to deploy for the root user. | |
| The group that the instance should be marked under. Please note, that group labelling is deprecated but still supported. The encouraged method for marking instances is to use tags. | |
| The image of the instance. This is a required parameter only when creating Linode instances. | |
| The instance label. This label is used as the main determiner for idempotency for the module and is therefore mandatory. | |
| If  Choices: 
 | |
| The region of the instance. This is a required parameter only when creating Linode instances. See https://www.linode.com/docs/api/regions/. | |
| The password for the root user. If not specified, it generates a new one. This generated password is available in the task success JSON. | |
| An object containing arguments to any User Defined Fields present in the StackScript used when creating the instance. Only valid when a  | |
| The numeric ID of the StackScript to use when creating the instance. | |
| The desired instance state. Choices: 
 | |
| The tags that the instance should be marked under. | |
| The type of the instance. This is a required parameter only when creating Linode instances. | 
Attributes
| Attribute | Support | Description | 
|---|---|---|
| Support: none | Can run in  | |
| Support: none | Will return details on what has changed (or possibly needs changing in  | 
Notes
Note
- No Linode resizing is currently implemented. This module aims to replace the current Linode module which uses deprecated API bindings on the Linode side. 
Examples
- name: Create a new Linode.
  community.general.linode_v4:
    label: new-linode
    type: g6-nanode-1
    region: eu-west
    image: linode/debian9
    root_pass: passw0rd
    authorized_keys:
      - "ssh-rsa ..."
    stackscript_id: 1337
    stackscript_data:
      variable: value
    state: present
- name: Delete that new Linode.
  community.general.linode_v4:
    label: new-linode
    state: absent
Return Values
Common return values are documented here, the following are the fields unique to this module:
| Key | Description | 
|---|---|
| The instance description in JSON serialized form. Returned: Always. Sample:  | 
