mirror of
https://github.com/bpg/terraform-provider-proxmox.git
synced 2025-07-04 21:14:05 +00:00
fix(user): make password
attribute optional (#463)
This commit is contained in:
parent
368b133427
commit
5a3b1ccaf7
@ -49,7 +49,7 @@ resource "proxmox_virtual_environment_role" "operations_monitoring" {
|
|||||||
- `groups` - (Optional) The user's groups.
|
- `groups` - (Optional) The user's groups.
|
||||||
- `keys` - (Optional) The user's keys.
|
- `keys` - (Optional) The user's keys.
|
||||||
- `last_name` - (Optional) The user's last name.
|
- `last_name` - (Optional) The user's last name.
|
||||||
- `password` - (Required) The user's password.
|
- `password` - (Optional) The user's password. Required for PVE or PAM realms.
|
||||||
- `user_id` - (Required) The user identifier.
|
- `user_id` - (Required) The user identifier.
|
||||||
|
|
||||||
## Attribute Reference
|
## Attribute Reference
|
||||||
|
@ -131,7 +131,7 @@ func User() *schema.Resource {
|
|||||||
mkResourceVirtualEnvironmentUserPassword: {
|
mkResourceVirtualEnvironmentUserPassword: {
|
||||||
Type: schema.TypeString,
|
Type: schema.TypeString,
|
||||||
Description: "The user's password",
|
Description: "The user's password",
|
||||||
Required: true,
|
Optional: true,
|
||||||
},
|
},
|
||||||
mkResourceVirtualEnvironmentUserUserID: {
|
mkResourceVirtualEnvironmentUserUserID: {
|
||||||
Type: schema.TypeString,
|
Type: schema.TypeString,
|
||||||
|
@ -31,7 +31,6 @@ func TestUserSchema(t *testing.T) {
|
|||||||
s := User()
|
s := User()
|
||||||
|
|
||||||
test.AssertRequiredArguments(t, s, []string{
|
test.AssertRequiredArguments(t, s, []string{
|
||||||
mkResourceVirtualEnvironmentUserPassword,
|
|
||||||
mkResourceVirtualEnvironmentUserUserID,
|
mkResourceVirtualEnvironmentUserUserID,
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -45,6 +44,7 @@ func TestUserSchema(t *testing.T) {
|
|||||||
mkResourceVirtualEnvironmentUserGroups,
|
mkResourceVirtualEnvironmentUserGroups,
|
||||||
mkResourceVirtualEnvironmentUserKeys,
|
mkResourceVirtualEnvironmentUserKeys,
|
||||||
mkResourceVirtualEnvironmentUserLastName,
|
mkResourceVirtualEnvironmentUserLastName,
|
||||||
|
mkResourceVirtualEnvironmentUserPassword,
|
||||||
})
|
})
|
||||||
|
|
||||||
test.AssertValueTypes(t, s, map[string]schema.ValueType{
|
test.AssertValueTypes(t, s, map[string]schema.ValueType{
|
||||||
|
Loading…
Reference in New Issue
Block a user