# Upgrades and backups

> How to upgrade the Eggent open core, back up the data folder, check the server's health, read logs and move Eggent to another machine.

Source: https://eggent.ai/docs/self-host-maintenance/

## Checking that it works {#health}

```bash
curl -fsS http://127.0.0.1:3000/api/health
```

The answer contains the status and the Eggent version. The same check works for monitoring.

The `docker compose` commands below run in the install folder (`~/.eggent` if you used the installer). Container logs:

```bash
docker compose logs -f --tail=200
```

## Upgrading {#upgrade}

Make a [backup](https://eggent.ai/docs/self-host-maintenance.md#backup) before upgrading.

**Installed with the installer** — just run it again; it updates the code and rebuilds the container:

```bash
curl -fsSL https://get.eggent.ai | bash
```

**The published image** — change `EGGENT_VERSION` in `.env` to the new version and run:

```bash
docker compose -f docker-compose.ghcr.yml pull
docker compose -f docker-compose.ghcr.yml up -d
```

**From source**:

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

What changed in each version is in the [GitHub releases](https://github.com/eggent-ai/eggent/releases).

## Backups {#backup}

All of Eggent's state is the `data/` folder. To back it up, archive it:

```bash
docker compose stop
tar czf eggent-data-$(date +%F).tgz data
docker compose start
```

Stopping keeps files from changing during the copy. Keep backups off the server: `data/` holds keys and tokens, so treat the archive as a secret.

## Moving to another machine {#migrate}

1. Install Eggent on the new machine the same way.
2. Stop it and replace its `data/` folder with the copy from the old machine.
3. Start it again. Chats, projects, settings, keys, schedules and the Telegram bot all move with the folder.

If the public address changes, update `APP_BASE_URL` and press **Activate Bot** again in **Settings → Messengers** so Telegram learns the new webhook address.

## Restarts and schedules {#restart}

On start-up Eggent re-arms every saved [schedule](https://eggent.ai/docs/schedules.md). Runs missed while the server was off are not repeated: the task runs at its next scheduled time. One-off tasks whose time has passed are removed.

## The speech recognition model {#whisper}

The `whisper.cpp` model is downloaded on the first transcription into `data/models/whisper/`. For a more accurate one, set `EGGENT_STT_MODEL=small` (or `medium`) and recreate the container; the new model downloads by itself. Without internet access, put the `ggml-<model>.bin` file in that folder by hand.
