Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 25 Dec 2024 11:05:37 +0000
From:      bugzilla-noreply@freebsd.org
To:        ports-bugs@FreeBSD.org
Subject:   [Bug 283590] sysutils/ttyd: rc.d stop command does not work + other issues
Message-ID:  <bug-283590-7788@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D283590

            Bug ID: 283590
           Summary: sysutils/ttyd: rc.d stop command does not work + other
                    issues
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: Individual Port(s)
          Assignee: nc@FreeBSD.org
          Reporter: d8zNeCFG@aon.at
             Flags: maintainer-feedback?(nc@FreeBSD.org)
          Assignee: nc@FreeBSD.org

Scenario:
- FreeBSD 14.2
- ports latest @ a554b7f5985f
- Using portmaster to upgrade ports
- shellinabox gets replaced by sysutils/ttyd
- Configuring ttyd in apache as reverse proxy
- Using the following in /etc/rc.conf:

ttyd_enable=3D"NO"
ttyd_exec=3D"/usr/bin/login"
ttyd_args=3D"-i lo0 -p 7681 -W"

- Starting ttyd using "service ttyd onestart"
- Stopping ttyd using "service ttyd onestop"

Result:
- The ttyd program is terminated
- The daemon progam which manages the ttyd program restarts ttyd after 15
seconds

Expected result:
- The ttyd program and its daemon controller should be terminated

Additional notes:
- The daemon command line uses "-r -R 15". The first "-r" seems to be
superfluous, considering the daemon(8) man page.
- ttyd by default is started without the "-W" flag, rendering the program q=
uite
useless. It would be nice to include a hint that "-W" should be added if
interactive user input is to be supported.
- ttyd by default is set to start /bin/sh. I think it would be better to st=
art
it with /usr/bin/login instead.
- A hint for reverse proxying using apache-2.4 could be added. From 2.4.47,
httpd supports websocket upgrades directly in the mod_proxy module (see
https://httpd.apache.org/docs/2.4/mod/mod_proxy.html). A minimal config for
apache looks like this:

<IfModule proxy_http_module>
<IfModule ssl_module>
    <Location /login>
        SSLRequireSSL
        ProxyPass http://127.0.0.1:7681 upgrade=3Dwebsocket
        ProxyPassReverse http://127.0.0.1:7681
    </Location>
</IfModule>
</IfModule>

-- Martin

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-283590-7788>