whi-tw / docker-sslh

sslh in docker

Home Page:https://hub.docker.com/r/tnwhitwell/sslh

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

docker-sslh

Update Status

Docker Pulls

Image Layers

Latest built Commit

Dependabot Status

Docker alpine image containing sslh, configurable with environment variables.

Usage

By default, no multiplexing options are enabled:

Start and expose port 443 with no configurations

docker run -d -p 443:8443 --name sslh tnwhitwell/sslh

To configure a backend, set at least the *_HOST env var:

Start and configure SSH and HTTPS with default ports

docker run -e SSH_HOST=host -e HTTPS_HOST=somehost.internal -p 443:8443 tnwhitwell/sslh

If the service is not listening on the default port, it can be overridden with the *_PORT env var:

Start and configure SSH and HTTPS with custom ports

docker run -e SSH_HOST=host -e SSH_PORT=2222 -e HTTPS_HOST=somehost.internal -e HTTPS_PORT=8443 -p 443:8443 tnwhitwell/sslh

Available Environment Variables

Naming should be self explanatory, defaults are indicated.

If a *_HOST environment variable is omitted, it will not be configured.

HTTPS_HOST=
HTTPS_PORT=443

OPENVPN_HOST=
OPENVPN_PORT=1194

SHADOWSOCKS_HOST=
SHADOWSOCKS_PORT=8388

SSH_HOST=
SSH_PORT=22

TRANSPARENT=false # This is currently WIP and doesn't seem to work properly. This could be a me problem, though, and could do with some investigation.

docker-compose

This can also be run with docker-compose:

---
version: '3'
services:
  web:
    image: nginx:latest
  sslh:
    image: tnwhitwell/sslh:latest
    ports:
      - 443:8443
    environment:
      HTTPS_HOST: web
      HTTPS_PORT: 443
      SSH_HOST: 172.17.0.1 # Point to the Docker Host's IP
      SSH_PORT: 22
    depends_on:
      - web

Thanks to @shaddysignal's sslh-hub for inspiration.

About

sslh in docker

https://hub.docker.com/r/tnwhitwell/sslh

License:GNU General Public License v3.0


Languages

Language:Shell 55.2%Language:Dockerfile 35.6%Language:Makefile 9.2%