Commit Graph
16 Commits
Author SHA1 Message Date
Gavin Frazar df44ae849d Add mysql conn tester (#20177)
* Add mysql conn tester
* fix issues with mysql error codes
2023-01-13 21:10:33 +00:00
STeve (Xin) Huang be77dadd55 Move database fetchers to discovery service (#19510) 2022-12-26 20:46:25 +00:00
Gavin FrazarandMarek Smoliński 65e35120a1 fix aws rds discovery invalid engine filter (#18328)
* Add helper func to check for AWS unrecognized engine error

* Retry RDS queries with individual filters if engine name is unrecognized

* godoc

* pass engine names instead of filters, to make retry logic simpler

* Update mocks to check/apply RDS engine filters

* Update watcher tests

* Add watcher test for unrecognized RDS engines

* Update lib/srv/db/cloud/mocks.go

Co-authored-by: Marek Smoliński <marek@goteleport.com>

Co-authored-by: Marek Smoliński <marek@goteleport.com>
2022-11-17 20:46:35 +00:00
STeve (Xin) Huang d8f4581606 Web API for getting database IAM policy (#17635) 2022-11-09 13:58:17 +00:00
STeve (Xin) Huang 1b0a083b9d Database access AWS RDS Proxy support (#17005) 2022-10-31 15:21:31 +00:00
Jakub Nyckowski 0ee91f6c37 Enable GCI linter (#17894) 2022-10-28 20:20:28 +00:00
Gabriel Corado 0f67969138 Add message for "certificate has expired" error on database connect (#14794) 2022-10-04 12:02:34 +00:00
Alan Parra 5cda242067 Update various Go dependencies (#16861)
Update various "assorted" dependencies, that either are used throughout
(logging, testing), are mostly algorithmic or otherwise difficult to pinpoint
"ownership".

I've dropped a couple of deprecated/mostly meaningless dependencies. I suspect
`github.com/mitchellh/mapstructure` could be dropped to, but I didn't look
further now.

* Drop dependency on Clever/go-utils
* Drop dependency on github.com/pkg/errors
* Update various Go dependencies
* Use CompareAndSwap instead of CAS (uber/atomic)
* Add a comment after replaced dependencies
2022-09-30 14:01:51 +00:00
Gavin FrazarandMarek Smoliński b79a9783ed Azure API for DB discovery (#15674)
* Add Azure auto-discovery configuration fields

* Init databases if azure matchers are in config

* Use AzureMatchers in db service

* Use all azure subscriptions/resource groups if omitted in matcher

* Add azure config tests

* Go mod tidy to update dependencies

* Add azure response error conversion

* Check for azure access denied and give a helpful error message

* Add azure subscriptions api

* Add azure mysql/postgresql api and wrappers

* Test generic db server for azure

* Make server properties its own type

* Convert server types manually instead of via json

* Move server list method selection logic out of api client

* Update azure db server tests

* Fixup merge

* Update comments

* Update more comments and remove junk code

* Move all azure api into lib/cloud/azure

* Update state and version checks

* Add mutex to subscription client for caching, just in case

* Update lib/cloud/azure/db_server_test.go

Co-authored-by: Marek Smoliński <marek@goteleport.com>

* Update lib/cloud/azure/subscriptions_test.go

Co-authored-by: Marek Smoliński <marek@goteleport.com>

* Update lib/cloud/azure/db_server_test.go

Co-authored-by: Marek Smoliński <marek@goteleport.com>

* Update lib/cloud/azure/db_server_test.go

Co-authored-by: Marek Smoliński <marek@goteleport.com>

* Update lib/cloud/azure/db_server_test.go

Co-authored-by: Marek Smoliński <marek@goteleport.com>

* Rename azure subscription client and remove sub ID caching

* Add reference links for azure db ports

* Move indirect dep into group

* Wrap all converted azure response errors

* Remove unreachable panic

* Godoc DBServer

* Remove maxPages arg to azure client funcs

* Gofmt

* Spacing between copyright and package

* import order

Co-authored-by: Marek Smoliński <marek@goteleport.com>
2022-08-25 19:15:05 +00:00
d8c9b08001 Support China and GovCloud for database access (#15359)
Co-authored-by: waylen <waylen.guo@gmail.com>
Co-authored-by: Jianghui Guo <89057156+waylenguo@users.noreply.github.com>
Co-authored-by: STeve (Xin) Huang <huangin52@gmail.com>
2022-08-16 18:42:18 +00:00
Marek Smoliński 275a443f19 Upgrade MySQL driver to v1.5.0 (#12667) 2022-05-18 11:27:10 +02:00
STeve (Xin) Huang 0d12750b78 Common database connect errors (#11111) 2022-03-15 16:28:23 +00:00
Gabriel Corado df44457b02 feat: aws database configurator (#9145) 2022-02-18 21:15:54 +00:00
Roman Tkachenko ce547953db Automatically import RDS databases (#8481) 2021-10-15 11:03:10 -07:00
Roman Tkachenko 9959ea381f Auto-configure IAM for RDS databases (#8339) 2021-10-01 11:06:17 -07:00
Roman Tkachenko efc3973f78 Better handling of database access IAM errors (#7525) 2021-07-14 09:13:39 -07:00