> For the complete documentation index, see [llms.txt](https://docs.nalpeiron.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.nalpeiron.com/zentitle2-docs/ui-local-license-server/local-license-server-lls/local-license-server-installation.md).

# Local License Server Installation

{% hint style="info" %}
The Zentitle2 Local License Server (LLS) is a docker application.
{% endhint %}

You can run it with any Docker tool, like Docker Compose, **but it is preferred to run it using a more advanced Docker orchestration platform, like Docker Swarm or K8S**.

{% hint style="info" %}
Credentials to our package registry can be created in the Zentitle2 interface (Administration -> API Credentials -> Package Registry)
{% endhint %}

### Prerequisites <a href="#prerequisites" id="prerequisites"></a>

1. You have the credentials to our package registry.
2. You have **Docker** installed on your host machine.

**Downloading the docker image**

You can download the docker image from our Docker registry using the deploy token you provided.

1. Login into the container registry with `docker login registry.gitlab.com - u <username or token name> -p <token>`
2. The docker image path is `registry.gitlab.com/nalpeiron/zentitle/local-license-server:[version]`

**Dependencies**

The only dependency required by the LLS application is a **PostgreSQL database**.

**Environment variables**

Before starting the LLS container, the following ENV variables need to be configured:

* **ConnectionStrings\_\_Database**: Connection string to the PostgreSQL database. Sample value: `Server=postgres-lls; Database=lls; User Id=lls; Password=password`
* **Authentication\_\_Username:** Username for LLS Management API endpoints
* **Authentication\_\_Password:** Password for LLS Management API endpoints

**Running the LLS service**

During the first startup, the service creates the DB schema in the PostgreSQL DB configured in the ENV variable and seeds it with the initial data. The service is running on the port `6501`by default.\
\
You should be able to access the server interface on the `/ui` address, or verify that the service is up and running by checking the `/health` endpoint’s response. The Swagger UI is available within the `/swagger` endpoint.

By default, the LLS service’s API is running over the **HTTP** protocol. If the vendor/client wants to run the service over **HTTPS**, they should provide a proxy and manage the SSL certificates themselves.

### Running the demo application <a href="#running-the-demo-application" id="running-the-demo-application"></a>

![](/files/DbpcTejqofOSQd5mDt87) Login into the container registry:

```
docker login registry.gitlab.com -u <token name> -p <token>
```

![](/files/SyZ11C7WMHmB8UFwG53G) Download the `docker-compose.z2-lls-demo.yml` file.

{% file src="/files/VKjrPgXRGLaqvYoiJiLq" %}

![](/files/pb16tBj3PaH7xgCTupGp) In the docker-compose file, replace the local-license-server service's image **\[version]** placeholder with the image version number provided by the account manager.

![](/files/GTHQEVatNnZIkCLo6YRk) Optionally override some environment variables for the `zentitle-lls-demo` service in the docker-compose file.

![](/files/Ct0kIWuoColfpOeGA1z6) Run the service as follows:

```
docker-compose -f docker-compose.z2-lls-demo.yml up -d
```

![](/files/GpXbE0sMiWJwGF0BgTBl) Check if the UI runs properly on <http://localhost:6501/ui>. Use the basic authentication credentials from step 4 to log in.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.nalpeiron.com/zentitle2-docs/ui-local-license-server/local-license-server-lls/local-license-server-installation.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
