---
- name: Set up network stuff
  hosts: localhost
  connection: local
  become: false
  vars:
    uid: "{{ lookup('env','USER') }}"
  tasks:
    - name: Allow nm-applet to set wifi
      become: true
      ansible.builtin.template:
        src: ../templates/org.freedesktop.NetworkManager.policy.j2
        dest: /usr/share/polkit-1/actions/org.freedesktop.NetworkManager.policy
    - name: Manage ifupdown in NM
      become: true
      ansible.builtin.lineinfile:
        path: /etc/NetworkManager/NetworkManager.conf 
        regex: managed=false
        line: managed=true