github.com/pmcatominey/terraform@v0.7.0-rc2.0.20160708105029-1401a52a5cc5/website/source/docs/providers/postgresql/r/postgresql_role.html.markdown (about) 1 --- 2 layout: "postgresql" 3 page_title: "PostgreSQL: postgresql_role" 4 sidebar_current: "docs-postgresql-resource-postgresql_role" 5 description: |- 6 Creates and manages a database on a PostgreSQL server. 7 --- 8 9 # postgresql\_role 10 11 The ``postgresql_role`` resource creates and manages a role on a PostgreSQL 12 server. 13 14 15 ## Usage 16 17 ``` 18 resource "postgresql_role" "my_role" { 19 name = "my_role" 20 login = true 21 password = "mypass" 22 encrypted = true 23 } 24 25 ``` 26 27 ## Argument Reference 28 29 * `name` - (Required) The name of the role. Must be unique on the PostgreSQL server instance 30 where it is configured. 31 32 * `login` - (Optional) Configures whether a role is allowed to log in; that is, whether the role can be given as the initial session authorization name during client connection. Corresponds to the LOGIN/NOLOGIN 33 clauses in 'CREATE ROLE'. Default value is false. 34 35 * `password` - (Optional) Sets the role's password. (A password is only of use for roles having the LOGIN attribute, but you can nonetheless define one for roles without it.) If you do not plan to use password authentication you can omit this option. If no password is specified, the password will be set to null and password authentication will always fail for that user. 36 37 * `encrypted` - (Optional) Corresponds to ENCRYPTED, UNENCRYPTED in PostgreSQL. This controls whether the password is stored encrypted in the system catalogs. Default is false.