libcluster_hcloud v0.1.1 ClusterHcloud.Strategy.Labels View Source
This clustering strategy works by loading all instances of the project matching the given label selector. See the hcloud docs for further details.
All instances must be started with the same app name and have security groups configured to allow inter-node communication.
config :libcluster,
topologies: [
labels_example: [
strategy: Elixir.ClusterHcloud.Strategy.Labels,
config: [
hcloud_api_access_token: "xxx",
label_selector: "mylabel",
app_prefix: "app",
private_network_name: "my-network",
show_debug: false,
polling_interval: 10_000]]],
Configuration Options
Key | Required | Description |
---|---|---|
:hcloud_api_access_token | yes | Access token for the hcloud project. |
:label_selector | yes | Label selector matching for the servers to be clustered. |
:app_prefix | no | Will be prepended to the node's IP address to create the node name. |
:private_network_name | no | Allows to use a specific internal hcloud network to determine the IP address. If not specified, the public IP address will be used. |
:polling_interval | no | Number of milliseconds to wait between polls to the hcloud api. Defaults to 5000 . |
:show_debug | no | True or false, whether or not to show the debug log. Defaults to true . |
Link to this section Summary
Functions
Returns a specification to start this module under a supervisor.
Callback implementation for Cluster.Strategy.start_link/1
.
Link to this section Functions
Returns a specification to start this module under a supervisor.
See Supervisor
.
Callback implementation for Cluster.Strategy.start_link/1
.