Skip to content

Commit

Permalink
doc/instances/scriptlet: Add get_cluster_members
Browse files Browse the repository at this point in the history
Signed-off-by: Yueyuanmei Zhang <[email protected]>
  • Loading branch information
Yueyuanmei Zhang committed Apr 20, 2024
1 parent 1c2c9b4 commit b676223
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions doc/explanation/clustering.md
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,7 @@ The following functions are available to the scriptlet (in addition to those pro
- `get_cluster_member_state(member_name)`: Get the cluster member's state. Returns an object with the cluster member's state in the form of [`api.ClusterMemberState`](https://pkg.go.dev/github.com/lxc/incus/shared/api#ClusterMemberState). `member_name` is the name of the cluster member to get the state for.
- `get_instance_resources()`: Get information about the resources the instance will require. Returns an object with the resource information in the form of [`scriptlet.InstanceResources`](https://pkg.go.dev/github.com/lxc/incus/shared/api/scriptlet/#InstanceResources).
- `get_instances(location, project)`: Get a list of instances based on project and/or location filters. Returns the list of instances in the form of [`[]api.Instance`] (https://pkg.go.dev/github.com/lxc/incus/shared/api#Instance).
- `get_cluster_members(group)`: Get a list of cluster members based on the cluster group. Returns the list of cluster members in the form of [`[]api.ClusterMember`](https://pkg.go.dev/github.com/lxc/incus/shared/api#ClusterMember).

```{note}
Field names in the object types are equivalent to the JSON field names in the associated Go types.
Expand Down

0 comments on commit b676223

Please sign in to comment.