-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
mysql backend - allow providing hostname (for CT) #1441
Comments
Neat idea. @LLBennett something to keep in mind! |
I worked around this in different ways the last 2 years, probably not worth a fix in Vault |
I think this might be related to #317. In the overall scheme it seems that it would be nice to be able to define the output string(s) in one way or another. I know the title says PostgreSQL but it sounds to be a very much the same request, no? |
mgritter
pushed a commit
that referenced
this issue
Sep 4, 2020
mgritter
pushed a commit
that referenced
this issue
Sep 8, 2020
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi,
A problem I'm currently having is that the mysql secret backend only provides a username (
{{.Data.username}}
in CT) and password ({{.Data.password}}
in CT)Providing a connection string usually also include a hostname though, and some arbitrary attributes like database and so on.
It would be nice if you could attach these kind of meta-data keys to the data returned from a mysql secret lease - e.g.
{{.Data.hostname}}
,{{.Data.port}}
and{{.Data.database}}
and so onFor example if my CT request credentials for a read-only access account, it could bind the hostname to
slave.mysql.service.consul
(provided by me inPOST /mysql/roles/
- will allow for more dumb CT as it wouldn't have to read the hostname from a clear-text key/value, allowing the consuming developer to just use the returned data and no outside knowledge about the system(s) to get things working correctlyExample:
POST /mysql/roles/p_read_only { sql: "bla bla", hostname: slave.mysql.service.consul, port: 3306, database: production }
POST /mysql/roles/i_read_only { sql: "bla bla", hostname: slave.mysql.service.consul, port: 3306, database: insights }
POST /mysql/roles/p_writeable { sql: "bla bla", hostname: master.mysql.service.consul, port: 3308, database: production }
The text was updated successfully, but these errors were encountered: