vscode-sqltools
vscode-sqltools copied to clipboard
Extensions always connect to localhost, but host in config different.
I have postgresql on virtual machine with address 192.168.88.101 settings.json
{
"workbench.colorTheme": "Visual Studio 2019 Light",
"workbench.iconTheme": "material-icon-theme",
"editor.fontSize": 15,
"editor.minimap.enabled": false,
"diffEditor.ignoreTrimWhitespace": false,
"editor.suggestSelection": "first",
"vsintellicode.modify.editor.suggestSelection": "automaticallyOverrodeDefaultValue",
"sqltools.connections": [
{
"askForPassword": true,
"database": "blog",
"driver": "PostgreSQL",
"name": "blog",
"pgOptions": {
},
"port": 5432,
"previewLimit": 50,
"server": "192.168.88.101",
"username": "blog_admin"
}
]
}
error log
['sql:ext:main:info'] EXECUTING => sqltools.selectConnection
['sql:ext:main:info'] EXECUTING => sqltools.getConnections
['sql:ext:main:info'] EXECUTING => sqltools.getConnections
['sql:ext:error-handler'] Error opening connection no pg_hba.conf entry for host "192.168.88.254", user "blog_admin", database "blog", SSL off
['sql:ext:error-handler:verbose'] [ResponseError: no pg_hba.conf entry for host "192.168.88.254", user "blog_admin", database "blog", SSL off
at /Users/op/.vscode/extensions/mtxr.sqltools-0.22.11/extension.js:16:111706
at /Users/op/.vscode/extensions/mtxr.sqltools-0.22.11/extension.js:16:112113
at Immediate.<anonymous> (/Users/op/.vscode/extensions/mtxr.sqltools-0.22.11/extension.js:16:112655)
at processImmediate (internal/timers.js:439:21)
at process.topLevelDomainCallback (domain.js:131:23)] {
code: -32001,
data: { driver: 'PostgreSQL', driverOptions: { pgOptions: {} } }
}
Desktop (please complete the following information):
- SQLTools Version [v0.22.11]
- VSCode Version: [June 2020 (version 1.47)]
- OS: [Mac Catalina]
- Driver:
- [ ] PostgreSQL
- Database version: [PostgreSQL v12]
i have the same issue, when i am trying to connect via VPN to my db. when i turn of vpn i see in the cscode-sqltools logs that the correct host is used but of course is not reachable
is there a way to increase the loglevel of sqltools?
Is it possible you also have a workspace-level definition? See #872