Uploaded image for project: 'VS Code Extension'
  1. VS Code Extension
  2. VSCODE-284

Unable to retrieve CA files when on WSL

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Critical - P2 Critical - P2
    • 0.6.12
    • Affects Version/s: 0.6.10
    • Component/s: Connectivity
    • Labels:
    • Environment:
      WSL 2 Ubuntu 20.04.2 LTS
    • 3
    • Not Needed
    • Iteration Johannesburg, Iteration Kampala, Iteration Lutz

      Problem Statement/Rationale

      When using the extension mongodb.mongodb-vscodePreview v0.6.10 on Visual Studio Code connected to WSL the extension incorrectly parses the file path of Server Validation Certificate Authority.
      Same steps performed on Visual Studio locally (non-WSL) works as expected.

      Steps to Reproduce

      1. Have Visual Studio Code connected to WSL (might require ms-vscode-remote.remote-wslPreview) - read more at Work in Windows Subsystem for Linux with Visual Studio Code
      2. on Visual Studio ran in WSL install mongodb.mongodb-vscodePreview v0.6.10 as usual
      3. Add MongoDB Connection
      4. On General tab provide: Hostname, Username, Password.
      5. Under SSL/TLS tab pick SSL: Server Validation
      6. Pick Certificate Authority with file picker (the file picker differs on WSL and locally)
      7. Connect

      Expected Results

      Successfully connected to <...>.docdb.amazonaws.com:27017.

      Actual Results

      Unable to load connection: Error: Failed to connect: ENOENT: no such file or directory, open '/mnt/c/Program Files/Microsoft VS Code/home/lpereira/source/<...>.pem'

      Additional Notes

      Any additional information that may be useful to include.

        1. mongodb locally.png
          mongodb locally.png
          122 kB
        2. mongodb WSL.png
          mongodb WSL.png
          133 kB

            Assignee:
            rhys.howell@mongodb.com Rhys Howell
            Reporter:
            lgp1985@gmail.com Luis Gustavo Pereira
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: