mirror of
https://github.com/iiab/iiab.git
synced 2025-03-09 15:40:17 +00:00
keep the pids known
This commit is contained in:
parent
000d4ec35c
commit
37ed8a6ba4
3 changed files with 6 additions and 4 deletions
|
@ -10,11 +10,11 @@ Before=netplan-wpa@{{ discovered_wireless_iface }}.service
|
||||||
Before=hostapd.service
|
Before=hostapd.service
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
Type=simple
|
Type=oneshot
|
||||||
|
RemainAfterExit=yes
|
||||||
ExecStartPre=-/sbin/iw phy phy0 interface add ap0 type __ap
|
ExecStartPre=-/sbin/iw phy phy0 interface add ap0 type __ap
|
||||||
ExecStartPre=-/sbin/ip link set ap0 address {{ ap0_mac_addr }}
|
ExecStartPre=-/sbin/ip link set ap0 address {{ ap0_mac_addr }}
|
||||||
ExecStart=-/sbin/ip link set ap0 up
|
ExecStart=-/sbin/ip link set ap0 up
|
||||||
ExecStopPost=-/sbin/iw dev ap0 del
|
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
|
|
|
@ -7,8 +7,8 @@ Requires=clone-wifi.service
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
Type=forking
|
Type=forking
|
||||||
Restart=on-failure
|
#Restart=on-failure
|
||||||
RestartSec=2
|
#RestartSec=2
|
||||||
PIDFile=/run/hostapd.pid
|
PIDFile=/run/hostapd.pid
|
||||||
ExecStart=/usr/sbin/hostapd -B -P /run/hostapd.pid /etc/hostapd/hostapd.conf
|
ExecStart=/usr/sbin/hostapd -B -P /run/hostapd.pid /etc/hostapd/hostapd.conf
|
||||||
ExecStartPost=-/sbin/ip link set ap0 up
|
ExecStartPost=-/sbin/ip link set ap0 up
|
||||||
|
|
|
@ -10,6 +10,8 @@ Before=netplan-wpa-{{ discovered_wireless_iface }}.service
|
||||||
Before=network.target
|
Before=network.target
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
|
Type=oneshot
|
||||||
|
RemainAfterExit=yes
|
||||||
ExecStart=/sbin/test-wifi
|
ExecStart=/sbin/test-wifi
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue