doc.go 918 B

123456789101112131415161718
  1. // Package rdsutils is used to generate authentication tokens used to
  2. // connect to a givent Amazon Relational Database Service (RDS) database.
  3. //
  4. // Before using the authentication please visit the docs here to ensure
  5. // the database has the proper policies to allow for IAM token authentication.
  6. // https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/UsingWithRDS.IAMDBAuth.html#UsingWithRDS.IAMDBAuth.Availability
  7. //
  8. // When building the connection string, there are two required parameters that are needed to be set on the query.
  9. // * tls
  10. // * allowCleartextPasswords must be set to true
  11. //
  12. // Example creating a basic auth token with the builder:
  13. // v := url.Values{}
  14. // v.Add("tls", "tls_profile_name")
  15. // v.Add("allowCleartextPasswords", "true")
  16. // b := rdsutils.NewConnectionStringBuilder(endpoint, region, user, dbname, creds)
  17. // connectStr, err := b.WithTCPFormat().WithParams(v).Build()
  18. package rdsutils