ZoneCloud Controller Handbook

Table of contents

Creating a cluster

Navigate to Clusters and press the “Create cluster” button.

Give your new cluster a name press the “Create” button.


Creating an agent

Navigate to “Servers” and press the “Create Server” button.

Fill in the required fields and press “Save”.

Server name: could be the hostname of the server, unique for each agent
Server token: will be used in the agent’s configuration file, press the “GENERATE” button to create a random one
IP: The server’s IP
Agent selection active
Cluster: Select the appropriate cluster from the list

Navigating back to the Servers page, you should see the newly created server/agent.


Creating a node

Navigate to “Servers” and press the “Create Server” button.

Fill in the required fields and press “Save”.

Server name: could be the hostname of the server, unique for each agent
Server token: will be used in the nodes’s configuration file, press the “GENERATE” button to create a random one
IP: The server’s IP
Node selection active
Cluster: Select the appropriate cluster from the list

Navigating back to the Servers page, you should see the newly created server/node.


Easy ZoneCloud configuration for agents/nodes

Navigate to “Servers” and press the “Configuration” button for the agent/node you want to setup.
You can copy-paste the configurations on your agent/node.

e.g.:


Creating a user

Navigate to Users and press the “CREATE USER” button.
Fill in the appropriate fields and press “Create”.


Excluding a zone

If for some reason you want a zone to not be served by an agent, all you have to do is navigate to Zones page and press the “Exclude” button.


Removing a zone exclusion

Navigate to Zones page and locate the zone on the “Excluded zones” table.
Press the “Remove exclusion” button.


Changing timezone

The time zone can be set on the .env file:


External API Access

Token authorization

To allow an external application to interact with ZoneCloud Controller’s API, you need to create an access token.

You can do this from the App API Access page.
From this page you can create new tokens or revoke existing ones.

Endpoints

POST /api/check_zone_active

 

Parameter name

Value

zoneRequired
The zone name to be checked if it is active
clusterOptional
The cluster name to search for the zone
extra_infoOptional
Value = 1
Appends “active_in” and “excluded_in” info for the zone where applicable.

 

Result

Output (JSON)

Zone is active
Zone is active (with extra_info=1)
Zone is not active
Authorization header missing/invalid
Wrong cluster name
Missing zone parameter

 

curl examples:

POST /api/exclude-zone

Exclude a zone from an agent.

Parameter name

Value

zoneRequired
The zone name to exclude
server_nameRequired
The agent’s name to exclude the zone from

Result

Output (JSON)

Zone is excluded
Server not found
Zone not found in agent
Authorization header missing/invalid
Missing zone/server_name parameter
 

curl examples:

POST /api/remove-exclude-zone

Remove a zone exclusion from an agent.

Parameter name

Value

zoneRequired
The zone name to remove exclusion
server_nameRequired
The agent’s name to remove exclusion of zone from

Result

Output (JSON)

Zone exclusion removed
Server not found
Zone not found in agent
Authorization header missing/invalid
Missing zone/server_name parameter
 

curl examples:

GET /api/get-duplicate-zones

Responds with duplicate zones along with a list of the servers that the zone is active in.

Takes no parameters.

curl exapmles:

Scroll to Top