You've already forked Rustdesk-Server
Initialize Git Repository: 'Rustdesk-Server'
All checks were successful
Rustdesk Server (Bookworm) / Rustdesk Server [arm64] (push) Successful in 19s
Rustdesk Server (Bookworm) / Rustdesk Server [amd64] (push) Successful in 20s
Rustdesk Server (Noble) / Rustdesk Server [arm64] (push) Successful in 19s
Rustdesk Server (Noble) / Rustdesk Server [amd64] (push) Successful in 20s
Rustdesk Server (Trixie) / Rustdesk Server [arm64] (push) Successful in 17s
Rustdesk Server (Trixie) / Rustdesk Server [amd64] (push) Successful in 28s
All checks were successful
Rustdesk Server (Bookworm) / Rustdesk Server [arm64] (push) Successful in 19s
Rustdesk Server (Bookworm) / Rustdesk Server [amd64] (push) Successful in 20s
Rustdesk Server (Noble) / Rustdesk Server [arm64] (push) Successful in 19s
Rustdesk Server (Noble) / Rustdesk Server [amd64] (push) Successful in 20s
Rustdesk Server (Trixie) / Rustdesk Server [arm64] (push) Successful in 17s
Rustdesk Server (Trixie) / Rustdesk Server [amd64] (push) Successful in 28s
This commit is contained in:
2
root/DEBIAN/conffiles
Normal file
2
root/DEBIAN/conffiles
Normal file
@@ -0,0 +1,2 @@
|
||||
/etc/rustdesk/relay.conf
|
||||
/etc/rustdesk/signal.conf
|
||||
9
root/DEBIAN/control
Normal file
9
root/DEBIAN/control
Normal file
@@ -0,0 +1,9 @@
|
||||
Package: rustdesk-server
|
||||
Version: 1.1.15
|
||||
Architecture:
|
||||
Installed-Size:
|
||||
Priority: optional
|
||||
Section: misc
|
||||
Homepage: http://www.privlab.it
|
||||
Maintainer: PrivLab <repository@privlab.it>
|
||||
Description: RustDesk [Relay|ID/Rendezvous] Server
|
||||
70
root/DEBIAN/postinst
Normal file
70
root/DEBIAN/postinst
Normal file
@@ -0,0 +1,70 @@
|
||||
#!/usr/bin/sh
|
||||
|
||||
set -e
|
||||
set -u
|
||||
|
||||
if [ -d '/run/systemd/system' ]; then
|
||||
/usr/bin/systemctl --system daemon-reload > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
fi
|
||||
|
||||
case "${1}" in
|
||||
configure)
|
||||
if [ -x '/usr/bin/deb-systemd-helper' ]; then
|
||||
/usr/bin/deb-systemd-helper unmask 'rustdesk-hbbr.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
/usr/bin/deb-systemd-helper unmask 'rustdesk-hbbs.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
fi
|
||||
if /usr/bin/deb-systemd-helper --quiet was-enabled 'rustdesk-hbbr.service'; then
|
||||
/usr/bin/deb-systemd-helper enable 'rustdesk-hbbr.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
else
|
||||
/usr/bin/deb-systemd-helper update-state 'rustdesk-hbbr.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
fi
|
||||
if /usr/bin/deb-systemd-helper --quiet was-enabled 'rustdesk-hbbs.service'; then
|
||||
/usr/bin/deb-systemd-helper enable 'rustdesk-hbbs.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
else
|
||||
/usr/bin/deb-systemd-helper update-state 'rustdesk-hbbs.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
fi
|
||||
if [ -x '/etc/init.d/rustdesk-hbbr' ]; then
|
||||
/usr/sbin/update-rc.d 'rustdesk-hbbr' defaults > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
fi
|
||||
if [ -x '/etc/init.d/rustdesk-hbbs' ]; then
|
||||
/usr/sbin/update-rc.d 'rustdesk-hbbs' defaults > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
fi
|
||||
/usr/bin/install --directory --group='rustdesk' --mode='750' --owner='rustdesk' '/var/lib/rustdesk'
|
||||
/usr/bin/install --directory --group='rustdesk' --mode='750' --owner='rustdesk' '/var/log/rustdesk'
|
||||
/usr/bin/install --directory --group='rustdesk' --mode='750' --owner='rustdesk' '/var/logrotate/rustdesk'
|
||||
/usr/bin/chown --quiet --recursive 'rustdesk':'root' '/etc/rustdesk'
|
||||
if [ ! -f '/etc/rustdesk/keypair' ]; then
|
||||
KEYPAIR=''
|
||||
while [ -z "${KEYPAIR}" ]; do
|
||||
KEYPAIR=$(/usr/bin/rustdesk-utils genkeypair)
|
||||
done
|
||||
PUBLICKEY=$(/usr/bin/echo "${KEYPAIR}" | /usr/bin/grep 'Secret Key:' | /usr/bin/sed --expression='s/Secret Key: //')
|
||||
/usr/bin/echo "${KEYPAIR}" > '/etc/rustdesk/keypair'
|
||||
/usr/bin/chmod --quiet --verbose '0440' '/etc/rustdesk/keypair'
|
||||
/usr/bin/sed --quiet --in-place --expression="s/KEY=.*/KEY='${PUBLICKEY}'/" '/etc/rustdesk/relay.conf'
|
||||
/usr/bin/sed --quiet --in-place --expression="s/KEY=.*/KEY='${PUBLICKEY}'/" '/etc/rustdesk/signal.conf'
|
||||
fi
|
||||
if [ -x '/usr/bin/deb-systemd-invoke' ]; then
|
||||
/usr/bin/systemctl --system daemon-reload > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
if [ -n "${2}" ]; then
|
||||
_dh_action='restart'
|
||||
else
|
||||
_dh_action='start'
|
||||
fi
|
||||
/usr/bin/deb-systemd-invoke "${_dh_action}" 'rustdesk-hbbr.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
/usr/bin/deb-systemd-invoke "${_dh_action}" 'rustdesk-hbbs.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
43
root/DEBIAN/postrm
Normal file
43
root/DEBIAN/postrm
Normal file
@@ -0,0 +1,43 @@
|
||||
#!/usr/bin/sh
|
||||
|
||||
set -e
|
||||
set -u
|
||||
|
||||
if [ -d '/run/systemd/system' ]; then
|
||||
/usr/bin/systemctl --system daemon-reload > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
fi
|
||||
|
||||
case "${1}" in
|
||||
remove)
|
||||
if [ -x '/usr/bin/deb-systemd-helper' ]; then
|
||||
/usr/bin/deb-systemd-helper mask 'rustdesk-hbbs.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
/usr/bin/deb-systemd-helper mask 'rustdesk-hbbr.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
fi
|
||||
;;
|
||||
purge)
|
||||
if [ -x '/usr/bin/deb-systemd-helper' ]; then
|
||||
/usr/bin/deb-systemd-helper purge 'rustdesk-hbbs.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
/usr/bin/deb-systemd-helper unmask 'rustdesk-hbbs.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
/usr/bin/deb-systemd-helper purge 'rustdesk-hbbr.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
/usr/bin/deb-systemd-helper unmask 'rustdesk-hbbr.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
fi
|
||||
if /usr/bin/getent passwd 'rustdesk' > '/dev/null'; then
|
||||
/usr/sbin/deluser 'rustdesk' > '/dev/null' 2>&1
|
||||
fi
|
||||
if /usr/bin/getent group 'rustdesk' > '/dev/null'; then
|
||||
/usr/sbin/deluser --group 'rustdesk' > '/dev/null' 2>&1
|
||||
fi
|
||||
/usr/bin/rm --force '/etc/rustdesk/keypair'
|
||||
/usr/bin/rm --force --recursive '/var/lib/rustdesk'
|
||||
;;
|
||||
esac
|
||||
|
||||
/usr/bin/rm --force --recursive '/var/log/rustdesk'
|
||||
/usr/bin/rm --force --recursive '/var/logrotate/rustdesk'
|
||||
20
root/DEBIAN/preinst
Normal file
20
root/DEBIAN/preinst
Normal file
@@ -0,0 +1,20 @@
|
||||
#!/usr/bin/sh
|
||||
|
||||
set -e
|
||||
set -u
|
||||
|
||||
case "${1}" in
|
||||
install)
|
||||
if ! /usr/bin/getent passwd 'rustdesk' > '/dev/null' 2>&1; then
|
||||
/usr/sbin/adduser --quiet \
|
||||
--system \
|
||||
--home '/var/lib/rustdesk' \
|
||||
--shell '/usr/sbin/nologin' \
|
||||
--no-create-home \
|
||||
--group \
|
||||
--disabled-password \
|
||||
--disabled-login \
|
||||
'rustdesk' > '/dev/null' 2>&1
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
28
root/DEBIAN/prerm
Normal file
28
root/DEBIAN/prerm
Normal file
@@ -0,0 +1,28 @@
|
||||
#!/usr/bin/sh
|
||||
|
||||
set -e
|
||||
set -u
|
||||
|
||||
case "${1}" in
|
||||
remove)
|
||||
if [ -x '/usr/bin/deb-systemd-invoke' ]; then
|
||||
/usr/bin/deb-systemd-invoke stop 'rustdesk-hbbs.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
/usr/bin/deb-systemd-invoke disable 'rustdesk-hbbs.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
/usr/bin/deb-systemd-invoke stop 'rustdesk-hbbr.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
/usr/bin/deb-systemd-invoke disable 'rustdesk-hbbr.service' > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
fi
|
||||
if [ -x '/etc/init.d/rustdesk-hbbs' ]; then
|
||||
/usr/sbin/update-rc.d 'rustdesk-hbbs' remove > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
fi
|
||||
if [ -x '/etc/init.d/rustdesk-hbbr' ]; then
|
||||
/usr/sbin/update-rc.d 'rustdesk-hbbr' remove > '/dev/null' 2>&1 || \
|
||||
/usr/bin/true
|
||||
fi
|
||||
/usr/bin/rm --force '/etc/rustdesk/keypair'
|
||||
;;
|
||||
esac
|
||||
86
root/etc/init.d/rustdesk-hbbr
Normal file
86
root/etc/init.d/rustdesk-hbbr
Normal file
@@ -0,0 +1,86 @@
|
||||
#!/usr/bin/sh
|
||||
|
||||
### BEGIN INIT INFO
|
||||
# Provides: rustdesk-hbbr
|
||||
# Required-Start: $local_fs $network $remote_fs
|
||||
# Required-Stop: $local_fs $network $remote_fs
|
||||
# Default-Start: 2 3 4 5
|
||||
# Default-Stop: 0 1 6
|
||||
# Short-Description: RustDesk Relay Server
|
||||
# Description: RustDesk is a full-featured open source remote control
|
||||
# alternative for self-hosting and security with minimal
|
||||
# configuration.
|
||||
### END INIT INFO
|
||||
|
||||
NAME='rustdesk-hbbr'
|
||||
DESC='RustDesk Relay Server'
|
||||
USER='rustdesk'
|
||||
GROUP='rustdesk'
|
||||
PIDFOLDER="/run/${NAME}"
|
||||
PIDFILE="${PIDFOLDER}/${NAME}.pid"
|
||||
DAEMON='/usr/sbin/hbbr'
|
||||
DAEMON_CONFIG='/etc/rustdesk/relay.conf'
|
||||
export DB_URL='/var/lib/rustdesk/server.sqlite'
|
||||
|
||||
set -e
|
||||
|
||||
[ -f "${DAEMON_CONFIG}" ]
|
||||
|
||||
. "${DAEMON_CONFIG}"
|
||||
. '/lib/lsb/init-functions'
|
||||
|
||||
[ -x "${DAEMON}" ]
|
||||
|
||||
DAEMON_OPTS="--key ${KEY} --port ${PORT}"
|
||||
|
||||
case "${1}" in
|
||||
start)
|
||||
/usr/bin/install --directory --group="${GROUP}" ---mode='0755' --owner="${USER}" "${PIDFOLDER}"
|
||||
log_daemon_msg "Starting ${DESC}" "${NAME}"
|
||||
if /usr/sbin/start-stop-daemon --quiet \
|
||||
--start \
|
||||
--oknodo \
|
||||
--make-pidfile \
|
||||
--pidfile "${PIDFILE}" \
|
||||
--user "${USER}" \
|
||||
--group "${GROUP}" \
|
||||
--exec "${DAEMON}" -- "${DAEMON_OPTS}"; then
|
||||
log_end_msg 0
|
||||
else
|
||||
log_end_msg 1
|
||||
/usr/bin/test -f "${PIDFILE}" && \
|
||||
/usr/bin/rm --force "${PIDFILE}"
|
||||
fi
|
||||
;;
|
||||
stop)
|
||||
log_daemon_msg "Stopping ${DESC}" "${NAME}"
|
||||
if /usr/sbin/start-stop-daemon --quiet \
|
||||
--stop \
|
||||
--oknodo \
|
||||
--retry 30 \
|
||||
--remove-pidfile \
|
||||
--pidfile "${PIDFILE}" \
|
||||
--user "${USER}" \
|
||||
--group "${GROUP}" \
|
||||
--exec "${DAEMON}"; then
|
||||
/usr/bin/test -f "${PIDFILE}" && \
|
||||
/usr/bin/rm --force "${PIDFILE}"
|
||||
log_end_msg 0
|
||||
else
|
||||
log_end_msg 1
|
||||
fi
|
||||
;;
|
||||
restart)
|
||||
"${0}" stop
|
||||
"${0}" start
|
||||
;;
|
||||
status)
|
||||
status_of_proc -p "${PIDFILE}" "${DAEMON}" "${NAME}" && \
|
||||
exit 0 || \
|
||||
exit "${?}"
|
||||
;;
|
||||
*)
|
||||
echo "Usage: /etc/init.d/${NAME} {start|stop|restart|status}" >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
86
root/etc/init.d/rustdesk-hbbs
Normal file
86
root/etc/init.d/rustdesk-hbbs
Normal file
@@ -0,0 +1,86 @@
|
||||
#!/usr/bin/sh
|
||||
|
||||
### BEGIN INIT INFO
|
||||
# Provides: rustdesk-hbbs
|
||||
# Required-Start: $local_fs $network $remote_fs
|
||||
# Required-Stop: $local_fs $network $remote_fs
|
||||
# Default-Start: 2 3 4 5
|
||||
# Default-Stop: 0 1 6
|
||||
# Short-Description: RustDesk ID/Rendezvous Server
|
||||
# Description: RustDesk is a full-featured open source remote control
|
||||
# alternative for self-hosting and security with minimal
|
||||
# configuration.
|
||||
### END INIT INFO
|
||||
|
||||
NAME='rustdesk-hbbs'
|
||||
DESC='RustDesk ID/Rendezvous Server'
|
||||
USER='rustdesk'
|
||||
GROUP='rustdesk'
|
||||
PIDFOLDER="/run/${NAME}"
|
||||
PIDFILE="${PIDFOLDER}/${NAME}.pid"
|
||||
DAEMON='/usr/sbin/hbbs'
|
||||
DAEMON_CONFIG='/etc/rustdesk/signal.conf'
|
||||
export DB_URL='/var/lib/rustdesk/server.sqlite'
|
||||
|
||||
set -e
|
||||
|
||||
[ -f "${DAEMON_CONFIG}" ]
|
||||
|
||||
. "${DAEMON_CONFIG}"
|
||||
. '/lib/lsb/init-functions'
|
||||
|
||||
[ -x "${DAEMON}" ]
|
||||
|
||||
DAEMON_OPTS="--key ${KEY} --port ${PORT} --relay-servers ${RELAY_SERVER} --rmem ${RMEM}"
|
||||
|
||||
case "${1}" in
|
||||
start)
|
||||
/usr/bin/install --directory --group="${GROUP}" ---mode='0755' --owner="${USER}" "${PIDFOLDER}"
|
||||
log_daemon_msg "Starting ${DESC}" "${NAME}"
|
||||
if /usr/sbin/start-stop-daemon --quiet \
|
||||
--start \
|
||||
--oknodo \
|
||||
--make-pidfile \
|
||||
--pidfile "${PIDFILE}" \
|
||||
--user "${USER}" \
|
||||
--group "${GROUP}" \
|
||||
--exec "${DAEMON}" -- "${DAEMON_OPTS}"; then
|
||||
log_end_msg 0
|
||||
else
|
||||
log_end_msg 1
|
||||
/usr/bin/test -f "${PIDFILE}" && \
|
||||
/usr/bin/rm --force "${PIDFILE}"
|
||||
fi
|
||||
;;
|
||||
stop)
|
||||
log_daemon_msg "Stopping ${DESC}" "${NAME}"
|
||||
if /usr/sbin/start-stop-daemon --quiet \
|
||||
--stop \
|
||||
--oknodo \
|
||||
--retry 30 \
|
||||
--remove-pidfile \
|
||||
--pidfile "${PIDFILE}" \
|
||||
--user "${USER}" \
|
||||
--group "${GROUP}" \
|
||||
--exec "${DAEMON}"; then
|
||||
/usr/bin/test -f "${PIDFILE}" && \
|
||||
/usr/bin/rm --force "${PIDFILE}"
|
||||
log_end_msg 0
|
||||
else
|
||||
log_end_msg 1
|
||||
fi
|
||||
;;
|
||||
restart)
|
||||
"${0}" stop
|
||||
"${0}" start
|
||||
;;
|
||||
status)
|
||||
status_of_proc -p "${PIDFILE}" "${DAEMON}" "${NAME}" && \
|
||||
exit 0 || \
|
||||
exit "${?}"
|
||||
;;
|
||||
*)
|
||||
echo "Usage: /etc/init.d/${NAME} {start|stop|restart|status}" >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
71
root/etc/logrotate.d/rustdesk
Normal file
71
root/etc/logrotate.d/rustdesk
Normal file
@@ -0,0 +1,71 @@
|
||||
/var/log/rustdesk/*.log {
|
||||
# Truncate the original log file in place after creating a copy,
|
||||
# instead of moving the old log file and optionally creating a
|
||||
# new one. It can be used when some program cannot be told to
|
||||
# close its logfile and thus might continue writing (appending)
|
||||
# to the previous log file forever. Note that there is a very
|
||||
# small time slice between copying the file and truncating it, so
|
||||
# some logging data might be lost. When this option is used, the
|
||||
# create option will have no effect, as the old log file stays in
|
||||
# place.
|
||||
copytruncate
|
||||
|
||||
# Log files are rotated every day.
|
||||
daily
|
||||
|
||||
# Archive old versions of log files adding a daily extension like
|
||||
# YYYYMMDD instead of simply adding a number. The extension may
|
||||
# be configured using the dateformat option.
|
||||
dateext
|
||||
|
||||
# Specify the extension for dateext using the notation similar to
|
||||
# strftime(3) function. Only %Y %m %d and %s specifiers are allowed.
|
||||
# The default value is -%Y%m%d. Note that also the character
|
||||
# separating log name from the extension is part of the dateformat
|
||||
# string. The system clock must be set past Sep 9th 2001 for %s to
|
||||
# work correctly. Note that the datestamps generated by this format
|
||||
# must be lexically sortable (i.e., first the year, then the month
|
||||
# then the day. e.g., 2001/12/01 is ok, but 01/12/2001 is not, since
|
||||
# 01/11/2002 would sort lower while it is later). This is because when
|
||||
# using the rotate option, logrotate sorts all rotated filenames to
|
||||
# find out which logfiles are older and should be removed.
|
||||
dateformat .%Y-%m-%d
|
||||
|
||||
# Use yesterday's instead of today's date to create the dateext
|
||||
# extension, so that the rotated log file has a date in its name that
|
||||
# is the same as the timestamps within it.
|
||||
dateyesterday
|
||||
|
||||
# Postpone compression of the previous log file to the next rotation
|
||||
# cycle. This only has effect when used in combination with compress.
|
||||
# It can be used when some program cannot be told to close its logfile
|
||||
# and thus might continue writing to the previous log file for some time.
|
||||
delaycompress
|
||||
|
||||
# Do not copy the original log file and leave it in place.
|
||||
nocopy
|
||||
|
||||
# New log files are not created.
|
||||
nocreate
|
||||
|
||||
# Don't mail old log files to any address.
|
||||
nomail
|
||||
|
||||
# Do not use shred when deleting old log files.
|
||||
noshred
|
||||
|
||||
# Do not rotate the log if it is empty.
|
||||
notifempty
|
||||
|
||||
# Logs are moved into directory for rotation. The directory must be on the
|
||||
# same physical device as the log file being rotated, and is assumed to be
|
||||
# relative to the directory holding the log file unless an absolute path
|
||||
# name is specified. When this option is used all old versions of the log
|
||||
# end up in directory.
|
||||
olddir /var/logrotate/rustdesk
|
||||
|
||||
# Log files are rotated count times before being removed or mailed to the
|
||||
# address specified in a mail directive. If count is 0, old versions are
|
||||
# removed rather than rotated.
|
||||
rotate 7
|
||||
}
|
||||
7
root/etc/rustdesk/relay.conf
Normal file
7
root/etc/rustdesk/relay.conf
Normal file
@@ -0,0 +1,7 @@
|
||||
# RustDesk Relay Server (hbbr) configuration
|
||||
|
||||
# Only allow the client with the same key.
|
||||
KEY=''
|
||||
|
||||
# Sets the listening port.
|
||||
PORT='21117'
|
||||
15
root/etc/rustdesk/signal.conf
Normal file
15
root/etc/rustdesk/signal.conf
Normal file
@@ -0,0 +1,15 @@
|
||||
# RustDesk ID/Rendezvous Server (hbbs) configuration
|
||||
|
||||
# Only allow the client with the same key.
|
||||
KEY=''
|
||||
|
||||
# Sets the listening port.
|
||||
PORT='21116'
|
||||
|
||||
# Sets the default relay servers.
|
||||
RELAY_SERVER='localhost'
|
||||
|
||||
# Sets UDP recv buffer size.
|
||||
# Set system rmem_max first!
|
||||
# e.g. 'sysctl -w net.core.rmem_max=52428800'
|
||||
RMEM='0'
|
||||
29
root/lib/systemd/system/rustdesk-hbbr.service
Normal file
29
root/lib/systemd/system/rustdesk-hbbr.service
Normal file
@@ -0,0 +1,29 @@
|
||||
[Unit]
|
||||
Description=RustDesk Relay Server
|
||||
ConditionFileNotEmpty=/etc/rustdesk/relay.conf
|
||||
After=network.target network-online.target rustdesk-hbbs.service
|
||||
Wants=rustdesk-hbbs.service
|
||||
Requires=network.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
Environment=DB_URL=/var/lib/rustdesk/server.sqlite
|
||||
EnvironmentFile=/etc/rustdesk/relay.conf
|
||||
ExecStart=/usr/sbin/hbbr --key "${KEY}" --port "${PORT}"
|
||||
ExecStartPost=/usr/bin/sh -c "umask '022'; /usr/bin/pgrep -n 'hbbr' > '/run/rustdesk/rustdesk-hbbr.pid'"
|
||||
ExecStop=/usr/bin/rm -f '/run/rustdesk/rustdesk-hbbr.pid'
|
||||
User=rustdesk
|
||||
Group=rustdesk
|
||||
PrivateDevices=true
|
||||
PrivateTmp=true
|
||||
ProtectSystem=strict
|
||||
ReadWriteDirectories=/var/lib/rustdesk
|
||||
RuntimeDirectory=rustdesk
|
||||
RuntimeDirectoryMode=755
|
||||
RuntimeDirectoryPreserve=yes
|
||||
StandardOutput=append:/var/log/rustdesk/hbbr.log
|
||||
StandardError=append:/var/log/rustdesk/hbbr-error.log
|
||||
WorkingDirectory=/var/lib/rustdesk
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
28
root/lib/systemd/system/rustdesk-hbbs.service
Normal file
28
root/lib/systemd/system/rustdesk-hbbs.service
Normal file
@@ -0,0 +1,28 @@
|
||||
[Unit]
|
||||
Description=RustDesk ID/Rendezvous Server
|
||||
ConditionFileNotEmpty=/etc/rustdesk/signal.conf
|
||||
After=network.target network-online.target
|
||||
Requires=network.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
Environment=DB_URL=/var/lib/rustdesk/server.sqlite
|
||||
EnvironmentFile=/etc/rustdesk/signal.conf
|
||||
ExecStart=/usr/sbin/hbbs --key "${KEY}" --port "${PORT}" --relay-servers "${RELAY_SERVER}" --rmem "${RMEM}"
|
||||
ExecStartPost=/usr/bin/sh -c "umask '022'; /usr/bin/pgrep -n 'hbbs' > '/run/rustdesk/rustdesk-hbbs.pid'"
|
||||
ExecStop=/usr/bin/rm -f '/run/rustdesk/rustdesk-hbbs.pid'
|
||||
User=rustdesk
|
||||
Group=rustdesk
|
||||
PrivateDevices=true
|
||||
PrivateTmp=true
|
||||
ProtectSystem=strict
|
||||
ReadWriteDirectories=/var/lib/rustdesk
|
||||
RuntimeDirectory=rustdesk
|
||||
RuntimeDirectoryMode=755
|
||||
RuntimeDirectoryPreserve=yes
|
||||
StandardOutput=append:/var/log/rustdesk/hbbs.log
|
||||
StandardError=append:/var/log/rustdesk/hbbs-error.log
|
||||
WorkingDirectory=/var/lib/rustdesk
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
2
root/usr/lib/sysusers.d/rustdesk-server.conf
Normal file
2
root/usr/lib/sysusers.d/rustdesk-server.conf
Normal file
@@ -0,0 +1,2 @@
|
||||
g rustdesk - -
|
||||
u rustdesk - "rustdesk" /var/lib/rustdesk /usr/sbin/nologin
|
||||
Reference in New Issue
Block a user