| # Copyright 2014 The Chromium OS Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| description "Run the access point manager daemon" |
| author "chromium-os-dev@chromium.org" |
| |
| start on starting system-services |
| stop on stopping system-services |
| expect fork |
| |
| env APMANAGER_LOG_LEVEL=0 |
| |
| pre-start script |
| # Create directory for storing config files. |
| mkdir -m 0755 -p /var/run/apmanager/hostapd |
| mkdir -m 0755 -p /var/run/apmanager/dnsmasq |
| chown -R apmanager:apmanager /var/run/apmanager/hostapd |
| chown -R apmanager:apmanager /var/run/apmanager/dnsmasq |
| end script |
| |
| exec /usr/bin/apmanager --v="${APMANAGER_LOG_LEVEL}" |