Skip to content

Getting Started

kandji-trent edited this page Jun 23, 2026 · 2 revisions

Getting Started

Quick Start

Follow the steps below to quickly get up and running with a local copy of your Iru Custom Resources.

  1. Create a new local repository: iructl new my-repo
  2. Change directories: cd my-repo
  3. Set your credentials:
    1. export IRUCTL_TENANT=<YOUR_API_URL_HERE>
    2. export IRUCTL_TOKEN=<YOUR_API_TOKEN_HERE>
  4. Download your custom profiles from Iru: iructl profile pull --all
  5. Download your custom scripts from Iru: iructl script pull --all
  6. Download your custom apps from Iru: iructl app pull --all

Note

Replace <YOUR_API_URL_HERE> and <YOUR_API_TOKEN_HERE> with your API URL and token. See the authentication section below for more details.

Tip

iructl app pull --all downloads app metadata only. Add --download to also fetch each app's installer into the payload directory.

Getting Help

Each command and subcommand has its own help screen, which can be accessed by appending --help. For example, iructl --help will display usage information, available options, a list of root-level commands, and a short description of each command (see below). Help screens for each subcommand can be accessed in the same way (e.g., iructl new --help).

Usage: iructl [OPTIONS] COMMAND [ARGS]...

 Iru Control - a utility for local management of Iru resources.

╭─ Options ────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ --preview                     Enable experimental preview features. [env var: IRUCTL_PREVIEW]                        │
│ --version                     Show the version.                                                                      │
│ --install-completion          Install completion for the current shell.                                              │
│ --show-completion             Show completion for the current shell, to copy it or customize the installation.       │
│ --help                        Show this message and exit.                                                            │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
╭─ Logging ────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ --log          TEXT  Path to the log file. (use '-' for stdout)                                                      │
│ --debug              Enable debug logging.                                                                           │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
╭─ Commands ───────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ profile   Interact with Iru Custom Profiles                                                                          │
│ script    Interact with Iru Custom Scripts                                                                           │
│ app       Interact with Iru Custom Apps                                                                              │
│ new       Create a new repository                                                                                    │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯

Creating Your Local Repository

Before doing anything else, you'll need to create a local repository. An iructl repository can be created in any directory using iructl new. Under the hood, an iructl repository is just a git repository with a .iructl file at its root, but using the command will include a handy README.md to get you started.

❯ iructl new iructl-repo
Created a new iructl repository at iructl-repo
Check out the included README.md file for more information on getting started.

Authenticate with Your Iru Tenant

With no configuration, you will be prompted for an Iru tenant API URL and a token when running a command that requires it.

$ iructl profile sync --all
Enter Iru Tenant URL: https://mysubdomain.api.iru.com
Enter API Token: ************

However, it's generally a better idea to store the credentials in environment variables. This removes the need to enter credentials for every command. The following environment variables are automatically checked by iructl before prompting the user.

Tip

These values can be added to your shell's startup file to be exported automatically.

Example ~/.profile, ~/.zshrc, or ~/.bashrc

export IRUCTL_TENANT="https://mysubdomain.api.iru.com"
export IRUCTL_TOKEN="not-a-real-token"

Clone this wiki locally