mirror of
https://github.com/gravitational/teleport
synced 2024-10-20 17:23:22 +00:00
0d6adaa50a
Actual LimitNOFILE varies greatly between the systems as it depends on the systemd version and the go version used to build Teleport. The goal of this commit is to run Teleport in the same setup, regardless of the distro nor Teleport version. New systemd defaults are 1024:524288, and starting with go 1.19, go process can increase their soft limit up to the hard limmit dynamically. Old systemd versions don't suppoprt `soft:hard` notation and old go versions don't automatically increase up to the hard limit. For this reasons, the most compatible setting is to set softlimit=hardlimit=524288.
18 lines
347 B
Desktop File
18 lines
347 B
Desktop File
[Unit]
|
|
Description=Teleport SSH server
|
|
After=network.target
|
|
|
|
[Service]
|
|
Type=simple
|
|
Restart=always
|
|
RestartSec=5
|
|
ExecStartPre=/bin/mkdir -p -m0700 /var/lib/teleport
|
|
ExecStart=/usr/local/bin/teleport start -c /opt/teleport/teleport.yaml
|
|
MountFlags=slave
|
|
LimitNOFILE=524288
|
|
LimitNPROC=1048576
|
|
LimitCORE=infinity
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target
|