Skip to content

Support for --root-path argument #4625

Closed

Description

@GokulNC

I am looking to add a prefix path for code-server instead of serving it via /.
This is to ensure that I can route VS code via my regular port 80 website, but with a prefix (like abc.com/code ) by linking it to my proxy-server to map it to code-server's port and path.

Basically, I am looking for something like this:
https://fastapi.tiangolo.com/advanced/behind-a-proxy/

If there's already a way to achieve this, please let me know. Thanks!

Activity

  1. GokulNC commented on Dec 15, 2021

    @GokulNC
    Author

    As of now, without this, I am getting 404: Not Found error when visiting abc.com/code since it redirects to abc.com/login

    (My reverse proxy-server strips the /code prefix before sending it the code-server's port)

  2. GokulNC commented on Dec 15, 2021

    @GokulNC
    Author

    OK. So if I explicitly go to /code/login, it works after logging-in as intended.
    So is it possible to fix this initial redirection issue?


    Also, only /code/ works, /code does not work (after login).

  3. locked and limited conversation to collaborators on Dec 15, 2021
  4. converted this issue into a discussion #4626 on Dec 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    featureNew user visible feature

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions