Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 702182 - www-misc/shellinabox - /etc/init.d/shellinabox: add logging option
Summary: www-misc/shellinabox - /etc/init.d/shellinabox: add logging option
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Patrice Clement
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-12-06 17:33 UTC by Forza
Modified: 2019-12-11 20:40 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Forza 2019-12-06 17:33:54 UTC
www-misc/shellinabox does not support logging other than via stdout and stderr. 
I did this to enable logging through startstopdaemon:

# /etc/conf.d/shellinaboxd
LOGFILE="/var/log/shellinabox.log"


# /etc/init.d/shellinabox
start() {
    ebegin "Starting ${my_daemon}"
    start-stop-daemon \
        --start \
        --background \
        --pidfile ${pidfile} \
        --make-pidfile \
        --exec ${command} \
        -1 ${LOGFILE} -2 ${LOGFILE} \
        -- ${command_args}
    eend $?
}
Comment 1 Forza 2019-12-06 17:39:40 UTC
Of course you need to add --verbose or --debug to "SIAB_OPTS=" in conf.d.
Comment 2 Larry the Git Cow gentoo-dev 2019-12-11 20:40:03 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5ff77dc01dcdf7fac4d59c94b4159fbf903853a0

commit 5ff77dc01dcdf7fac4d59c94b4159fbf903853a0
Author:     Patrice Clement <monsieurp@gentoo.org>
AuthorDate: 2019-12-11 20:34:27 +0000
Commit:     Patrice Clement <monsieurp@gentoo.org>
CommitDate: 2019-12-11 20:39:57 +0000

    www-misc/shellinabox: instruct daemon to log to a file.
    
    Closes: https://bugs.gentoo.org/702182
    Package-Manager: Portage-2.3.79, Repoman-2.3.16
    Signed-off-by: Patrice Clement <monsieurp@gentoo.org>

 www-misc/shellinabox/files/shellinaboxd.conf    | 15 +++++++++------
 www-misc/shellinabox/files/shellinaboxd.init    |  5 +++--
 www-misc/shellinabox/shellinabox-2.20-r1.ebuild |  2 +-
 3 files changed, 13 insertions(+), 9 deletions(-)