Skip to content

feat(vscode-web): add support for settings #195

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
merged 3 commits into from
Mar 18, 2024

Conversation

michaelbrewer
Copy link
Contributor

@michaelbrewer michaelbrewer commented Mar 15, 2024

Add support for settings, like code-server

module "vscode-web" {
  source     = "registry.coder.com/modules/vscode-web/coder"
  version    = "1.0.8"
  agent_id   = coder_agent.example.id
  extensions = ["dracula-theme.theme-dracula"]
  settings = {
    "workbench.colorTheme" = "Dracula"
  }
  accept_license = true
}

Currently saves to ~/.vscode-server/data/Machine/settings.json as ~/.vscode-server/data/User/settings.json does not seem to work.

related to #194
closes #196

Currently saves to `~/.vscode-server/data/Machine/settings.json`
as `~/.vscode-server/data/User/settings.json` does not seem to work.
@matifali matifali requested a review from code-asher March 15, 2024 20:20
Copy link
Member

@code-asher code-asher left a comment

Choose a reason for hiding this comment

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

Looks good!


### Pre-configure Settings

Configure VS Code's [settings.json](https://code.visualstudio.com/docs/getstarted/settings#_settingsjson) file:
Copy link
Member

Choose a reason for hiding this comment

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

Should we add a warning that user settings cannot be customized because they are stored in the browser, so only machine settings will work? We could also recommend code-server if they absolutely need to have user settings, or recommend using settings sync.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@code-asher - maybe for another PR, but i think it would be useful to list out know issues and benefits the differentiate to the options.

ie:
code-server:

  • is more functionally complete
  • has less issues
  • does not support the microsoft marketplace
  • does not support some of the microsoft extensions like copilt, liveshare
  • does not require wildcard urls
  • etc..

vscode-web:

  • has issues with port forwarding
  • settings issues
  • requires wildcard / subdomain = true.
  • does not support self-hosted extensions
  • supports the microsoft extensions
  • etc..

Copy link
Member

@code-asher code-asher Mar 18, 2024

Choose a reason for hiding this comment

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

Agreed! This is a good list. code-server has a list of differences from Codespaces (https://github.com/coder/code-server/blob/main/docs/FAQ.md#whats-the-difference-between-code-server-and-github-codespaces) but not the self-hosted version, so we should probably add something there as well (this list is also a little out of date). Some of the differences there apply to the self-hosted version as well though.

Co-authored-by: Asher <ash@coder.com>
@code-asher code-asher merged commit 18810cc into coder:main Mar 18, 2024
@michaelbrewer michaelbrewer deleted the feat/vscode-web-settings branch March 20, 2024 21:55
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.

VS Code Web: Add support for settings
2 participants