Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Schema: JAAS group data source #604

Open
pkulik0 opened this issue Oct 9, 2024 · 1 comment
Open

Schema: JAAS group data source #604

pkulik0 opened this issue Oct 9, 2024 · 1 comment
Assignees
Labels
area/schema Review schema changes before work begins kind/feature suggests new feature or enhancement

Comments

@pkulik0
Copy link
Contributor

pkulik0 commented Oct 9, 2024

Type of change

Adding new schema

Description

This schema change is needed for implementation of a data source for JAAS groups. We already have a resource for them and the schema attributes are exactly the same.

Details

"name": schema.StringAttribute{
	Description: "The name of the group.",
	Required:    true,
},
"uuid": schema.StringAttribute{
        Description: "The UUID of the group.",
	Computed:    true,
},

The JAAS group resource takes a name to create a group, so for ease of use this data source also takes in the attribute already known to users and fetches the UUID from JAAS.

Example terraform plan

resource "juju_jaas_group" "test" {
  name = "group-0"
}

// --------------- Second plan that uses the data source to use the group from plan #1

data "juju_jaas_group" "test" {
  name = "group-0"
}

Notes & References

No response

@pkulik0 pkulik0 changed the title JAAS group data source Schema: JAAS group data source Oct 9, 2024
@kian99
Copy link
Contributor

kian99 commented Oct 16, 2024

Thanks for this, looks good to me.

@hmlanigan hmlanigan added the area/schema Review schema changes before work begins label Oct 17, 2024
@hpidcock hpidcock added the kind/feature suggests new feature or enhancement label Oct 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/schema Review schema changes before work begins kind/feature suggests new feature or enhancement
Projects
None yet
Development

No branches or pull requests

4 participants