argocd-vault-plugin
argocd-vault-plugin copied to clipboard
[WIP] Implement database engine for vault
Description
This PR implement support database engine for vault
Fixes: #270
Checklist
Please make sure that your PR fulfills the following requirements:
- [x] Reviewed the guidelines for contributing to this repository
- [x] The commit message follows the Conventional Commits Guidelines.
- [x] Tests for the changes have been updated
- [ ] Are you adding dependencies? If so, please run
go mod tidy -compat=1.17to ensure only the minimum is pulled in. - [ ] Docs have been added / updated
Type of Change
- [x] Feature
- [x] New tests
Other information
TODO list :
- [x] output the database credentials
- [x] [test] create tests
- [x] [test] mount database engine
- [x] [test] create policies
- [ ] [test] configure database connection (This is currently bugged, i have the following error)
vault_test.go:32: Error making API request. URL: PUT https://127.0.0.1:33337/v1/database/config/testing Code: 404. Errors: * no handler for route "database/config/testing". route entry not found. - [ ] [test] configure database dynamic credentials (I need to know what database i can use)
Hi @orblazer, regarding the error you're getting * no handler for route "database/config/testing". route entry not found. I think that's because the SecretEngine in path database hasn't been successfully enabled at Line 139, pkg/helpers/test_helpers.go.
client.Sys().Mount("database", &api.MountInput{
Type: "database",
})
client.Sys().Mount() method returns an error if not successful, you should handle that error.
@sakiib yeah that is only first commit, i still search how i can run the tests for try it (but for that i need implement SQLLite or something else)