blob: 5c813b07f296b80aabea9a20de53e9e5a8644c5b [file] [log] [blame]
Denys Vlasenkod8330ca2016-09-20 18:09:00 +02001#!/bin/sh
2
3exec 2>&1
4exec </dev/null
5
6pwd="$PWD"
7
8if="${PWD##*/dhcp_}"
9
10echo "* Upping iface $if"
Denys Vlasenkoe17e8d42019-02-02 19:06:19 +010011# "or sleep" idiom prevents rapid respawning if iface does not exist
Denys Vlasenko1e9a4f52019-04-21 14:30:19 +020012ip link set dev "$if" up || exec sleep 5
Denys Vlasenkod8330ca2016-09-20 18:09:00 +020013
14##echo "* Powersave disable on $if"
15##iw dev "$if" set power_save off
16
Denys Vlasenko1e474d32019-04-05 18:38:12 +020017echo "* Starting wpa_supplicant on $if [$$]"
Denys Vlasenkod8330ca2016-09-20 18:09:00 +020018exec \
19env - PATH="$PATH" \
20softlimit \
21setuidgid root \
22wpa_supplicant -i "$if" -c "$pwd/wpa_supplicant.conf" -d