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

Add nonce for to js for login to work with CSP #32

Merged
merged 7 commits into from
Mar 23, 2023
Merged

Conversation

Oglopf
Copy link
Contributor

@Oglopf Oglopf commented Feb 28, 2023

No description provided.

@johrstrom
Copy link
Contributor

I know we've had issues with opening on the working_dir. I've found that the setting is in this file. If we want to continue to open on that initial directory we may be able to edit this file before we launch.

jq '.' ~/.local/share/code-server/coder.json

@johrstrom
Copy link
Contributor

This works for me, IDK if you want to play around with the contents of ~/.local/share/code-server/coder.json in this PR or just defer it.

@Oglopf
Copy link
Contributor Author

Oglopf commented Mar 2, 2023

I'm going to try and fix that too in the script, will update soon with that.

@johrstrom
Copy link
Contributor

I'm finding a few things here

  • 3.4 doesn't seem to work at all when we upgrade to 4.8 so I'd say let's just remove it as an option.
    • Switching back and forth between versions seems to throw errors in the console log. 3.4 doesn't load any files in the directory. 3.9 (after loading 4.8 then switching back to 3.9) has similar console log messages, but does in fact seem to work.
  • I don't know what --extra-extensions-dir and I don't see it as a valid CLI option in any version. In any case, extensions are picked up in --user-data-dir and this seems duplicate, so I think we can safely remove it.
  • with 3.4 removed --ignore-last-opened is a valid option for all versions, so we don't even need the if block.

Here's the diff I've been testing with.

diff.txt

@Oglopf
Copy link
Contributor Author

Oglopf commented Mar 23, 2023

Wait, do you want that extra-extensions or not? I'm confused now as this was removed before, then put in, and now we want to remove it?

@johrstrom
Copy link
Contributor

Wait, do you want that extra-extensions or not? I'm confused now as this was removed before, then put in, and now we want to remove it?

Yea I think so. I don't see it as a valid option for any version. Extensions are picked up in #{--user-data-dir}/extentions so I don't really know what this does, if anything.

Again - I cannot find it as a valid option for any version and extensions work fine without it.

@Oglopf Oglopf merged commit bb8409d into master Mar 23, 2023
@Oglopf Oglopf deleted the fix-codeserver-login branch March 23, 2023 19:41
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.

3 participants