gitlab-container
GitLab container registry operations via API. ALWAYS use this skill when user wants to: (1) list container repositories, (2) view/delete image tags, (3) clean up old images, (4) manage Docker registry.
What this skill does
# Container Registry Skill
Container registry management for GitLab using `glab api` raw endpoint calls.
## Quick Reference
| Operation | Command Pattern | Risk |
|-----------|-----------------|:----:|
| List repositories | `glab api projects/:id/registry/repositories` | - |
| Get repository | `glab api projects/:id/registry/repositories/:repo_id` | - |
| Delete repository | `glab api projects/:id/registry/repositories/:repo_id -X DELETE` | ⚠️⚠️⚠️ |
| List tags | `glab api projects/:id/registry/repositories/:repo_id/tags` | - |
| Get tag | `glab api projects/:id/registry/repositories/:repo_id/tags/:tag` | - |
| Delete tag | `glab api projects/:id/registry/repositories/:repo_id/tags/:tag -X DELETE` | ⚠️⚠️ |
| Bulk delete tags | `glab api projects/:id/registry/repositories/:repo_id/tags -X DELETE -f ...` | ⚠️⚠️⚠️ |
**Risk Legend**: - Safe | ⚠️ Caution | ⚠️⚠️ Warning | ⚠️⚠️⚠️ Danger
## When to Use This Skill
**ALWAYS use when:**
- User mentions "container", "registry", "docker image", "container image"
- User wants to list or delete Docker tags
- User mentions "image cleanup", "registry cleanup"
- User wants to view container repository information
**NEVER use when:**
- User wants to build/push Docker images (use CI/CD or docker CLI)
- User wants to run containers (use docker CLI or orchestrator)
- User wants package registry (different API)
## API Prerequisites
**Required Token Scopes:** `read_registry`, `write_registry` (for delete operations), or `api`
**Permissions:**
- Read registry: Reporter+
- Delete images: Developer+ (or Maintainer depending on settings)
**Note:** Container Registry must be enabled for the project.
## Available Commands
### List Container Repositories
```bash
# List all repositories in project
glab api projects/123/registry/repositories --method GET
# With pagination
glab api projects/123/registry/repositories --paginate
# Include tags count
glab api "projects/123/registry/repositories?tags_count=true" --method GET
# Using project path
glab api "projects/$(echo 'mygroup/myproject' | jq -Rr @uri)/registry/repositories"
```
### Get Repository Details
```bash
# Get specific repository
glab api projects/123/registry/repositories/456 --method GET
# With tags count
glab api "projects/123/registry/repositories/456?tags_count=true" --method GET
```
### Delete Repository
**Warning:** This deletes the repository and ALL its tags!
```bash
# Delete entire repository
glab api projects/123/registry/repositories/456 --method DELETE
```
### List Tags in Repository
```bash
# List all tags
glab api projects/123/registry/repositories/456/tags --method GET
# With pagination
glab api projects/123/registry/repositories/456/tags --paginate
```
### Get Tag Details
```bash
# Get specific tag
glab api projects/123/registry/repositories/456/tags/latest --method GET
# Get tag with digest info
glab api projects/123/registry/repositories/456/tags/v1.0.0 --method GET
```
### Delete Single Tag
```bash
# Delete specific tag
glab api projects/123/registry/repositories/456/tags/v1.0.0 --method DELETE
# Delete 'latest' tag
glab api projects/123/registry/repositories/456/tags/latest --method DELETE
```
### Bulk Delete Tags
```bash
# Delete tags matching regex (keep none)
glab api projects/123/registry/repositories/456/tags --method DELETE \
-f name_regex_delete=".*"
# Delete all tags except last 5
glab api projects/123/registry/repositories/456/tags --method DELETE \
-f name_regex_delete=".*" \
-f keep_n=5
# Delete tags older than 30 days, keep last 10
glab api projects/123/registry/repositories/456/tags --method DELETE \
-f name_regex_delete=".*" \
-f keep_n=10 \
-f older_than="30d"
# Delete only dev/snapshot tags
glab api projects/123/registry/repositories/456/tags --method DELETE \
-f name_regex_delete="^dev-.*"
# Keep tags matching pattern (exclude from deletion)
glab api projects/123/registry/repositories/456/tags --method DELETE \
-f name_regex_delete=".*" \
-f name_regex_keep="^v[0-9]+\\.[0-9]+\\.[0-9]+$" \
-f keep_n=5
```
## Bulk Delete Options
| Option | Type | Description |
|--------|------|-------------|
| `name_regex_delete` | string | Regex pattern for tags to delete |
| `name_regex_keep` | string | Regex pattern for tags to keep (overrides delete) |
| `keep_n` | integer | Number of latest tags to keep |
| `older_than` | string | Delete tags older than duration (e.g., `30d`, `1w`) |
## Common Workflows
### Workflow 1: List All Images and Tags
```bash
project_id=123
# Get all repositories
repos=$(glab api projects/$project_id/registry/repositories --paginate)
# For each repository, list tags
echo "$repos" | jq -r '.[].id' | while read repo_id; do
repo_name=$(echo "$repos" | jq -r ".[] | select(.id == $repo_id) | .path")
echo "=== $repo_name ==="
glab api projects/$project_id/registry/repositories/$repo_id/tags | \
jq -r '.[].name'
echo ""
done
```
### Workflow 2: Find Large Images
```bash
project_id=123
repo_id=456
# List tags with sizes
glab api projects/$project_id/registry/repositories/$repo_id/tags --paginate | \
jq -r 'sort_by(.total_size) | reverse | .[] | "\(.name): \(.total_size / 1024 / 1024 | floor) MB"'
```
### Workflow 3: Clean Up Old Development Images
```bash
project_id=123
repo_id=456
# Delete dev images older than 7 days, keep last 3
glab api projects/$project_id/registry/repositories/$repo_id/tags --method DELETE \
-f name_regex_delete="^dev-.*" \
-f older_than="7d" \
-f keep_n=3
```
### Workflow 4: Keep Only Release Tags
```bash
project_id=123
repo_id=456
# Delete everything except semver tags, keep last 10
glab api projects/$project_id/registry/repositories/$repo_id/tags --method DELETE \
-f name_regex_delete=".*" \
-f name_regex_keep="^v[0-9]+\\.[0-9]+\\.[0-9]+$" \
-f keep_n=10
```
### Workflow 5: Audit Registry Usage
```bash
project_id=123
# Get total size per repository
glab api "projects/$project_id/registry/repositories?tags_count=true" --paginate | \
jq -r '.[] | "\(.path): \(.tags_count) tags"'
# Get detailed size info for a repository
repo_id=456
glab api projects/$project_id/registry/repositories/$repo_id/tags --paginate | \
jq '[.[] | .total_size] | add / 1024 / 1024 | "Total: \(. | floor) MB"'
```
### Workflow 6: Find and Delete Untagged Images
```bash
project_id=123
repo_id=456
# Note: Untagged images are automatically cleaned up by GitLab
# You can trigger cleanup by deleting all tags and then the repo
# Or wait for the scheduled cleanup job
```
### Workflow 7: Export Tag List for Backup
```bash
project_id=123
repo_id=456
# Export tag names
glab api projects/$project_id/registry/repositories/$repo_id/tags --paginate | \
jq -r '.[].name' > tags_backup.txt
# Export with details
glab api projects/$project_id/registry/repositories/$repo_id/tags --paginate | \
jq -r '.[] | [.name, .created_at, .total_size] | @csv' > tags_details.csv
```
## Registry URL Format
GitLab Container Registry URLs follow this pattern:
```
registry.gitlab.com/<namespace>/<project>
registry.gitlab.com/<namespace>/<project>/<image>
```
For example:
- `registry.gitlab.com/mygroup/myproject`
- `registry.gitlab.com/mygroup/myproject/app`
- `registry.gitlab.com/mygroup/myproject/api`
## Troubleshooting
| Issue | Cause | Solution |
|-------|-------|----------|
| 403 Forbidden | No registry access | Check token scopes, need `read_registry` |
| 404 Not Found | Registry disabled or repo doesn't exist | Enable registry in project settings |
| Delete fails | Insufficient permissions | Need Developer+ role or `write_registry` scope |
| Bulk delete no effect | No matching tags | Check regex pattern |
| Old images persist | GitLab cleanup job | Wait for scheduled cleanup or delete manually |
## Size Limits and Quotas
- GitLab.com has storage quotas per namespace
- Self-managed instances may have different limits
- Check namespace storage usage in Settings > Usage Quotas
## Best Practices
1. **Regular cleanup**: Set up scheduled cleanup wRelated in Image & Video
watch
IncludedWatch a video (URL or local path). Downloads with yt-dlp, extracts auto-scaled frames with ffmpeg, pulls the transcript from captions (or Whisper API fallback), and hands the result to Claude so it can answer questions about what's in the video.
physical-ai-defect-image-generation
IncludedUse when the user wants to orchestrate defect image generation, run associated setup, or handle outputs on OSMO. The Day 0 path handles cold-start with USD-to-ROI, image-edit augmentation, and AnomalyGen to create initial PCBA datasets. The Day 1 path performs inference and labeling on real images. This skill helps with first-time asset setup, creation of finetuning checkpoints, and configuring deployment. Trigger keywords: defect image generation, dig workflow, dig pipeline, defect image detection workflow, aoi pipeline, aoi anomalygen, usd2roi anomalygen, day 0 pcba, day 1 pcba, day 1 real-photo alignment, day 1 manual roi, metal surface anomaly, glass defect, anomalygen finetune, setup_pcb, setup_metal, setup_glass, setup_pretrained, dig setup, dig datasets, dig pretrained checkpoint, dig image-edit endpoint.
accelint-react-best-practices
IncludedReact performance optimization and best practices. ALWAYS use this skill when working with any React code - writing components, hooks, JSX; refactoring; optimizing re-renders, memoization, state management; reviewing for performance; fixing hydration mismatches; debugging infinite re-renders, stale closures, input focus loss, animations restarting; preventing remounting; implementing transitions, lazy initialization, effect dependencies. Even simple React tasks benefit from these patterns. Covers React 19+ (useEffectEvent, Activity, ref props). Triggers - useEffect, useState, useMemo, useCallback, memo, inline components, nested components, components inside components, re-render, performance, hydration, SSR, Next.js, useDeferredValue, combined hooks.
elevenlabs-agents
IncludedBuild conversational AI voice agents with ElevenLabs Platform using React, JavaScript, React Native, or Swift SDKs. Configure agents, tools (client/server/MCP), RAG knowledge bases, multi-voice, and Scribe real-time STT. Use when: building voice chat interfaces, implementing AI phone agents with Twilio, configuring agent workflows or tools, adding RAG knowledge bases, testing with CLI "agents as code", or troubleshooting deprecated @11labs packages, Android audio cutoff, CSP violations, dynamic variables, or WebRTC config. Keywords: ElevenLabs Agents, ElevenLabs voice agents, AI voice agents, conversational AI, @elevenlabs/react, @elevenlabs/client, @elevenlabs/react-native, @elevenlabs/elevenlabs-js, @elevenlabs/agents-cli, elevenlabs SDK, voice AI, TTS, text-to-speech, ASR, speech recognition, turn-taking model, WebRTC voice, WebSocket voice, ElevenLabs conversation, agent system prompt, agent tools, agent knowledge base, RAG voice agents, multi-voice agents, pronunciation dictionary, voice speed control, elevenlabs scribe, @11labs deprecated, Android audio cutoff, CSP violation elevenlabs, dynamic variables elevenlabs, case-sensitive tool names, webhook authentication
humanizer
IncludedHumanize AI-generated text by detecting and removing patterns typical of LLM output. Rewrites text to sound natural, specific, and human. Uses 28 pattern detectors, 560+ AI vocabulary terms across 3 tiers, and statistical analysis (burstiness, type-token ratio, readability) for comprehensive detection. Use when asked to humanize text, de-AI writing, make content sound more natural/human, review writing for AI patterns, score text for AI detection, or improve AI-generated drafts. Covers content, language, style, communication, and filler categories.
generating-mermaid-diagrams
IncludedSalesforce architecture diagrams using Mermaid with ASCII fallback. Use this skill when generating text-based diagrams for Salesforce architecture, OAuth flows, ERDs, integration sequences, or Agentforce structure. TRIGGER when: user says "diagram", "visualize", "ERD", or asks for sequence diagrams, flowcharts, class diagrams, or architecture visualizations in Mermaid. DO NOT TRIGGER when: user wants PNG/SVG image output (use generating-visual-diagrams), or asks about non-Salesforce systems.