diff --git a/basics.yml b/basics.yml index 1ca0c96..8419a98 100644 --- a/basics.yml +++ b/basics.yml @@ -135,22 +135,35 @@ # filename: testing # when: ansible_distribution_release is match("bookworm") - - name: check if this is a mint system + - name: check if this is a Mint system stat: path: /etc/linuxmint/mintSystem.conf - register: mint + register: mintpios - - name: add dhcpcd to startup + - name: check if we are in a RaspberryPiOS + stat: + path: /usr/bin/wayfire-pi + register: mintpios + + - name: Install Basic Packages if not running in container/mint or PiOS + apt: + name: + - dhcpcd5 + update_cache: yes + install_recommends: no + when: (nocontainer.stat.exists == true) and (mintpios.stat.exists == false) + + - name: add dhcpcd to startup if not running in container/mint or PiOS command: systemctl enable dhcpcd args: creates: /etc/systemd/system/multi-user.target.wants/dhcpcd.service - when: (nocontainer.stat.exists == true) and (mint.stat.exists == false) + when: (nocontainer.stat.exists == true) and (mintpios.stat.exists == false) - - name: No DHCPcd for internal interfaces + - name: No DHCPcd for internal interfaces if not running in container/mint or PiOS ansible.builtin.lineinfile: path: /etc/dhcpcd.conf line: denyinterfaces docker0 virbr0 tornet0 veth* br* eth1 - when: (nocontainer.stat.exists == true) and (mint.stat.exists == false) + when: (nocontainer.stat.exists == true) and (mintpios.stat.exists == false) register: dhcpcd - name: Check weather /etc/network/interfaces exists