chore: add ai_gateway options that alias aibridge options (#25061)

Adds options matching new AI Gateway naming.
New options are added as alias for old options. Old options are still
working.
Old options have deprecated message.
No conflict detection was added.

Updated documentation so it mentions only new options. Added note about
old options still working.

> Various AI tools where used to create this PR
This commit is contained in:
Paweł Banaszewski
2026-05-21 11:14:11 +02:00
committed by GitHub
parent f1b772928d
commit 46e93e6325
23 changed files with 1572 additions and 708 deletions
+6 -6
View File
@@ -33,7 +33,7 @@ a YAML configuration file.
| Connection Logs | `--connection-logs-retention` | `CODER_CONNECTION_LOGS_RETENTION` | `0` (disabled) | How long to retain Connection Logs |
| API Keys | `--api-keys-retention` | `CODER_API_KEYS_RETENTION` | `7d` | How long to retain expired API keys |
| Workspace Agent Logs | `--workspace-agent-logs-retention` | `CODER_WORKSPACE_AGENT_LOGS_RETENTION` | `7d` | How long to retain workspace agent logs |
| AI Gateway | `--aibridge-retention` | `CODER_AIBRIDGE_RETENTION` | `60d` | How long to retain AI Gateway records |
| AI Gateway | `--ai-gateway-retention` | `CODER_AI_GATEWAY_RETENTION` | `60d` | How long to retain AI Gateway records |
> [!NOTE]
> AI Gateway retention is configured separately from other retention settings.
@@ -59,7 +59,7 @@ coder server \
--connection-logs-retention=90d \
--api-keys-retention=7d \
--workspace-agent-logs-retention=7d \
--aibridge-retention=60d
--ai-gateway-retention=60d
```
### Environment Variables Example
@@ -69,7 +69,7 @@ export CODER_AUDIT_LOGS_RETENTION=365d
export CODER_CONNECTION_LOGS_RETENTION=90d
export CODER_API_KEYS_RETENTION=7d
export CODER_WORKSPACE_AGENT_LOGS_RETENTION=7d
export CODER_AIBRIDGE_RETENTION=60d
export CODER_AI_GATEWAY_RETENTION=60d
```
### YAML Configuration Example
@@ -81,7 +81,7 @@ retention:
api_keys: 7d
workspace_agent_logs: 7d
aibridge:
ai_gateway:
retention: 60d
```
@@ -152,7 +152,7 @@ retention:
api_keys: 7d
workspace_agent_logs: 7d
aibridge:
ai_gateway:
retention: 60d
```
@@ -198,7 +198,7 @@ retention:
api_keys: 0s # Keep expired API keys forever
workspace_agent_logs: 0s # Keep workspace agent logs forever
aibridge:
ai_gateway:
retention: 0s # Keep AI Gateway records forever
```