Ansible role for configuring a Proxmox VE server/cluster.
This role assumes that you are running it on Proxmox server installation.
For nodes to join on a existing cluster, the current node and existing member should have SSH connection with SSH keys setup.
Variable | Comment |
---|---|
pve_force_reboot boolean |
Force the server to reboot after executing the role. Choices: |
pve_force_reboot boolean |
Force the server to reboot after executing the role. Choices: |
pve_enterprise boolean |
Defines whether the server has an PVE-Enterprise license. Choices: |
pve_datacenter_tag_style_order string |
Defines the order of the guests tags. Set to |
Variable | Comment |
---|---|
pve_iommu_passthrough boolean |
Enable/disable PCI passthrough configuration. Choices: |
pve_iommu_intel boolean |
Enable/disable the IOMMU for Intel processors with VT-d/VT-x. Choices: |
Variable | Comment |
---|---|
pve_admin_group string |
Define the Administrators group on the PVE realm. Default: |
pve_admin_user string |
Define the administrator user on the PVE realm. Default: |
pve_audit_group string |
Define the Auditors group on the PVE realm. Default: |
pve_audit_user string |
Define the audit user on the PVE realm. Default: |
Variable | Comment |
---|---|
pve_cluster_create string |
Define the name of PVE cluster to be created. This variable MUST be defined in only one node per cluster. |
pve_cluster_hostname string |
Define the node hostname. Default: |
pve_cluster_join_address string |
Define the address of an existing cluster member to join. Format: DNS-like name, IP address or IPv6 address. |
pve_cluster_link string |
Force the cluster communication to go through the specified link address. Format: DNS-like name, IP address or IPv6 address. |
pve_cluster_ha_shutdown_policy string |
Define the shutdown policy for HA-enabled guests. Please refer to the Shutdown Policy section on the official Proxmox High Availability guide for more information. Choices: |
pve_cluster_migration_network string |
Set the network for running guests migration. Format: IP address/mask or IPv6 address/mask. |
Variable | Comment |
---|---|
pve_network_interfaces list / elements=string or interface_config |
Defines the local network interfaces configuration. |
pve_network_bridges list / elements=bridge_config |
Defines the local network bridges configuration. |
pve_network_interface_alias list / elements=interface_alias |
Defines persistent interface alias for local network interfaces. Use this to rename interface to a more convenient names. |
Attribute | Comment | Required / Optional |
---|---|---|
name string |
The interface name. For VLAN tagged interfaces append the VLAN tag on the interface name (e.g: Informing only the |
Required |
allow string |
Identify the subsystem that should brought up the interface. Choices: |
Optional |
address string |
The address to be assigned to the interface. Format: IP address/mask. |
Optional |
gateway string |
The network gateway address. Format: IP address. |
Optional |
description string |
Free-form comment to be appended on the interface configuration. |
Optional |
Attribute | Comment | Required / Optional |
---|---|---|
name string |
The bridge name. |
Required |
interfaces string list / elements=string |
The physical interface(s) that should be bridged into. |
Required |
address string |
The address to be assigned to the brigde. Format: IP address/mask. |
Optional |
gateway string |
The network gateway address. Format: IP address. |
Optional |
vlans string |
Turn the bridge into a VLAN-aware bridge for the configured VLANs. Format: comma separated list of VLAN ID, range of VLAN IDs can be grouped with dashes (e.g. |
Optional |
description string |
Free-form comment to be appended on the interface configuration. |
Optional |
Attribute | Comment | Required / Optional |
---|---|---|
mac_address string |
The MAC address to match the interface. At least one in |
Optional |
driver string |
The driver to match the interface. To discover your interface driver you can run: At least one in |
Optional |
interface_name string |
The name (alias) to be configured for the interface. |
Required |
Variable | Comment |
---|---|
pve_cifs_shares list / elements=cifs_share |
Define the CIFS/SMB shares to be added on the server/cluster storage. |
pve_nfs_mounts list / elements=nfs_mount |
Define the NFS mounts to be added on the server/cluster storage. |
pve_iscsi_targets list / elements=iscsi_target |
Define the iSCSI targets to be added on the server/cluster storage. |
pve_iscsi_authentication iscsi_authentication |
Define the iSCSI authentication for the iSCSI targets, whenever authentication is needed. |
pve_zfs_pools list / elements=zfs_pool |
Defined the ZFS pools to be added on the server/cluster storage. |
pve_lvm_mounts list / elements=lvm_mount |
Define the LVM mounts to be added on the server/cluster storage. |
Attribute | Comment | Required / Optional |
---|---|---|
name string |
The storage name on the Proxmox server/cluster. |
Required |
server string |
The CIFS/SMB server address. Format: DNS-like name, IP address or IPv6 address. |
Required |
share string |
The CIFS/SMB share name. |
Required |
username string |
The CIFS/SMB username credentials. |
Required |
password string |
The CIFS/SMB password credentials. |
Required |
content string |
Comma separated list of the storage content types. Please refer to the Common Storage Properties section on the official Proxmox Storage documentation for more information. Choices: |
Optional |
shared boolean |
Indicate that this is a single storage with the same contents on all nodes. Choices: |
Optional |
Attribute | Comment | Required / Optional |
---|---|---|
name string |
The storage name on the Proxmox server/cluster. |
Required |
server string |
The NFS server address. Format: DNS-like name, IP address or IPv6 address. |
Required |
export path |
The NFS export path. |
Required |
content string |
Comma separated list of the storage content types. Please refer to the Common Storage Properties section on the official Proxmox Storage documentation for more information. Choices: |
Optional |
nodes string |
Comma separated list of nodes where the should be available, set Default: |
Optional |
Attribute | Comment | Required / Optional |
---|---|---|
name string |
The storage name on the Proxmox server/cluster. |
Required |
portal string |
The iSCSI server address. Format: DNS-like name, IP address or IPv6 address. |
Required |
target path |
The iSCSI target IQN. Format: base-name:target |
Required |
content string |
The iSCSI storage content types. If you want to use LVM on top of iSCSI, it make sense to set content Please refer to the Common Storage Properties section on the official Proxmox Storage documentation for more information. Choices: |
Optional |
nodes string |
Comma separated list of nodes where the should be available, set Default: |
Optional |
Attribute | Comment | Required / Optional |
---|---|---|
username string |
The iSCSI User credentials. |
Required |
password string |
The iSCSI User secret credentials. |
Required |
username_in string |
The iSCSI Peer (initiator) User credentials. |
Required |
password_in string |
The iSCSI Peer (initiator) secret credentials. |
Required |
Attribute | Comment | Required / Optional |
---|---|---|
name string |
The storage name on the Proxmox server/cluster. |
Required |
pool string |
The ZFS pool name. |
Required |
content string |
Comma separated list of the storage content types. Please refer to the Common Storage Properties section on the official Proxmox Storage documentation for more information. Choices: |
Optional |
Attribute | Comment | Required / Optional |
---|---|---|
name string |
The storage name on the Proxmox server/cluster. |
Required |
vgname string |
LVM volume group name. This must point to an existing volume group. |
Required |
content string |
Comma separated list of the storage content types. Please refer to the Common Storage Properties section on the official Proxmox Storage documentation for more information. Choices: |
Optional |
- name: Configuring Proxmox VE server
hosts: all
roles:
- gringolito.proxmox_ve
vars:
pve_datacenter_tag_style_order: config
pve_iommu_intel: true
pve_iommu_passthrough: true
pve_network_interface_alias:
- driver: r8152
interface_name: enusb0
pve_nfs_mounts:
- name: my-nfs
server: nfs.gringolito.com
export: /mnt/nfs/pve
content: images,backup,iso
Beerware
Filipe Utzig < filipe at gringolito.com >