@@ -6,28 +6,35 @@ Open Terminal and run the following commands to register the service:
66
77``` bash
88# Register the easytier service using a configuration file
9- sudo serviceman add -name easytier -system \
9+ sudo serviceman add -- name easytier --daemon \
1010--workdir /var/log/easytier \
11- -groupname wheel -username root \
12- -cap-net-bind \
11+ --group wheel --user root \
1312-- easytier-core -c ~ /.config/easytier.toml
1413
1514# Register the easytier service without using a configuration file
16- sudo serviceman add -name easytier -system \
15+ sudo serviceman add -- name easytier --daemon \
1716--workdir /var/log/easytier \
18- -groupname wheel -username root \
19- -cap-net-bind \
17+ --group wheel --user root \
2018-- easytier-core --ipv4 x.x.x.x --network-name xxx --network-secret yyy --peers tcp://peer_host:11010
2119```
2220
2321Start the easytier service:
2422
2523``` bash
26- sudo serviceman start easytier
24+ sudo launchctl start easytier
25+ # Load task, -w option will restart on next login/restart.
26+ launchctl load -w /Library/LaunchDaemons/easytier.plist
2727```
2828
2929Stop the easytier service:
3030
3131``` bash
32- sudo serviceman stop easytier
32+ sudo launchctl stop easytier
33+ # Unload task, -w option will not be executed on next login/restart.
34+ launchctl unload -w /Library/LaunchDaemons/easytier.plist
35+ ```
36+ View Logs:
37+
38+ ``` bash
39+ sudo tail -f /var/log/easytier.log
3340```
0 commit comments