• READ
  • WRITE
  • DELETE
  • HUMAN

How to manage environment variables with your AI

Connect Dokku to your AI client to handle app configurations through natural language. You can change secrets or check current settings without touching a terminal.

Ask AI about this page

Short answer

How can I manage Dokku environment variables with AI?

Your AI client uses the Dokku MCP to read, set, or remove configuration keys for your deployed apps. This lets you update secrets or clear old variables using simple text commands. You'll see the results reflected in your app's runtime environment immediately.

Configuration outcomes

Where your settings land.

What happens when you ask your AI to change settings.

READ

View current settings

The AI pulls your existing configuration list. You get a clear view of what variables are currently active in your app.

WRITE

Update or add keys

The AI pushes new values or updates existing ones. Your app receives the new configuration once the command finishes.

DELETE

Remove old secrets

The AI strips specific keys from your app's config. This cleans up unused or expired credentials instantly.

HUMAN

Manual verification

You decide when a sensitive change is safe to commit. The AI handles the execution, but you maintain final oversight.

The workflow

What your AI does when the request arrives.

The AI translates your intent into specific Dokku commands.

  1. Audit current state

    The AI checks which variables are already set so it doesn't overwrite something important by mistake.

    list_config
  2. Apply changes

    The AI injects the new key-value pairs you requested into the application environment.

    set_config
  3. Clean up

    The AI removes the specific configuration keys you no longer need.

    unset_config
  4. Confirm success

    The AI verifies the action was successful and reports the new state back to you.

    list_config

Try it

Copy these to start.

Use these prompts to trigger actions in Dokku.

Starting points

Swap out the app names and variable keys with your actual Dokku deployment details.

Dokku Connector

You're all set. Choose your MCP client and follow the setup instructions.

Connector linkhttps://edge.vinkius.com/vk_preview_4l81eUQDUiIsTQzod0jOLzrGv5gyZbaFCGJYUggR/mcp

Claude Desktop

Follow the steps below to connect in seconds.

  1. 1In Claude Desktop, open Settings → Connectors.
  2. 2Click “Add custom connector” and paste the connector link above as the remote MCP server URL.
  3. 3Click Add and start a new chat — Dokku capabilities are ready to use.
Configuration · claude_desktop_config.jsonCopy
{
  "mcpServers": {
    "dokku-mcp": {
      "url": "https://edge.vinkius.com/vk_preview_4l81eUQDUiIsTQzod0jOLzrGv5gyZbaFCGJYUggR/mcp"
    }
  }
}
Copy into chat04
  • List all the environment variables for my app named 'web-api'.

  • Set the DATABASE_URL for 'production-app' to 'postgres://user:pass@host:5432/db'.

  • Remove the old API_KEY from my 'staging-service' app.

  • Check if the STRIPE_SECRET is currently set in my 'payment-gateway' app.

  • Claude
  • ChatGPT
  • Cursor
  • VS Code
  • Windsurf
  • Claude Code
  • JetBrains
  • Cline

Start here

Connect Dokku once, then ask.

Follow the link to link your Dokku instance. Your credentials stay encrypted, and you can immediately start managing apps through your AI client.

Connect Dokku to your AI

FAQ

How the task behaves

  • 01

    Can the AI deploy new applications?

    No. This MCP is limited to managing configuration and secrets for existing apps.

  • 02

    Will the AI delete my entire app if I make a mistake?

    No. The tools only allow for managing configuration keys, not deleting the application itself.

  • 03

    Does the AI see my actual database passwords?

    The AI sees the values you ask it to list or set, but it only interacts with the configuration layer provided by Dokku.

  • 04

    Can I use this to change my app's buildpack?

    No. The available tools are strictly for managing environment variables.

  • 05

    Do I need to use the Dokku CLI after connecting?

    You don't have to, but you can. The AI handles the configuration tasks so you can stay in your chat interface.

  • More questions about Dokku? The Connector page answers them. See everything the Dokku Connector can do

Connect Dokku to Claude, Cursor, ChatGPT & more