You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
However, this is not scalable. I am looking for advice to pass the user ID as _id in the user creation api call. I am fearing a chicken and the egg dilemma
The text was updated successfully, but these errors were encountered:
I am wanting to add user attributes and have a certain chicken and the egg dilemma.
I added the attributes schema like so
"attributes": &schema.Schema{
Type: schema.TypeList,
Required: true,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{
"name": &schema.Schema{
Type: schema.TypeString,
Optional: true,
},
"value": &schema.Schema{
Type: schema.TypeString,
Optional: true,
},
and am able to create the user with attributes as so:
resource "jumpcloud_user" "test_user1" {
username = "tuser"
firstname = "test"
lastname = "user"
email = "[email protected]"
attributes {
name = "github"
value = "test124"
}
}
However, this produces the following error:
Error: Invalid address to set: []string{"attributes", "0", "_id"}
on main.tf line 5, in resource "jumpcloud_user" "test_user1":
5: resource "jumpcloud_user" "test_user1" {
to workaround this I have implemented this:
"attributes": &schema.Schema{
Type: schema.TypeList,
Required: true,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{
"name": &schema.Schema{
Type: schema.TypeString,
Optional: true,
},
"value": &schema.Schema{
Type: schema.TypeString,
Optional: true,
},
"_id": &schema.Schema{
Type: schema.TypeString,
Optional: true,
},
However, this is not scalable. I am looking for advice to pass the user ID as _id in the user creation api call. I am fearing a chicken and the egg dilemma
The text was updated successfully, but these errors were encountered: