Skip to content

Added mod for ssh tunneling #18

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

Dobli
Copy link

@Dobli Dobli commented Mar 21, 2020

This mod enables tcp forwarding for the openssh server, allowing to use the container as tunnel, e.g. between a private network and a public server to make local services publicly available. Usage example is provided within the readme.

@aptalca aptalca requested a review from a team March 22, 2020 03:56
@aptalca
Copy link
Member

aptalca commented Mar 23, 2020

@Dobli are you sure expose is needed? As far as I know, expose is only for documentation purposes and has no effect on the container: https://docs.docker.com/engine/reference/builder/#expose

@Dobli
Copy link
Author

Dobli commented Mar 24, 2020

Hi, I'll check it again later, at least when I tried it last time it seemed necessary so my webserver could reach it. I'll try to omitt it and see if it is necessary.

@Dobli
Copy link
Author

Dobli commented Mar 24, 2020

@aptalca
Okay I checked it again. It behaves like described in my readme. When exposed is used in the compose file (or run command) other containers (in my case my reverse proxy) are able to access the port, when I omit it the port is not reachable.

This also matches the description of expose in the compose documentation: https://docs.docker.com/compose/compose-file/#expose

You are right that it usually is not necessary, but this could be caused by docker run and docker-compose commands both respecting the EXPOSE entries within Dockerfiles and exposing these ports to other containers by default: https://docs.docker.com/compose/compose-file/#service-configuration-reference

In this case though, it is unknown what ports should be exposed during Dockerfile creation. Therefore the expose entry is necessary.

@aptalca
Copy link
Member

aptalca commented Mar 24, 2020

Great, thanks for confirming.

@aptalca aptalca merged commit 99bfca3 into linuxserver:openssh-server-ssh-tunnel Mar 24, 2020
labmonkey added a commit to labmonkey/docker-mods that referenced this pull request Mar 18, 2024
# This is the 1st commit message:

Updated requirements in the Readme to mention docker dependencies

# This is the commit message linuxserver#2:

Improve the way mod behaves after restart where config directory disappears by recreating the config file (prevent unneccesary update in the api)

# This is the commit message linuxserver#3:

debug

# This is the commit message linuxserver#4:

fix

# This is the commit message linuxserver#5:

fix

# This is the commit message linuxserver#6:

fix

# This is the commit message linuxserver#7:

fix

# This is the commit message linuxserver#8:

fix

# This is the commit message linuxserver#9:

fix

# This is the commit message linuxserver#10:

Refactor whole code (same functionality)

# This is the commit message linuxserver#11:

fix

# This is the commit message linuxserver#12:

fix

# This is the commit message linuxserver#13:

fix

# This is the commit message linuxserver#14:

fix

# This is the commit message linuxserver#15:

fix

# This is the commit message linuxserver#16:

fix

# This is the commit message linuxserver#17:

fix

# This is the commit message linuxserver#18:

fix everything with pylint

# This is the commit message linuxserver#19:

fix

# This is the commit message linuxserver#20:

fix

# This is the commit message linuxserver#21:

fix

# This is the commit message linuxserver#22:

fix

# This is the commit message linuxserver#23:

fix

# This is the commit message linuxserver#24:

fix

# This is the commit message linuxserver#25:

fix

# This is the commit message linuxserver#26:

fix

# This is the commit message linuxserver#27:

fix

# This is the commit message linuxserver#28:

fix

# This is the commit message linuxserver#29:

fix

# This is the commit message linuxserver#30:

added monitor param

# This is the commit message linuxserver#31:

added support for notifications

# This is the commit message linuxserver#32:

fix

# This is the commit message linuxserver#33:

fix

# This is the commit message linuxserver#34:

fix

# This is the commit message linuxserver#35:

fix

# This is the commit message linuxserver#36:

fix

# This is the commit message linuxserver#37:

added note about defaults
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants