Skip to content

Stand up locally

You'll need the following to run iridium locally:

Iridium is dependent on an RDBMS system such as MySQL or MariaDB.

Note: all commands are run from the root of the distribution folder you downloaded and extracted in the previous step, The set-up in this document is not intended for production purposes.

Want help running Iridium?

Try our hosted solution for free

Stand up the database

Run an instance of MariaDB locally.

$ docker run  --name mariadb \
    -p 3306:3306 \
    -e MYSQL_ROOT_PASSWORD=iridium \
    -e MYSQL_DATABASE=identities \
    -e MYSQL_USER=iridium \
    -e MYSQL_PASSWORD=iridium \
    -d mariadb:latest

Now you'll be able to start and stop the MariaDB container with the following commands.

$ docker stop mariadb
$ docker start mariadb

At this point you have an instance of MariaDB. You can verify this by executing docker ps, you should see similar output like below

 docker ps
CONTAINER ID   IMAGE                                        COMMAND                  CREATED         STATUS         PORTS                                        NAMES
a44c37b6d4c1   mariadb:10.6.11                              "docker-entrypoint.s…"   6 seconds ago   Up 3 seconds   0.0.0.0:3306->3306/tcp                       mariadb

We still need to initialize the database with specific data for Iridium to function

Initialize the Iridium Database

Iridium needs specific data entities to exist for it to function. This guide demonstrates how to use the iridium CLI to execute this task. This document assumes you have downloaded and unpacked the binary distribution of Iridium in a previous step as detail here.

To initialize the database execute the following command. Again we are expecting you to be in the top level folder of expanded tar.gz distribution you downloaded and unpacked earlier.

NOTE Iridium init is meant to be non-destructive in that if you initialize the database once it will not work again. You will need to bring your containers all the way down to run the init function again.

  1. Initialize with a social provider

Initialize with Iridium with a Login Provider

Again we are expecting you to be in the top level folder of expanded tar.gz distribution you downloaded and unpacked earlier. For ease of getting started lets focus on using only one provider at the moment. You'll need to set your GitHub Client credentials in the file below. Instructions on how to do this with GitHub are here. You can do this by executing.

$ vim conf/external-providers.yaml

Modify the contents of the file to match below, you'll need to modify the values to be specific for your GitHub Oauth application.
You will want to remove the Google YAML block for this quick start.

- name: "github"
  clientId: "${yourClientId}"
  clientSecret: "${yourClientSecret"

Initialize the database

Run the following command to initialize the database with the GitHub credentials, and other needed entities for Iridium to run.

$ ./bin/iridium init 

Upon successful initialization of the database you'll see similar output.

06:22:59.884 [main] INFO  software.iridium.cli.command.InitCommand - ########################################
06:22:59.884 [main] INFO  software.iridium.cli.command.InitCommand - Database successfully initialized
06:22:59.884 [main] INFO  software.iridium.cli.command.InitCommand - ########################################
06:22:59.884 [main] INFO  software.iridium.cli.command.InitCommand - Iridium Management Application ID is localRunIdChangeForProduction
06:22:59.885 [main] INFO  software.iridium.cli.command.InitCommand - Be sure to place this in the appropriate environment.ts file

Since this is a local run, you will not need to update your environment.ts as stated above.

Run the Iridium Core Server

Run the following command, again this is from the top level folder of the distribution you downloaded.

$ export SPRING_CONFIG_LOCATION=./conf/application.properties
$  java -jar ./lib/iridium-core-server-${iridium-version}.jar

If you want to run Iridium from source, Follow the instructions to run Iridium from Intellij here. From here, you should be able to log in to the Iridium Management UI using your GitHub account. At this point you've stood up the system with an Iridium tenant and an associated management application.