cozystack-proxmox - Ansible playbook for setting up Proxmox VE access control
- Create ACLs, users, roles, and API tokens for Cozystack integration
- Generate an encrypted resource file with user credentials and permissions
- Allow to auto-map the GPU resources to the VMs to allow GPU passthrough easily
Create a secure password and store it somewhere safe:
head -c48 /dev/urandom | base64 > ~/.yourvaultmasterpasswordfileCopy the example secrets file to the appropriate location:
cp ansible/envs/.host_vars/.thepvesecrets.yml.example ansible/envs/.host_vars/.thepvesecrets.ymlEncrypt the secrets file before editing:
ansible-vault encrypt --vault-password-file ~/.yourvaultmasterpasswordfile ansible/envs/.host_vars/.thepvesecrets.ymlUsefull ansible-vault commands:
ansible-vault encrypt
ansible-vault decrypt
ansible-vault edit
ansible-vault view ansible-playbook ansible/playbooks/proxmox_acl_setup.yml --vault-password-file ~/.yourvaultmasterpasswordfileansible-playbook ansible/playbooks/proxmox_gpu_mapping.yml --vault-password-file ~/.yourvaultmasterpasswordfileyou can erase any created resources by running the playbook with the -e option:
ansible-playbook ansible/playbooks/proxmox_acl_setup.yml --vault-password-file ~/.yourvaultmasterpasswordfile -e "reset=true" Apache 2.0