Skip to content
This repository has been archived by the owner on Sep 2, 2021. It is now read-only.

Latest commit

 

History

History
44 lines (36 loc) · 1.41 KB

README.md

File metadata and controls

44 lines (36 loc) · 1.41 KB

Ansible Proxmox API

proxmox_api is an Ansible module to interact with the Proxmox API.

Parameters

Parameter Type Default Description
endpoint str The endpoint to call.
method str GET The HTTP method to use (GET/POST/...).
host str The Proxmox host to communicate with.
port int 8006 The port at which the Proxmox API listens.
user str The username to log in to Proxmox with.
password str The user's password.
verify_ssl bool True Verify the hosts SSL certificate.
parameters dict Parameters to send in the body.

Examples

Get properties for all nodes

- name: Get properties for all nodes
  proxmox_api:
    endpoint: /nodes
    host: proxmox.example.com
    user: admin
    password: secret

Set a virtual machine to boot from hard disk

- name: Set a virtual machine to boot from hard disk
  proxmox_api:
    endpoint: '/nodes/{{ node }}/qemu/{{ vmid }}/config
    method: post
    host: proxmox.example.com
    user: admin
    password: secret
    parameters:
      boot: c