---
title: Deploy InfluxDB with AI on Blossom
url: "/deploy/influxdb/"
canonical_url: https://blossom88.com/deploy/influxdb/
markdown_url: https://blossom88.com/deploy/influxdb.md
summary: Deploy InfluxDB OSS 2 on Blossom, write app metrics with a scoped token,
  and query them in Data Explorer.
categories:
- deployment
- monitoring
stack:
- Go
- Flux
- InfluxDB OSS 2
---

# Deploy InfluxDB with AI on Blossom

[InfluxDB](https://www.influxdata.com/) stores measurements over time.
This recipe uses the [MIT-licensed OSS 2 edition](https://github.com/influxdata/influxdb/blob/v2.10.1/LICENSE)
with its built-in Data Explorer.

![Open the sample metrics bucket.](/deploy/assets/images/influxdb/sample-metrics-bucket.webp)

## Ask Your Agent

> **Ask your AI agent:** Deploy InfluxDB on Blossom and help me write and query my first app metrics.
>
> Follow this guide: https://blossom88.com/deploy/influxdb/

[Install the Blossom CLI and skill](https://docs.blossom88.com/learn/getting-started/install/) on your agent's machine and [choose a Location in your cloud account](https://docs.blossom88.com/learn/getting-started/choose-your-cloud/#connect-your-provider).

## Have Ready

Nothing is required beyond your Blossom account.

- **A source of metrics** (Later): Start with synthetic samples, then connect your app or collector.

## How It Runs

| Part | Role | Where |
|---|---|---|
| InfluxDB OSS 2 | Metrics API, storage, and Data Explorer | Persistent Service |
| Your app or collector | Writes measurements with the bucket token | Your App or server |

## Deploy InfluxDB

Run the official OSS 2 image as one
[Persistent Service](/docs/apps/persistent-services/). Keep the setup
page and Data Explorer behind Blossom Account access.

<details class="optional-reading" markdown="1">
<summary>Notes for your agent</summary>

Use port 8086 and the `/health` endpoint. Mount the Volume at
`/var/lib/influxdb2` to retain measurements, settings, and
token permissions. Use the InfluxDB 2 image series for this recipe.

</details>

<details class="optional-reading" markdown="1">
<summary>Commands your agent runs</summary>

    blossom app_plan:preview --data influxdb-plan.yml
    blossom service:create --data influxdb-service.yml
    blossom environment:deploy --id environment-100 --follow

</details>

## Create a Bucket and Token

Finish setup once, create a metrics bucket, and make a token with
only the read and write permissions it needs for that bucket. An app
or collector in the same Environment can write to the private Service
address.

> **Ask your AI agent:** Set up my first metrics bucket and give my app a token scoped to that bucket.

> Follow this guide: https://blossom88.com/deploy/influxdb/



## Query Your First Measurements

Write a sample latency measurement with your token. Open
[Data Explorer](https://docs.influxdata.com/influxdb/v2/query-data/execute-queries/data-explorer/)
and query the bucket to see what arrived.

> **Ask your AI agent:** Write a sample latency measurement and show it in the InfluxDB Data Explorer.

> Follow this guide: https://blossom88.com/deploy/influxdb/



## Keep It Running

Reuse the Volume when updating InfluxDB. Query the earlier
measurement, then write and read another with the same scoped token.

![Query original and new samples after Container replacement.](/deploy/assets/images/influxdb/measurements-after-redeploy.webp)

## What You Get

- A bucket for your application's time-series measurements
- A read and write token scoped to that bucket
- A private Data Explorer for querying measurements
- History and token permissions that persist across updates

Tested on Blossom: The same scoped token queried the first measurement and wrote a second after Container replacement. A second bucket stayed outside its scope.
