mirror of
https://github.com/shazow/ssh-chat.git
synced 2025-05-22 18:01:25 +03:00
Add systemd service
parent
7bb56b62f0
commit
f6026c2e70
@ -1,4 +1,6 @@
|
|||||||
This page documents how to deploy ssh-chat using various methods
|
This page documents how to deploy ssh-chat using various methods.
|
||||||
|
|
||||||
|
You can run ssh-chat on port 22, but then you'll need to change the port of OpenSSH to something else like 2022. You can do this in `/etc/ssh/sshd_config`. Two services can't run on the same port like this.
|
||||||
|
|
||||||
## OpenRC
|
## OpenRC
|
||||||
|
|
||||||
@ -40,4 +42,26 @@ This page documents how to deploy ssh-chat using various methods
|
|||||||
|
|
||||||
# systemd
|
# systemd
|
||||||
|
|
||||||
|
(Replace `/PATH/TO/`)
|
||||||
|
|
||||||
|
`/etc/systemd/system/ssh-chat.service`:
|
||||||
|
|
||||||
|
```
|
||||||
|
[Unit]
|
||||||
|
Description=ssh-chat
|
||||||
|
After=network.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=simple
|
||||||
|
User=nobody
|
||||||
|
ExecStart=/PATH/TO/ssh-chat --bind=":22" -i="/PATH/TO/host_key" --admin="/PATH/TO/authorized_keys"
|
||||||
|
AmbientCapabilities=CAP_NET_BIND_SERVICE
|
||||||
|
Restart=always
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
|
```
|
||||||
|
|
||||||
|
Additional resources:
|
||||||
|
|
||||||
- https://impactcore.blogspot.ca/2017/09/ssh-chat-irc-like-chat-client-over-ssh.html
|
- https://impactcore.blogspot.ca/2017/09/ssh-chat-irc-like-chat-client-over-ssh.html
|
||||||
|
Loading…
x
Reference in New Issue
Block a user