add wifi "support"
This commit is contained in:
parent
533082b8d4
commit
96d62d6060
@ -1,5 +1,8 @@
|
||||
---
|
||||
|
||||
# password for wifi, if applicable
|
||||
conn_pass: ""
|
||||
|
||||
# password for ddclient
|
||||
ddclient_pass: ""
|
||||
|
||||
|
@ -120,6 +120,7 @@ services:
|
||||
PAPERLESS_URL: "https://{{ paperless_domain }}"
|
||||
PAPERLESS_USE_X_FORWARD_HOST: true
|
||||
PAPERLESS_USE_X_FORWARD_PORT: true
|
||||
PAPERLESS_OCR_USER_ARGS: '{"continue_on_soft_render_error": true}'
|
||||
PAPERLESS_OCR_PAGES: 1
|
||||
PAPERLESS_TASK_WORKERS: 2
|
||||
PAPERLESS_THREADS_PER_WORKER: 2
|
||||
|
@ -3,6 +3,15 @@
|
||||
|
||||
# static IP interface
|
||||
net_interface: eth0
|
||||
# e.g. wifi
|
||||
conn_type: ethernet
|
||||
# if you have a wireless connection already, set this to its name to use it
|
||||
conn_name: wired
|
||||
# wifi connection name
|
||||
conn_ssid: ""
|
||||
# set this in the secret template
|
||||
conn_pass: ""
|
||||
|
||||
# LAN static IP address
|
||||
local_ip: null
|
||||
subnet_prefix: /24
|
||||
|
@ -3,6 +3,11 @@
|
||||
name:
|
||||
- networkmanager
|
||||
|
||||
- name: Disable MAC randomization
|
||||
template:
|
||||
src: mac-randomization.conf.j2
|
||||
dest: /etc/systemd/resolved.conf.d/30-mac-randomization.conf
|
||||
|
||||
- name: Enable NetworkManager
|
||||
service:
|
||||
name: NetworkManager
|
||||
@ -68,9 +73,13 @@
|
||||
gw4: "{{ gateway }}"
|
||||
method4: manual
|
||||
state: present
|
||||
conn_name: wired
|
||||
conn_name: "{{ conn_name }}"
|
||||
ssid: "{{ conn_ssid }}"
|
||||
wifi_sec:
|
||||
key-mgmt: wpa-psk
|
||||
psk: "{{ conn_pass }}"
|
||||
ifname: "{{ net_interface }}"
|
||||
type: ethernet
|
||||
type: "{{ conn_type }}"
|
||||
register: nmcli_conf
|
||||
changed_when: false
|
||||
poll: 0
|
||||
|
@ -0,0 +1,2 @@
|
||||
[device-mac-randomization]
|
||||
wifi.scan-rand-mac-address=no
|
@ -3,6 +3,6 @@
|
||||
sleep 30
|
||||
|
||||
/usr/bin/nmcli connection down {{ net_interface }} > /dev/null 2>&1
|
||||
/usr/bin/nmcli connection down "Wired connection 1" > /dev/null 2>&1
|
||||
/usr/bin/nmcli connection down wired > /dev/null 2>&1
|
||||
/usr/bin/nmcli connection up wired > /dev/null
|
||||
/usr/bin/nmcli connection down "Wired connection 1" > /dev/null 2>&1
|
||||
/usr/bin/nmcli connection down {{ conn_name }} > /dev/null 2>&1
|
||||
/usr/bin/nmcli connection up {{ conn_name }} > /dev/null
|
||||
|
Loading…
Reference in New Issue
Block a user