Create a track from a template
Speed up track building.
This guide explains how to create a template-based track through Web UI and Instruqt CLI.
Templates are track skeletons based on commonly used sandbox types. Using templates speeds up your track building. Because after creating from a template, you only have to complete the track. But first, you decide which template best suits your needs.

Before you begin

Did you check the Build tracks page? This page sets you off for creating tracks.

Create track

Step 1: Decide which template you need

Use the following table to decide which template best suits your needs:
Need/situation
Template
Content
I need a sandboxed AWS account in my Instruqt track
AWS Cloud Account
  • Link an AWS cloud account to your sandbox
  • Use the cloud client Docker container
  • Use the AWS CLI and UI from our learn environment
  • Limit usage of the cloud account using IAM and SCP policies
I need a container-based sandbox host
Sandbox container
Lightweight Linux system
I need a virtual machine with more computing power and memory. Or I want to run Docker containers.
Sandbox virtual machine
  • Provision virtual machine sandbox host using a predefined Compute Engine image
  • Use the Docker daemon on the sandbox host to build and run container images
  • Add check and solve scripts
  • Add simple assets (a Dockerfile) to the sandbox host
I need a pre-installed helm chart.
Helm chart
  • A virtual machine with a kubernetes cluster
  • Helm already installed on the machine
  • NGINX ingress controller pre-installed on the kubernetes cluster
I need a single node Kubernetes cluster
Kubernetes
  • Provision a single node k3s cluster on a virtual machine
  • Deploy a webserver (NGINX) on Kubernetes
  • Use a service tab to expose the web server through the Instruqt UI
I need a Kubernetes cluster on multiple sandbox hosts
Multi-node Kubernetes cluster
  • Provision a multi-node k3s cluster
  • Use a predefined Instruqt image with k3s
  • Pass parameters to a sandbox host using environment variables
  • Use the track setup script to block loading the track until all services are up
I need a VS Code editor
VSCode & TypeScript
  • Add IDE code editor features to an Instruqt track
  • Use a code server container to serve a VSCode IDE
  • Run a unit test suite in a check script

Step 2: Create a track from a template

This guide will choose the Kubernetes template. If you choose another template, replace your choice where appropriate.
Pick the Web UI or the Instruqt CLI route depending on your preference:
🌐 Web UI
πŸ’» Instruqt CLI
  1. 1.
    Open your browser and go to play.instruqt.com. ↳ Instruqt shows your content.
  2. 2.
    Click Create track on the Content page. ↳ The Start creating content page opens.
  3. 3.
    Click Create from template to open the Instruqt templates page.
  4. 4.
    Select the template of your choice. ↳ The Track info pop-up opens.
  5. 5.
    In the Track title field, enter your title.
  6. 6.
    In the Track slug field, modify the slug if you want to.
  7. 7.
    Click Create. ↳ Instruqt creates the track and shows the Track overview page of the newly created track.
  1. 1.
    Type the following command to create a track:
    instruqt track create
  2. 2.
    Enter the track title:
    ==> Track title: KubernetesTrack
  3. 3.
    Enter option 2 to select From a template:
    ==> Start with an empty track or use a template:
    ​
    [1] From scratch
    For full flexibility, start with an empty track
    [2] From a template
    To get started quickly, start from one of our templates
    ​
    Please select your method: 2
  4. 4.
    Enter the number of the template you want to use:
    ==> Choose a template:
    ​
    [1] AWS Cloud Account
    Learn how to build tracks with an AWS account
    [2] Sandbox container
    Get started quickly with just one container-based sandbox host.
    [3] Sandbox virtual machine
    Use a virtual machine (VM) as a sandbox host
    [4] Helm chart
    Learn how to install helm charts with Instruqt.
    [5] Kubernetes
    Learn how to build Kubernetes-based tracks with this template
    [6] Multi-node Kubernetes cluster
    Setup a Kubernetes cluster on multiple sandbox hosts
    [7] VSCode & TypeScript
    Edit and test TypeScript applications in VSCode
    ​
    Please select your template: 5
    ↳ Instruqt CLI creates the track and returns this output:
    Using the template: Kubernetes
    ​
    ==> Creating new track files:
    kubernetestrack
    β”œβ”€β”€ 01-deploying-nginx
    β”‚ β”œβ”€β”€ assignment.md
    β”‚ β”œβ”€β”€ check-kubernetes-vm
    β”‚ └── solve-kubernetes-vm
    β”œβ”€β”€ 02-exposing-nginx
    β”‚ β”œβ”€β”€ assignment.md
    β”‚ β”œβ”€β”€ check-kubernetes-vm
    β”‚ β”œβ”€β”€ setup-kubernetes-vm
    β”‚ └── solve-kubernetes-vm
    β”œβ”€β”€ 03-showing-the-service
    β”‚ └── assignment.md
    β”œβ”€β”€ 04-kubernetes-dashboard
    β”‚ β”œβ”€β”€ assignment.md
    β”‚ └── setup-kubernetes-vm
    β”œβ”€β”€ track_scripts
    β”‚ └── setup-kubernetes-vm
    β”œβ”€β”€ config.yml
    └── track.yml
    OK
    ==> More templates are available at https://play.instruqt.com/inspiration-library
    ​
    ==> To play your track, change into the track directory and push it to Instruqt:
    cd kubernetestrack
    instruqt track push
  5. 5.
    Deploy the track to the Instruqt platform:
    instruqt track push
  6. 6.
    Open your browser and go to play.instruqt.com/. ↳ Instruqt now shows the created track in your content.

Background: Created track directory and configuration files

Your output depends on the template you have chosen. The same applies to the created directories and files. But you will have these components anyway:
  • A main directory with the track name. In this case kubernetestrack
  • The configuration files config.yml and track.yml inside the main directory
  • A subdirectory whose name starts with 01. In this case: 01-deploying-nginx
  • The configuration files assignment.md, check-..., and solve-... inside the 01 subdirectory
kubernetestrack
β”œβ”€β”€ 01-deploying-nginx
β”‚ β”œβ”€β”€ assignment.md
β”‚ β”œβ”€β”€ check-kubernetes-vm
β”‚ └── solve-kubernetes-vm
β”œβ”€β”€ 02-exposing-nginx
β”‚ β”œβ”€β”€ assignment.md
β”‚ β”œβ”€β”€ check-kubernetes-vm
β”‚ β”œβ”€β”€ setup-kubernetes-vm
β”‚ └── solve-kubernetes-vm
β”œβ”€β”€ 03-showing-the-service
β”‚ └── assignment.md
β”œβ”€β”€ 04-kubernetes-dashboard
β”‚ β”œβ”€β”€ assignment.md
β”‚ └── setup-kubernetes-vm
β”œβ”€β”€ track_scripts
β”‚ └── setup-kubernetes-vm
β”œβ”€β”€ config.yml
└── track.yml
The topic configuration files explains the created files in detail. But the following table is already a short overview:
File
Purpose
Content
Remark
config.yml
Sets the characteristics for the sandbox
YAML
​
track.yml
Sets the characteristics for the track
YAML
​
assingment.md
Sets the characteristics for a challenge
Markdown
Created for every challenge in your track
check-...
Checks if the learner solved a challenge
Scripting language
The full name depends on your setting
solve-...
Solves a challenge automatically if the learner skips a challenge
Scripting language
The full name depends on your setting

​

Video tutorial

You can also watch this video tutorial for creating a track:
Well done! Now you can play your track to see if everything works as expected.
Copy link
Edit on GitHub
On this page
Before you begin
Create track
Step 1: Decide which template you need
Step 2: Create a track from a template