Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 24231 Details for
Bug 39023
tightvnc init.d script
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
init.d
vnc (text/plain), 1.46 KB, created by
Luca Barbato
on 2004-01-22 04:38:20 UTC
(
hide
)
Description:
init.d
Filename:
MIME Type:
Creator:
Luca Barbato
Created:
2004-01-22 04:38:20 UTC
Size:
1.46 KB
patch
obsolete
>#!/sbin/runscript ># Copyright 1999-2002 Gentoo Technologies, Inc. ># Distributed under the terms of the GNU General Public License, v2 or later ># $Header: $ > >depend() { > need net >} > >checkconfig() { > if [ -n "${DISPLAYS}" ]; then > if [ $1 = "start" ]; then > local user > for user in $DISPLAYS; do > if eval [ ! -f "~${user%%:*}/.vnc/passwd" ]; then > eerror "There are no passwords defined for user ${user%%:*}." > return 1 > elif [ -e "/tmp/.X11-unix/X${user##*:}" ]; then > eerror "Display :${user##*:} appears to be already in use because of /tmp/.X11-unix/X${user##*:}" > eerror "Remove this file if there is no X server $HOSTNAME:${user##*:}" > return 1 > elif [ -e "/tmp/.X${user##*:}-lock" ]; then > eerror "Display :${user##*:} appears to be already in use because of /tmp/.X${user##*:}-lock" > eerror "Remove this file if there is no X server $HOSTNAME:${user##*:}" > return 1 > fi > done > fi > return 0 > else > eerror 'Please define $DISPLAYS in /etc/conf.d/vnc' > return 1 > fi >} > >start() { > checkconfig start || return 1 > ebegin "Starting TightVNC server" > for user in $DISPLAYS; do > su ${user%%:*} -c "PATH=$PATH:/usr/X11R6/bin vncserver :${user##*:} $VNC_OPTS" &>/dev/null > done > eend $? >} > >stop () { > checkconfig stop || return 2 > ebegin "Stopping TightVNC server" > for user in $DISPLAYS; do > su ${user%%:*} -c "PATH=$PATH:/usr/X11R6/bin vncserver -kill :${user##*:}" &>/dev/null > done > eend $? >} > >restart() { > svc_stop > svc_start >}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 39023
:
24230
| 24231 |
34227
|
34228