Skip to main content
Glama

create_config

Create an immutable config object for Docker Swarm to store non-sensitive configuration files like nginx.conf, mounted into service containers.

Instructions

Create an immutable Swarm config object; requires a swarm manager.

Configs store non-sensitive configuration files (nginx.conf, app.yaml, etc.) and mount them into service containers at a specified path. Unlike secrets, config data is not encrypted at rest — use create_secret for credentials or keys. data is raw bytes; encode strings first (e.g. "my config".encode()). Once created, a config is immutable: to update it, create a new config with a new name and update the service to reference it, then remove the old config with remove_config.

args: name - Unique config name within the swarm data - Raw bytes content of the config file labels - Labels to apply to the config object templating - Templating driver config (e.g. {"Name": "golang"} for Go template syntax) returns: dict - The created config's attrs including its id

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dataYes
nameYes
labelsNo
templatingNo
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond annotations (readOnlyHint=false, destructiveHint=false), the description discloses key traits: configs are immutable, data must be raw bytes (with encoding advice), requires swarm manager, and returns created config's attributes including id. No contradictions with annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is thorough but not overly verbose. It is front-loaded with the main purpose, then details parameters and return. A minor reduction in length could improve conciseness, but it remains efficient.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given 4 parameters, no output schema, and nested objects, the description covers purpose, usage, all parameter meanings, behavioral traits (immutability, encryption compared to secret), and return value. It is complete for effective tool invocation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Despite 0% schema description coverage, the description adds meaningful explanations for all 4 parameters: name (unique), data (raw bytes, encoding hint), labels (object), templating (example: golang). This fully compensates for the schema gap.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb 'Create', the resource 'immutable Swarm config object', and notes it requires a swarm manager. It distinguishes from sibling tools like 'create_secret' by explaining that configs are not encrypted at rest, directly differentiating their use cases.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description mentions prerequisites ('requires a swarm manager') and explicitly contrasts with 'create_secret' for when not to use it. It also provides lifecycle guidance (immutable, update by creating new config). However, it does not explicitly state when to use this tool over other config-related tools like 'list_configs' or 'get_config', but the primary use case is clear.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/GavinLucas/docker-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server