summaryrefslogtreecommitdiffstats
path: root/net-misc/xrdp/files/xrdp-initd
diff options
context:
space:
mode:
Diffstat (limited to 'net-misc/xrdp/files/xrdp-initd')
-rw-r--r--net-misc/xrdp/files/xrdp-initd28
1 files changed, 28 insertions, 0 deletions
diff --git a/net-misc/xrdp/files/xrdp-initd b/net-misc/xrdp/files/xrdp-initd
new file mode 100644
index 0000000..8f943e1
--- /dev/null
+++ b/net-misc/xrdp/files/xrdp-initd
@@ -0,0 +1,28 @@
+#!/sbin/openrc-run
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+depend() {
+ use net logger
+}
+
+start() {
+ ebegin "Starting X remote desktop daemon"
+ start-stop-daemon --start --pidfile /var/run/xrdp.pid --exec /usr/sbin/xrdp > /dev/null
+ eend $? || return $?
+
+ ebegin "Starting remote desktop session manager"
+ start-stop-daemon --start --pidfile /var/run/xrdp-sesman.pid --exec /usr/sbin/xrdp-sesman > /dev/null
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping X remote desktop daemon"
+ start-stop-daemon --stop --pidfile /var/run/xrdp.pid
+ eend $?
+
+ ebegin "Stopping remote desktop session manager"
+ start-stop-daemon --stop --pidfile /var/run/xrdp-sesman.pid
+ eend $?
+}