Network-Setup/Ansible/playbook.yaml
2022-02-18 22:02:53 +01:00

38 lines
No EOL
936 B
YAML

---
- name: Install Container-runtime Podman - misc
remote_user: eichehome
tasks:
- name: Install Podman
ansible.builtin.package:
name: podman
state: present
- name: Install Git
ansible.builtin.package:
name: git
state: present
- name: Create Directory
ansible.builtin.file:
path: '/git/Network-Setup'
state: directory
- name: Checkout Git
ansible.builtin.git:
repo: 'https://git.sp-codes.de/eichehome/Network-Setup'
dest: /git/Network-Setup
- name: Setup wg0
ansible.builtin.file:
src: '/git/Network-Setup/Systemd/{{ item.src }}'
dest: '/etc/systemd/network/{{ item.dest }}'
loop:
- { src: wg0.netdev, dest: wg0.netdev }
- { src: wg0.network, dest: wg0.network }
- name: Link resolve.conf
ansible.builtin.file:
src: '/run/systemd/resolve/stub-resolv.conf'
dest: '/etc/resolve.conf'
state: link