Merge pull request #5 from ichpuchtli/systemd-service
Add systemd service
This commit is contained in:
commit
78adcce380
11
README.md
11
README.md
@ -33,3 +33,14 @@ OR
|
||||
OR
|
||||
|
||||
echo -e "MyAccessPoint\nMyPassPhrase" | ./create_ap -n wlan0
|
||||
|
||||
## Systemd service
|
||||
Using the persistent [systemd](https://wiki.archlinux.org/index.php/systemd#Basic_systemctl_usage) service
|
||||
### Install:
|
||||
# cp create_ap.service /etc/systemd/system
|
||||
|
||||
### Start service immediately:
|
||||
# systemctl start create_ap
|
||||
|
||||
### Start on boot:
|
||||
# systemctl enable create_ap
|
||||
|
12
create_ap.service
Normal file
12
create_ap.service
Normal file
@ -0,0 +1,12 @@
|
||||
[Unit]
|
||||
Description=Create AP Service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
ExecStart=/usr/bin/bash create_ap -n -g 10.0.0.1 wlan0 AccessPointSSID
|
||||
KillSignal=SIGINT
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
Loading…
Reference in New Issue
Block a user