homelab-automation/ansible/playbooks/proxmox.yml
Benjamin Hays bd06770c7a
Some checks failed
Ansible Deploy / deploy (ansible/playbooks/debian.yml) (push) Failing after 2m23s
Ansible Deploy / deploy (ansible/playbooks/proxmox.yml) (push) Failing after 1m9s
Ansible Lint / build (push) Successful in 1m22s
fix strange folder naming error
2025-05-18 10:25:12 -04:00

28 lines
874 B
YAML

---
- name: Proxmox Configuration Playbook
hosts: proxmox
remote_user: root
tasks:
- name: Adding ansible SSH Pubkey as authorized
ansible.builtin.copy:
mode: "0600"
src: ../../configs/authorized_keys
dest: /root/.ssh/authorized_keys
- name: Adding PVE-no-subscription repo
ansible.builtin.blockinfile:
path: /etc/apt/sources.list
insertbefore: ^# security
block: |
# PVE pve-no-subscription repository provided by proxmox.com,
# NOT recommended for production use
deb http://download.proxmox.com/debian/pve bookworm pve-no-subscription
- name: Upgrading system
ansible.builtin.apt:
upgrade: safe
update_cache: true
cache_valid_time: 7200
- name: Installing sudo
ansible.builtin.apt:
name: sudo
state: present