# `LLMProxy.ReleaseTasks`
[🔗](https://github.com/elixir-vibe/llm_proxy/blob/v0.3.1/lib/llm_proxy/release_tasks.ex#L1)

Release-safe operational tasks for standalone LLMProxy deployments.

These functions are intended to be called through `bin/llm_proxy eval ...`
by systemd jobs or operators. Release `eval` runs in a new, non-booted VM,
so tasks that need bundled storage start only the local dependencies they use.

# `codex_login`

```elixir
@spec codex_login([String.t()]) :: :ok
```

Runs an interactive OpenAI Codex OAuth login and stores the provider token.

# `drain_await`

```elixir
@spec drain_await(timeout()) :: :ok
```

Wait for active work on the running LLMProxy service to reach zero.

# `drain_cancel`

```elixir
@spec drain_cancel() :: :ok
```

Cancel deployment drain mode on the running LLMProxy service.

# `drain_for_deploy`

```elixir
@spec drain_for_deploy(timeout()) :: :ok
```

Drain active work before deployment, restoring service on failure.

# `drain_start`

```elixir
@spec drain_start() :: :ok
```

Start deployment drain mode on the running LLMProxy service.

# `drain_status`

```elixir
@spec drain_status() :: :ok
```

Print deployment drain status from the running LLMProxy service.

# `migrate`

```elixir
@spec migrate() :: :ok
```

Runs all pending Ecto migrations for the configured LLMProxy repo.

# `provider_tokens_decrypt`

```elixir
@spec provider_tokens_decrypt() :: :ok
```

Restore provider tokens to plaintext for a controlled rollback.

# `provider_tokens_encrypt`

```elixir
@spec provider_tokens_encrypt() :: :ok
```

Encrypt plaintext provider tokens with the active codec key.

# `provider_tokens_rotate`

```elixir
@spec provider_tokens_rotate() :: :ok
```

Re-encrypt all provider tokens with the active codec key.

# `provider_tokens_status`

```elixir
@spec provider_tokens_status() :: :ok
```

Print provider-token encryption state without credential values.

# `provider_tokens_verify`

```elixir
@spec provider_tokens_verify() :: :ok
```

Verify that the configured codec can read all provider tokens.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
