Skip to content

Simple tutorial on using Docker to map your ~/.ssh to a container. This uses an Alpine container for simplicity. This is not generally advisable, but I publish it in case it is helpful to someone.

License

Notifications You must be signed in to change notification settings

bean5/docker_ssh

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

docker_ssh

A docker wrapper that maps your ~/.ssh folder to a an alpine-based SSH container. It mounts to a corresponding ~/.ssh/ to the container as read-only. Previously it that was copied, permissions were modified, but with docker-compose, now it can be mounted directly.

Warning

Although this is mounted as read-only, it is not recommended that you mount your actual .ssh folder. You should be mounting one that makes sense for your project.

Requirements

  • docker
  • docker-compose

Use

docker compose up -d ssh

Then use ssh as you normally would. Enjoy!

License

See LICENSE file. I chose MIT because I didn't do much here except glue awesome code together. License selected using https://choosealicense.com/ -- a very handy tool!

About

Simple tutorial on using Docker to map your ~/.ssh to a container. This uses an Alpine container for simplicity. This is not generally advisable, but I publish it in case it is helpful to someone.

Topics

Resources

License

Stars

Watchers

Forks