52 lines
1.0 KiB
YAML
52 lines
1.0 KiB
YAML
---
|
|
|
|
- hosts: localhost
|
|
connection: localhost
|
|
become: true
|
|
|
|
pre_tasks:
|
|
|
|
- name: change sorces.list file
|
|
copy:
|
|
src: files/sources.list
|
|
dest: /etc/apt/sources.list
|
|
owner: root
|
|
group: root
|
|
|
|
- name: change sorces.list file
|
|
copy:
|
|
src: files/pve-enterprise.list
|
|
dest: /etc/apt/sources.list.d/pve-enterprise.list
|
|
owner: root
|
|
group: root
|
|
|
|
tasks:
|
|
|
|
- name: update package cache
|
|
apt:
|
|
- update_cache=yes
|
|
- autoremove=yes
|
|
- autoclean=yes
|
|
|
|
- name: dist upgrade
|
|
apt: upgrade=dist
|
|
|
|
- name: add ansible-pull cron job
|
|
cron:
|
|
name: ansible auto-provision
|
|
minute: "15"
|
|
hour: "1"
|
|
user: root
|
|
job: "ansible-pull -o -U https://git.bitsathy.ac.in/ShankarMounesh/ansible-proxmox.git proxmox.yml"
|
|
|
|
- name: add reboot cronjob
|
|
cron:
|
|
name: reboot machine every sunday
|
|
minute: "*/5"
|
|
# hour: "2"
|
|
user: root
|
|
job: "reboot"
|
|
|
|
|
|
|