Tooluck logoTooluck
SKILL.md

docker-management

Agent skill fromBagelHole/DevOps-Security-Agent-Skills

Build, optimize, and troubleshoot Docker containers and images. Create efficient Dockerfiles, manage container lifecycle, configure networking and volumes, and debug container issues. Use when working with Docker, containerization, or container troubleshooting.

How to install docker-management

install docker-management
# install the DevOps-Security-Agent-Skills pack with the skills CLI
npx skills add BagelHole/DevOps-Security-Agent-Skills

# or add only this skill to Claude Code: copy the folder

devops/containers/docker-management/

# into

~/.claude/skills/docker-management/ (all projects)

.claude/skills/docker-management/ (one project)

devops/containers/docker-management/SKILL.md

MITFull file
1# Docker Management
2
3Build, run, and manage Docker containers for application deployment and development.
4
5## When to Use This Skill
6
7Use this skill when:
8- Creating and optimizing Dockerfiles
9- Building and tagging Docker images
10- Running and managing containers
11- Debugging container issues
12- Configuring Docker networking and volumes
13- Implementing container security best practices
14
15## Prerequisites
16
17- Docker Engine installed (20.10+)
18- Basic command line knowledge
19- Understanding of application deployment
20
21## Dockerfile Best Practices
22
23### Multi-Stage Build
24
25```dockerfile
26# Build stage
27FROM node:20-alpine AS builder
28WORKDIR /app
29COPY package*.json ./
30RUN npm ci --only=production
31COPY . .
32RUN npm run build
33
34# Production stage
35FROM node:20-alpine AS production
36WORKDIR /app
37RUN addgroup -g 1001 -S nodejs && \
38 adduser -S nodejs -u 1001
39COPY --from=builder --chown=nodejs:nodejs /app/dist ./dist
40COPY --from=builder --chown=nodejs:nodejs /app/node_modules ./node_modules
41USER nodejs
42EXPOSE 3000
43CMD ["node", "dist/index.js"]
44```
45
46### Layer Optimization
47
48```dockerfile
49FROM python:3.12-slim
50
51# Install dependencies first (cached unless requirements change)
52COPY requirements.txt .
53RUN pip install --no-cache-dir -r requirements.txt
54
55# Copy application code (changes frequently)
56COPY . .
57
58CMD ["python", "app.py"]
59```
60
61### Security Hardening
62
63```dockerfile
64FROM node:20-alpine
65
66# Create non-root user
67RUN addgroup -g 1001 appgroup && \
68 adduser -u 1001 -G appgroup -D appuser
69…

Excerpt shown under the repository's MIT license.

More skills in DevOps-Security-Agent-Skills

Keep exploring

Similar skill repositories

thedotmack /

claude-mem
116k

Persistent Context Across Sessions for Every Agent – Captures everything your agent does during sessions, compresses it with AI, and injects relevant context back into future sessions. Works with Claude Code, OpenClaw, Codex, Gemini, Hermes, Copilot, OpenCode + More

CCCXGHGM+135 skills

Newsletter

Join the Community

Subscribe to our newsletter for the latest news and updates