# Upgrade

Use this page to upgrade a Docker Compose deployment.

{% hint style="warning" %}
Back up your PostgreSQL metadata databases before upgrading. See [Back up PostgreSQL](/deploy-syntho/deploy-syntho-using-docker/back-up-postgresql.md).
{% endhint %}

These commands assume you run them from the folder that contains `docker-compose.yaml` and `.env`.

{% stepper %}
{% step %}
**Refresh registry authentication (if needed)**

Use the registry host and credentials provided by Syntho to login with:

```bash
docker login syntho.azurecr.io -u <USERNAME> -p <PASSWORD>
```

{% hint style="info" %}
Ensure that `syntho.azurecr.io` is added to your firewall allowlist to enable image pulls
{% endhint %}
{% endstep %}

{% step %}
**Update `.env`**

* `APPLICATION_VERSION:<new-applicationversion>`
* `LICENSE_KEY:<new-license-key>`
  {% endstep %}

{% step %}
**Pull new images and restart**

```bash
docker compose pull
docker compose up -d
```

{% endstep %}

{% step %}
**Verify**

```bash
docker compose ps
docker compose logs -f
```

Open the UI and confirm you can log in.
{% endstep %}
{% endstepper %}


---

# Agent Instructions: 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:

```
GET https://docs.syntho.ai/deploy-syntho/deploy-syntho-using-docker/upgrade.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
