mirror of
https://gitlab.sectorq.eu/jaydee/ansible.git
synced 2025-09-13 04:10:10 +02:00
This commit is contained in:
@@ -4,22 +4,21 @@
|
||||
state: present
|
||||
become: true
|
||||
- name: Display all interfaces name
|
||||
debug:
|
||||
ansible.builtin.debug:
|
||||
var: ansible_facts.interfaces
|
||||
- name: Get wifi adapter
|
||||
set_fact:
|
||||
ansible.builtin.set_fact:
|
||||
active_adapter: '{{ item }}'
|
||||
loop: '{{ ansible_facts.interfaces }}'
|
||||
when: 'item.startswith("eno")'
|
||||
- name: Display all interfaces name
|
||||
debug:
|
||||
ansible.builtin.debug:
|
||||
msg: "{{ ansible_default_ipv4.interface }}"
|
||||
|
||||
|
||||
- name: Creating config
|
||||
become: true
|
||||
ansible.builtin.copy:
|
||||
|
||||
dest: "/etc/systemd/system/wol.service"
|
||||
content: |
|
||||
[Unit]
|
||||
|
Reference in New Issue
Block a user