Managing a Space

Service Password

A service password can be set by going My Profile and entering the chosen password in the Service Password field, if not set the system will generate a random password.

This can then be used in templates as the variable ${{ .user.service_password }}, e.g. for a MariaDB server it can be used as the root password by setting the MARIADB_ROOT_PASSWORD environment variable MARIADB_ROOT_PASSWORD = "${{.user.service_password}}".

ℹ️
If the password is change the new password isn’t immediately made available to the spaces, however it will be used on the next start of the space.

Creating a Space

From the Templates page open the menu next to the template to use and click Create Space:

ℹ️
Depending on the permissions the user has the option Create Space For maybe displayed, clicking this will prompt for the user under which the space is to be created. This allows an admin to create spaces for users.

The fllowing form will be presented:

Enter a name for the space e.g. mytest and leave the Terminal Shell as Bash, once Create Space is clicked the space will be created within knot and the main spaces page loaded.

The space is created in a stopped state, no resources are used within the Nomad cluster at this point.

The Additional Space Names section allows additional names to be entered against the space, this is useful when using the web proxy service and development needs to access the target software under multiple domain names.

Manual Spaces

It’s possible to run the agent manually on a virtual machine or even a physical server and connect to it from the knot web interface.

Select the Manual-Configuration template, then fill out the URL of the agent e.g. http://192.168.0.1:3000 if the address can be found via a DNS SRV lookup then the URL can be given in the form srv+http://vm.service.consul.

Starting a Space

From the Spaces page click the menu item next to the space to start, and then select Start, them menu will change to read “Starting” and after a few seconds the Running will show in the Status column.

The environment will continue its boot process during which time additional icons will appear next to the space, e.g. Terminal.

Not all icons will appear for all spaces as they are dependant on the agent configuration within the space.

  • SSH Is shown when it’s possible to create a SSH connection to the space, clicking the icon will show the command line information for connecting to the space.
  • Code Server Is shown if a running instance of Visual Studio Code is found running within the space, clicking the icon opens a new tab or window showing the editor.
  • Terminal Is shown if a web based terminal can be opened into the space, clicking the icon opens a new window showing the terminal.
  • Ports Is shown if there’s ports exposed that can either be connected to via the web interface or via port forwarding on the command line. Clicking the icon drops down a list of the available ports, ports shown with a solid background can be connected to by clicking the button and will open in a new tab or window, while ports with an outline are available for use with port forwarding on the command line.
  • Desktop Is show if a running web based VNC server such as KasmVNC is available within the container. Clicking it will open a new window displaying the graphical desktop.

Stopping a Space

Clicking the menu item next to the running space will show the Stop button.

⚠️
When stopping a space all data in memory and not on a persistent volume will be lost. However any volumes used by the space will not be deleted.

Updating a Space

If the template that a running space is using is updated then an Update Available badge is displayed:

To update the space, stop it and then start it again. Add volumes that have been added to the template will be created when the space starts and any volumes that have been removed from the template will be deleted along with the data they contain.

A space can also be edited, this allows changing of the space name as well as updating any additional names for the space. Additional URLs are supported as soon as the space is successfully saved.

Deleting a Space

🚫
Deleting a space will delete the volumes and any data they contain.

Only stopped spaces can be deleted.

From the menu next to the stopped space select the Delete item and confirm deletion. When the space is deleted all resources are freed from the Nomad cluster and all volumes and their associated data are removed.