Denys Vlasenko | d32a1a4 | 2015-10-24 05:30:58 +0200 | [diff] [blame] | 1 | #!/bin/sh |
| 2 | |
| 3 | exec 2>&1 |
| 4 | exec </dev/null |
| 5 | |
| 6 | pwd="$PWD" |
| 7 | |
| 8 | if="${PWD##*/zcip_}" |
| 9 | |
| 10 | echo "* Upping iface $if" |
Denys Vlasenko | 1e9a4f5 | 2019-04-21 14:30:19 +0200 | [diff] [blame] | 11 | ip link set dev "$if" up || exec sleep 5 |
Denys Vlasenko | d32a1a4 | 2015-10-24 05:30:58 +0200 | [diff] [blame] | 12 | |
Denys Vlasenko | 1e474d3 | 2019-04-05 18:38:12 +0200 | [diff] [blame] | 13 | echo "* Starting zcip on $if [$$]" |
Denys Vlasenko | d32a1a4 | 2015-10-24 05:30:58 +0200 | [diff] [blame] | 14 | exec \ |
| 15 | env - PATH="$PATH" \ |
| 16 | softlimit \ |
| 17 | setuidgid root \ |
| 18 | zcip -fvv \ |
| 19 | "$if" \ |
| 20 | "$pwd/zcip_handler" |