1
0

better configuration

This commit is contained in:
Anna Christina Naß
2026-04-09 13:31:48 +02:00
parent b841f0b1a8
commit 11aa0dc702
2 changed files with 19 additions and 14 deletions

View File

@@ -20,18 +20,25 @@ EXPOSE 80
WORKDIR /opt/websockify WORKDIR /opt/websockify
ENV LOCALPORT="80" ENV WSHOST="window.location.hostname"
ENV WSPORT="80"
ENV DEST="box.imzadi.de:23" ENV DEST="box.imzadi.de:23"
ENV OPTS="--web /web" ENV OPTS="--web /web"
RUN cat <<'EOF' > /entrypoint.sh RUN cat <<'EOF' > /entrypoint.sh
#!/bin/sh #!/bin/sh
echo "Websockify" echo "Websockify Container"
echo "----------" echo "--------------------"
echo "Options : $OPTS" echo "Container Host : $WSHOST"
echo "Local Port : $LOCALPORT" echo "Container Port : $WSPORT"
echo "Destination: $DEST" echo "Destination : $DEST"
/usr/local/bin/websockify $OPTS $LOCALPORT $DEST echo "Options : $OPTS"
/usr/local/bin/websockify $OPTS 80 $DEST
EOF
RUN cat <<'EOF' > /web/config.js
var wshost=$WSHOST;
var wsport=$WSPORT;
EOF EOF
RUN chmod +x /entrypoint.sh RUN chmod +x /entrypoint.sh

View File

@@ -12,15 +12,11 @@
<div id="fTelnetContainer"></div> <div id="fTelnetContainer"></div>
<script src="ftelnet.norip.xfer.min.js" id="fTelnetScript"></script> <script src="ftelnet.norip.xfer.min.js" id="fTelnetScript"></script>
<script src="config.js" id="fTelnetScript"></script>
<script> <script>
var Options = new fTelnetOptions(); var Options = new fTelnetOptions();
Options.Hostname = window.location.hostname; Options.Hostname = wshost;
Options.Port = 8006; Options.Port = wsport;
//Options.ProxyHostname = 'sinclair.narnia.11101.de';
//Options.ProxyPort = 8006;
Options.ScreenRows = 25;
var Client = new fTelnetClient('fTelnetContainer', Options); var Client = new fTelnetClient('fTelnetContainer', Options);
fTelnet.ButtonBarVisible = true; fTelnet.ButtonBarVisible = true;
@@ -28,3 +24,5 @@
</body> </body>
</html> </html>