The Instruqt CLI is the terminal-based interface to the Instruqt platform. Use it to:
Create a new track from scratch
Pull the configuration files of an existing track
Push your local changes to Instruqt, to update the track
Start an automated test of the track
Before you can get started, you'll need to install and authenticate the Instruqt CLI.
Download the latest release
Extract the archive
Move the binary to a location in your
$PATH, for example:
To test if you can run the CLI, run the
instruqt command in your terminal
To start developing tracks with the CLI, authenticate your local install first
instruqt auth login in your terminal
Open the generated URL in your browser
Log in using your Instruqt credentials
$ instruqt auth login==> Signing in to instruqt==> Please open the following address in your browser andsign in with your Instruqt credentials:==> <http://localhost:15777/>==> Storing credentialsOK
To keep you logged in, Instruqt stores an access token in your home directory on the path
.config/instruqt/credentials and refreshes the token periodically. If you don't use the CLI for some time, you might be asked to login again.
We only support the latest version of the CLI. If a newer version is available, the CLI blocks and asks you to upgrade first. You can also manually upgrade using
$ instruqt update==> Updating CLI.OK
If you run the Instruqt CLI in a non-interactive way, for example in your CI, always run
instruqt update first to make sure you use the latest version.
When using the CLI in CI pipelines (e.g. when updating content from a pull request, or running automated tests), you can use an API token to authenticate. To create (or regenerate) an API token, visit the API section of your organization page.
To authenticate the CLI using an API token, you can set the
INSTRUQT_TOKEN environment variable.