2017-05-27 18:09:50 +00:00
|
|
|
[Unit]
|
|
|
|
Description=Hostapd IEEE 802.11 AP, IEEE 802.1X/WPA/WPA2/EAP/RADIUS Authenticator
|
2019-08-08 18:04:48 +00:00
|
|
|
Wants=network-pre.target
|
2020-02-26 08:21:27 +00:00
|
|
|
After=network-pre.target
|
2020-03-10 05:38:58 +00:00
|
|
|
{% if is_raspbian %}
|
2020-02-26 08:21:27 +00:00
|
|
|
Before=dhcpcd.service
|
|
|
|
{% endif %}
|
|
|
|
Before=network.target
|
2017-05-27 18:09:50 +00:00
|
|
|
|
|
|
|
[Service]
|
|
|
|
Type=idle
|
|
|
|
PIDFile=/run/hostapd.pid
|
2018-12-31 06:51:29 +00:00
|
|
|
ExecStartPre=-/sbin/iw phy phy0 interface add ap0 type __ap
|
|
|
|
ExecStartPre=-/sbin/ip link set ap0 address {{ ap0_mac_addr }}
|
2018-08-21 16:17:30 +00:00
|
|
|
ExecStart=/usr/sbin/hostapd -P /run/hostapd.pid /etc/hostapd/hostapd.conf
|
2020-02-26 08:21:27 +00:00
|
|
|
ExecStartPost=-/sbin/ip link set ap0 up
|
|
|
|
ExecStopPost=-/sbin/iw dev ap0 del
|
2017-05-27 18:09:50 +00:00
|
|
|
|
|
|
|
[Install]
|
|
|
|
WantedBy=multi-user.target
|