» mysql_user_password

The mysql_user_password resource sets and manages a passwordd for a given user on a MySQL server.

» Example Usage

resource "mysql_user" "jdoe" {
  user = "jdoe"
}
 resource "mysql_user_password" "jdoe" {
  user    = "${mysql_user.jdoe.user}"
  pgp_key = "keybase:joestump"
}

You can rotate passwords by running terraform taint mysql_user_password.jdoe. The next time Terraform applies a new password will be generated and the user's password will be updated accordingly.

» Argument Reference

The following arguments are supported:

  • user - (Required) The IAM user to associate with this access key.
  • host - (Optional) The source host of the user. Defaults to localhost.
  • pgp_key - (Optional) Either a base-64 encoded PGP public key, or a keybase username in the form keybase:some_person_that_exists.

» Attributes Reference

The following additional attributes are exported: