> ## Documentation Index
> Fetch the complete documentation index at: https://support.lilt.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Scheduling Maintenance-Window Banners

## Overview

Display a platform-wide banner to notify users of an upcoming or in-progress maintenance window. The banner appears on every page of the Lilt UI while the current time is within the window, and disappears automatically when the window ends.

For self-managed installations, banners are scheduled and cancelled with the `admin-cli` tool. (Lilt SaaS uses Retool against the same underlying `WebsiteBanners` table.)

## Required Tools

You will need to use SSH to connect to the systems.

* On the Mac or Linux, you can open a terminal window and use ssh.

* On Windows, you can use the PuTTY ssh client.

### Installer Privileges

Users need to have access to the kubernetes cluster that hosts the application.

## Schedule a maintenance-window banner

#### Connect to the front pods

`$ kubectl exec -it <frontPod> -c front -- /bin/bash`

<Note>
  Steps to fetch \<frontpod>:

  * connect to the kubernetes cluster

  * fetch \<frontpod> by running:

    * `kubectl get pods -n lilt | grep -i front`
</Note>

#### Create the banner

**Times must be ISO 8601 with explicit UTC** (`Z` or `+00:00`). Local times are rejected to prevent banners from showing at the wrong time.

`$ npm run dist-admin-cli -- create-maintenance-window --start "<start-iso-utc>" --end "<end-iso-utc>" --message "<message>"`

Example:

```bash theme={null}
$ npm run dist-admin-cli -- create-maintenance-window \
    --start "2026-06-01T03:00:00Z" \
    --end   "2026-06-01T05:00:00Z" \
    --message "Scheduled maintenance: Lilt will be unavailable for approximately 2 hours."
```

The command prints the new banner's `id`:

```
Maintenance window created (id=42).
  Starts:  2026-06-01T03:00:00Z
  Ends:    2026-06-01T05:00:00Z
  Message: Scheduled maintenance: Lilt will be unavailable for approximately 2 hours.
```

<Note>
  Record the `id` from the output. You will need it to cancel the banner before its scheduled end time.
</Note>

## Cancel a scheduled banner

#### Connect to the front pods

`$ kubectl exec -it <frontPod> -c front -- /bin/bash`

#### Delete by id

`$ npm run dist-admin-cli -- delete-maintenance-window --id <id>`

Example:

```bash theme={null}
$ npm run dist-admin-cli -- delete-maintenance-window --id 42
Deleted maintenance window id=42.
```

#### Delete every currently-active banner (when the id is unknown)

`$ npm run dist-admin-cli -- delete-maintenance-window --all-active`

Example:

```bash theme={null}
$ npm run dist-admin-cli -- delete-maintenance-window --all-active
Deleted 1 currently-active maintenance window(s).
```

This only affects banners whose window includes the current time. Past banners are left as historical records; future banners (not yet started) are also untouched.

## Notes

* Banners are **soft-deleted** — the row remains in the `WebsiteBanners` table with `isDeleted = true` for audit purposes.
* Past banners (whose `endDate` has passed) disappear from the UI automatically; there is no need to delete them.
* Banner display is identical to Lilt SaaS — the UI reads the same `/website-banners` endpoint.
