Open-Awesome
CategoriesAlternativesStacksSelf-HostedExplore
Open-Awesome

© 2026 Open-Awesome. Curated for the developer elite.

TermsPrivacyAboutGitHubRSS
  1. Home
  2. SSH
  3. ssh2docker

ssh2docker

MITGov1.2.0

A standalone SSH server that creates or joins Docker containers, providing secure shell access with dynamic configuration.

Visit WebsiteGitHubGitHub
197 stars19 forks0 contributors

What is ssh2docker?

ssh2docker is a standalone SSH server designed to provide secure shell access directly into Docker containers. It acts as a gateway, allowing users to SSH into a host and be automatically placed into a new or existing Docker container based on configuration. This solves the problem of managing secure, isolated shell access for multiple users or services within a Dockerized environment without manual container entry.

Target Audience

DevOps engineers, system administrators, and developers managing Docker-based infrastructure who need to provide controlled SSH access to containers for debugging, maintenance, or operational tasks.

Value Proposition

Developers choose ssh2docker for its simplicity and security—it leverages standard SSH for authentication and seamlessly integrates with Docker, eliminating the need for complex setups. Its unique selling point is the ability to dynamically create or join containers per SSH session with extensive configuration options, making it more flexible than basic Docker exec approaches.

Overview

:whale: standalone SSH server that connects you to your Docker containers

Use Cases

Best For

  • Providing secure SSH access to Docker containers for multiple users
  • Debugging and maintaining containerized applications via shell
  • Running non-interactive commands (e.g., git, rsync) inside containers over SSH
  • Isolating user sessions in separate Docker containers for security
  • Automating container access with custom authentication hooks
  • Managing development or staging environments with controlled container entry

Not Ideal For

  • Environments requiring high-performance SSH with minimal latency overhead
  • Projects needing persistent, stateful user sessions across container reboots
  • Teams that rely on advanced SSH features like port forwarding or SCP without extra setup
  • Non-Dockerized infrastructures or those using alternative container runtimes

Pros & Cons

Pros

Dynamic Container Provisioning

Automatically creates or joins Docker containers based on SSH users, enabling isolated sessions without manual intervention, as shown in the usage example where different users get different images.

Customizable Authentication Hooks

Supports password and public-key authentication via external scripts, allowing integration with systems like LDAP, as indicated by the --password-auth-script and --publickey-auth-script options.

Fine-Grained Configuration

Allows restricting allowed Docker images, customizing run arguments, and setting default shells, providing control over container environments through CLI flags like --allowed-images and --docker-run-args.

Versatile Session Management

Handles both TTY and non-TTY sessions for interactive shells or commands like git and rsync, as mentioned in the changelog support for exec without TTY.

Cons

Requires Privileged Docker Access

Often needs Docker in privileged mode or with host volume mounts, as shown in the test command using --privileged, which introduces security risks and complicates deployment.

Limited SSH Feature Set

Focuses on basic shell access and command execution; advanced SSH features like SCP or port forwarding aren't explicitly supported and may require additional container-side setup.

Potential Maintenance Concerns

The last stable release was in 2015, with master having unreleased changes, indicating possible inactivity and lack of recent updates or security patches.

Frequently Asked Questions

Quick Stats

Stars197
Forks19
Contributors0
Open Issues23
Last commit3 months ago
CreatedSince 2015

Tags

#ssh-server#gateway#devops-tools#container-management#infrastructure#secure-shell#docker#go#ssh#session-management

Built With

G
Go

Links & Resources

Website

Included in

SSH2.8k
Auto-fetched 1 day ago

Related Projects

teleportteleport

The easiest, and most secure way to access and protect all of your infrastructure.

Stars20,423
Forks2,073
Last commit1 day ago
ssh chatssh chat

Chat over SSH.

Stars5,897
Forks427
Last commit4 months ago
whostherewhosthere

A ssh server that knows who you are. $ ssh whoami.filippo.io

Stars2,354
Forks110
Last commit1 month ago
ShellHubShellHub

:computer: Get seamless remote access to any Linux device. Centralized SSH for the edge and cloud computing

Stars2,016
Forks183
Last commit1 day ago
Community-curated · Updated weekly · 100% open source

Found a gem we're missing?

Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.

Submit a projectStar on GitHub