Skip to content
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

Consol tunnel fix #343

Merged
merged 2 commits into from
Jul 14, 2020
Merged

Consol tunnel fix #343

merged 2 commits into from
Jul 14, 2020

Conversation

catborise
Copy link
Collaborator

ssh tunneling not working after migrating python3.
it is fixed.
update tunnel with threading.

@retspen
Copy link
Owner

retspen commented Jul 14, 2020

Good job. Thank you!

@retspen retspen merged commit 522b95f into retspen:master Jul 14, 2020
@@ -22,7 +22,7 @@ django.setup()
import re
import socket
from six.moves import http_cookies as Cookie
from webvirtcloud.settings import WS_PORT, WS_HOST, WS_CERT
from webvirtcloud.settings import WS_PUBLIC_PORT, WS_HOST, WS_CERT
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @catborise 👋 ,
I've a question regarding this change.

From my understanding WS_PUBLIC_HOST is used to define the external Port which is e.g. used as variable for the web socket connection.

Now when I change this variable to port 80 (Which I have to in order to be able to use my nginx reverse proxy) the novncd service can't start anymore because It's trying to use port 80 which is already block by nginx.

So with which intention it was changed?

Regards

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@shokinn you should also change nginx config if you want to use 80 port for console. you should forward 80 to 6080.

you can look at nginx conf which is under conf/nginx directory

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No I'm sorry maybe you misunderstood me.

So I already have a working Web socket reverse proxy. Which routes internally to 6080.

I ask why did you changed WS_PORT to WS_PUBLIC_PORT.

WS_PORT is meant to be setting the novncd service port.
WS_PUBLIC_PORT is meant to be define the puiblic port e.g. the port from the nginx reverse proxy or natted port.

Your change breaks this behavior which make it is impossible to have separate ports for the service and for the public port.

See the readme here regarding the public port: https://github.com/retspen/webvirtcloud#reverse-proxy

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same thing hapening to me which leads to my VNC not working at all :)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@shokinn i understand the problem we replace ws port and ws public port. but i forget to replace ws_public_port to ws_port in the console/novncd . we should update it also. i will

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@shokinn could you please make a test to see if it is solve the problem or not.
change only the file: console/novncd
from
from webvirtcloud.settings import WS_PUBLIC_PORT, WS_HOST, WS_CERT
to
from webvirtcloud.settings import WS_PORT, WS_HOST, WS_CERT

and modify webvirtcloud/settings.py WS_PORT

feedback pls ..
thanks

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll check it later today,
I think that I already checked it yesterday evening but I'll check it again when I'm back home today and have access to my development environment.

If it works, I'll file PR.
If not, I'll let you know here :)

Copy link
Contributor

@shokinn shokinn Aug 13, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@catborise @lord-kyron
I've filed a PR #352 could you please check and verify that this will also work for you?

*This bug here is still in place so if you test it with a local kvm it would still not work.

I've tested it and it works now (when I fix locally the bug above).

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.

4 participants