devcontainers / devcontainers/spec
[Bug]When working with a proxy, the extensions cannot be automatically installed.
- Dominant language
- No language data
- Stars
- 5.7k
- Forks
- 496
- PR merge metrics
- No merged PRs in 30d
Description
I am using a proxy and installed the proxy root cert into the host system (MacOs 13.0.1 on m1), also in the container (with "postCreateCommand": "update-ca-certificates"). but when the container is created, the vscode extensions cannot be installed automatically.
In the Server output, it shows the error:
```
[error] Error: unable to get local issuer certificate
at TLSSocket.onConnectSecure (node:_tls_wrap:1530:34)
at TLSSocket.emit (node:events:526:28)
at TLSSocket._finishInit (node:_tls_wrap:944:8)
at TLSWrap.ssl.onhandshakedone (node:_tls_wrap:725:12)
```
If you manually install those extensions, you can succeed, but the same error still happens:
```
2023-04-14 13:18:51.782 [info] Getting Manifest... firsttris.vscode-jest-runner
2023-04-14 13:18:53.268 [error] Failed to install extension. firsttris.vscode-jest-runner
2023-04-14 13:18:53.269 [error] Error: unable to get local issuer certificate
at TLSSocket.onConnectSecure (node:_tls_wrap:1530:34)
at TLSSocket.emit (node:events:526:28)
at TLSSocket._finishInit (node:_tls_wrap:944:8)
at TLSWrap.ssl.onhandshakedone (node:_tls_wrap:725:12)
2023-04-14 13:18:56.103 [info] Downloaded extension to file:///home/node/.vscode-server/extensionsCache/c43f6b2a-2384-48bd-ae85-353b75a340bf
2023-04-14 13:18:56.114 [info] Installing extension: firsttris.vscode-jest-runner
2023-04-14 13:18:56.114 [info] Installing the extension without checking dependencies and pack firsttris.vscode-jest-runner
2023-04-14 13:18:56.136 [info] Removed the extension from uninstalled list: firsttris.vscode-jest-runner
2023-04-14 13:18:56.157 [info] Deleted from disk firsttris.vscode-jest-runner /home/node/.vscode-server/extensions/firsttris.vscode-jest-runner-0.4.60
2023-04-14 13:18:56.266 [info] Extracted extension to /home/node/.vscode-server/extensions/.8e55fd86-d39c-45f5-aa94-2892122214d7: firsttris.vscode-jest-runner
2023-04-14 13:18:56.271 [info] Renamed to /home/node/.vscode-server/extensions/firsttris.vscode-jest-runner-0.4.60
2023-04-14 13:18:56.272 [info] Extracting extension completed. firsttris.vscode-jest-runner
2023-04-14 13:18:56.278 [info] Extension installed successfully: firsttris.vscode-jest-runner
```
I also tried to set the container environment NODE_EXTRA_CA_CERTS to point to the proxy root cert, but it doesn't help too.
Contributor guide
Assessment
This issue has not been assessed yet.