1
0
mirror of https://github.com/ipfs/kubo.git synced 2025-08-06 19:44:01 +08:00

implement systemd socket activation

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
This commit is contained in:
Steven Allen
2018-09-23 21:47:30 -07:00
parent 9ea7c6a111
commit 429c4b537c
8 changed files with 173 additions and 50 deletions

View File

@ -0,0 +1,15 @@
# Enabling this will *completely override* any API listeners configured in your
# config.
[Unit]
Description=IPFS API Socket
[Socket]
Service=ipfs.service
FileDescriptorName=io.ipfs.api
BindIPv6Only=true
ListenStream=127.0.0.1:5001
ListenStream=[::1]:5001
[Install]
WantedBy=sockets.target

View File

@ -0,0 +1,15 @@
# Enabling this will *completely override* any Gateway listeners configured in
# your config.
[Unit]
Description=IPFS Gateway Socket
[Socket]
Service=ipfs.service
FileDescriptorName=io.ipfs.gateway
BindIPv6Only=true
ListenStream=127.0.0.1:8080
ListenStream=[::1]:8080
[Install]
WantedBy=sockets.target

View File

@ -0,0 +1,9 @@
[Unit]
Description=IPFS Daemon
[Service]
ExecStart=/usr/bin/ipfs daemon --init --migrate
KillSignal=SIGINT
[Install]
WantedBy=default.target