Add role to set up base Proxmox server

This commit is contained in:
Timotej Lazar 2023-07-14 14:17:44 +02:00
parent db310ba716
commit aae782a66b
3 changed files with 27 additions and 0 deletions

View file

@ -0,0 +1,2 @@
- name: reload interfaces
command: ifreload -a

View file

@ -0,0 +1,16 @@
- name: Disable enterprise repositories
apt_repository:
repo: '{{ item }}'
state: absent
update_cache: '{{ ansible_loop.last }}'
loop:
- 'deb https://enterprise.proxmox.com/debian/pve {{ ansible_distribution_release }} pve-enterprise'
- 'deb https://enterprise.proxmox.com/debian/ceph-quincy {{ ansible_distribution_release }} enterprise'
loop_control:
extended: true
- name: Enable no-subscription repository
apt_repository:
repo: 'deb http://download.proxmox.com/debian/pve {{ ansible_distribution_release }} pve-no-subscription'
- include_tasks: sdn.yml

View file

@ -0,0 +1,9 @@
- name: Install packages for SDN
package:
name: libpve-network-perl
- name: Source SDN network configuration
lineinfile:
path: /etc/network/interfaces
line: 'source /etc/network/interfaces.d/*'
notify: reload interfaces