Skip to content
Tim Gerhard edited this page Jan 26, 2017 · 1 revision

Web resources are resources which are only available on the webfrontend. This page will explain how web resources can be set up and used.

Custom Element Icons

Users can select any icon as element icons in the elements' configuration window. Custom element icons are a list of icons with URLs and names provided by the testbed administrators. They can be found in ToMaTo's menu bar.

In order to set them up, the URL at the key web/web-resources/custom-element-icons in config.yaml must point to a valid JSON document. An example for this together with some icons can be found at contrib/custom_icons.

Default Executable Archives

Default executable archives are executable archives provided by the testbed administrators. They are integrated into the topology editor.

In order to set them up, the URL provided at the key web/web-resources/default-executable-archive-list in config.yaml must point to an index JSON document. It contains a list of JSON objects consisting of an internal name, a label, and a relative or absolute URL to a detailed description:

[{ "name": "install_python", "label": "Install Python", "url": "install_python/index.json" }, {...}]

The description looks like this, with a relative link to an icon and the archive, together with a description and a creation date in ISO format:

{ "icon": "icon.png", "default_archive": "install_java.tar.gz", "description": "Install Java on debian or ubuntu", "creation_date": "2016-08-19", "alternatives": [{...}] }

The alternatives are a list of alternative archives. This is useful if, for some reason, the default archive is incompatible with certain templates. Each entry in the alternatives list looks like this:

{ "archive": "install_java.tar.gz", "creation_date": "2016-08-19", "description": "Install Java on debian or ubuntu", "templates": ["debian-8", "full:debian-7"] } Where templates is a list of templates, which can be type-specific or for all types.