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

Incorrect reporting in the terminal when custom password is used #757

Closed
gerroon opened this issue Jun 7, 2019 · 10 comments
Closed

Incorrect reporting in the terminal when custom password is used #757

gerroon opened this issue Jun 7, 2019 · 10 comments
Labels
bug Something isn't working

Comments

@gerroon
Copy link

gerroon commented Jun 7, 2019

Hi

I am trying to set this up with password but it is not working out well

/opt/code-server/code-server --port=4000 --allow-http --disable-telemetry --password "MYPASS" -d /media/CODE

INFO  Starting webserver... {"host":"0.0.0.0","port":"4000"}
WARN  No certificate specified. This could be insecure.
WARN  Documentation on securing your setup: https://github.com/cdr/code-server/blob/master/doc/security/ssl.md
WARN  Launched without authentication.
INFO  Telemetry is disabled
INFO   
INFO  Started (click the link below to open):

As you see it is laucnhed without password, I tried variations on the password field without any luck.

I am on Debian Buster using code-server v1.1119-vsc1.33.1

@gerroon gerroon added the bug Something isn't working label Jun 7, 2019
@yujincheng08
Copy link

password is deprecated. Use environment variable PASSWORD instead.

@Josh-Uvi
Copy link

Josh-Uvi commented Jun 8, 2019

password is deprecated. Use environment variable PASSWORD instead.
@yujincheng08
how do you use the environment variable PASSWORD to replace --password to set the custom password. Perhaps, an example code would help. Thanks

@deansheather
Copy link
Member

@Josh-Uvi env PASSWORD=test code-server

@deansheather
Copy link
Member

@gerroon I just tried this and it looks like code-server incorrectly reports that it's launched without authentication when a password is supplied. I opened it in the browser and it does require a password.

@gerroon
Copy link
Author

gerroon commented Jun 9, 2019

@deansheather

Thanks for check it out. I will give it a try. I did not think about thatg possibility to be honest,

@code-asher
Copy link
Member

code-asher commented Jun 10, 2019

We only output the password when it's generated (since you already know the password). #286 (comment)

@gerroon
Copy link
Author

gerroon commented Jun 11, 2019

@code-asher sure but the message in the termianl is misleading. It does not have to show the password, but at least it can say the password is enabled instead of WARN Launched without authentication.

@code-asher
Copy link
Member

Oh, right! I completely missed that part. Let's update the issue title to something like "Incorrectly reports as launching without authentication when using custom password".

@gerroon gerroon changed the title --password="mypass" is not working Incorrectly reporting in the terminal when custom password is used Jun 11, 2019
@gerroon gerroon changed the title Incorrectly reporting in the terminal when custom password is used Incorrect reporting in the terminal when custom password is used Jun 11, 2019
@code-asher
Copy link
Member

code-asher commented Jun 11, 2019

Thanks for the bug report; just pushed a fix. I'm gonna try to read issues (and comments!) more closely in the future, sorry about that. 😛

@antofthy
Copy link

I saw this problem too. Thought use of PASSWORD environment variable was broken because of it!
didn't get around to reporting it before this bug report appeared.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants