mirror of
https://github.com/EasyTier/easytier.github.io.git
synced 2025-05-19 10:27:06 +00:00
1.0 KiB
1.0 KiB
Installing as a Linux Systemd Service
On Linux distributions that support systemd, you can configure the service to start automatically with the system by following these steps:
- Create a new service file at
/etc/systemd/system/easytier.serviceand modify the command line parameters afterExecStartas needed.
[Unit]
Description=EasyTier Service
After=network.target syslog.target
Wants=network.target
[Service]
Type=simple
ExecStart=/root/easytier-core --ipv4 x.x.x.x --network-name xxx --network-secret yyy --peers tcp://peer_host:11010
[Install]
WantedBy=multi-user.target
- After saving the file, run the following command in the terminal to enable the service:
systemctl enable easytier.service
- You can start and stop the service using the following commands:
systemctl start easytier.service
systemctl stop easytier.service
Please note that using the systemctl command instead of the service command is the more modern approach, and it is recommended to use it on systems that support systemd.