Activated update for debian

This commit is contained in:
Kevin Veen-Birkenbach 2020-12-31 13:21:56 +01:00
parent baeef4aad2
commit 6e4ae4d03b
7 changed files with 31 additions and 6 deletions

View File

@ -2,6 +2,15 @@
## Description
Ansible script to manage servers.
## roles
The system use the following role namings:
| role prefix | meaning|
|---|---|
|system-|system changes|
|native-|applications which run native on the system|
|docker-|applications which run on docker containers on the system|
## Update
Follow the best [practices for inventories](https://docs.ansible.com/ansible/2.3/playbooks_best_practices.html) and execute ansible via:

View File

@ -0,0 +1,5 @@
# role native-apt-update
This role updates the packages
# upgrade
Keep in mind that you have to do the upgrade manual because debian based distributions are no runing release

View File

@ -0,0 +1,4 @@
- name: apt update all packages to their latest version
apt:
name: "*"
state: latest

View File

@ -1,2 +1,3 @@
dependencies:
- native-ssh
- native-user-alarm

View File

@ -0,0 +1,3 @@
dependencies:
- { role: native-pacman-update, when: ansible_distribution == 'Archlinux' }
- { role: native-apt-update, when: ansible_distribution == "Debian" }

View File

@ -1,12 +1,15 @@
---
- name: setup arch hosts
hosts: arch_hosts
- name: general host setup
hosts: all
roles:
- system-security
- system-update
become: true
- name: setup wireguard hosts
hosts: wireguard_hosts
roles:
- native-security
- native-pacman
- native-wireguard
- native-user-alarm
- name: setup primary_backup_hosts
- name: setup primary backup hosts
hosts: primary_backup_hosts
pre_tasks:
- name: "check if docker is installed"