ln-730-devops-setup

Sets up Docker, CI/CD, and environment configuration with auto-detection. Use when adding DevOps infrastructure to a project.

310 stars

Best use case

ln-730-devops-setup is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Sets up Docker, CI/CD, and environment configuration with auto-detection. Use when adding DevOps infrastructure to a project.

Teams using ln-730-devops-setup should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/ln-730-devops-setup/SKILL.md --create-dirs "https://raw.githubusercontent.com/levnikolaevich/claude-code-skills/main/skills-catalog/ln-730-devops-setup/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/ln-730-devops-setup/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How ln-730-devops-setup Compares

Feature / Agentln-730-devops-setupStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Sets up Docker, CI/CD, and environment configuration with auto-detection. Use when adding DevOps infrastructure to a project.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

Related Guides

SKILL.md Source

> **Paths:** File paths (`shared/`, `references/`, `../ln-*`) are relative to skills repo root. If not found at CWD, locate this SKILL.md directory and go up one level for repo root. If `shared/` is missing, fetch files via WebFetch from `https://raw.githubusercontent.com/levnikolaevich/claude-code-skills/master/skills/{path}`.

# ln-730-devops-setup

**Type:** L2 Domain Coordinator
**Category:** 7XX Project Bootstrap
**Parent:** ln-700-project-bootstrap

Coordinates DevOps infrastructure setup by delegating to specialized workers.

---

## Purpose & Scope

Orchestrates the complete DevOps setup for a project:
- **Does**: Auto-detect stack, delegate to workers, verify configuration
- **Does NOT**: Generate files directly (delegates to ln-731, ln-732, ln-733)

---

## Overview

| Aspect | Details |
|--------|---------|
| **Input** | Project directory with source code |
| **Output** | Docker, CI/CD, environment configuration |
| **Workers** | ln-731 (Docker), ln-732 (CI/CD), ln-733 (Environment) |
| **Mode** | Auto-detect (no user prompts) |

---

## Supported Stacks

| Component | Option 1 | Option 2 |
|-----------|----------|----------|
| **Frontend** | React/Vite + Nginx | - |
| **Backend** | .NET 8/9 | Python (FastAPI/Django) |
| **Database** | PostgreSQL | - |
| **CI/CD** | GitHub Actions | - |

---

## Workflow

### Phase 1: Pre-flight Validation

Check required tools and project structure:
- Verify Docker is installed (`docker --version`)
- Verify docker-compose is available
- Check for existing DevOps files (warn if overwriting)

**Output**: Validation report or STOP with instructions

### Phase 2: Project Analysis (Auto-detect)

Detect project stack automatically:

| Detection | Method | Files to Check |
|-----------|--------|----------------|
| **Frontend** | Package.json presence | `src/frontend/package.json`, `package.json` |
| **Backend .NET** | .csproj/.sln presence | `*.sln`, `src/**/*.csproj` |
| **Backend Python** | requirements.txt/pyproject.toml | `requirements.txt`, `pyproject.toml` |
| **Database** | Connection strings in code | `appsettings.json`, `.env.example` |
| **Existing CI/CD** | Workflow files | `.github/workflows/`, `azure-pipelines.yml` |

**Version Detection**:
- Node.js: Read from `package.json` engines or use `node -v`
- .NET: Read from `*.csproj` TargetFramework
- Python: Read from `pyproject.toml` or `runtime.txt`
- PostgreSQL: Default to latest stable (17)

**Output**: Stack configuration object with detected versions

### Phase 3: Worker Delegation

Delegate to workers in parallel (independent tasks):

```
ln-730 (Coordinator)
    |
    +---> ln-731-docker-generator (via Skill tool)
    |         Input: stack config, versions
    |         Output: Dockerfile.*, docker-compose.yml, .dockerignore
    |
    +---> ln-732-cicd-generator (via Skill tool)
    |         Input: stack config, detected commands
    |         Output: .github/workflows/ci.yml
    |
    +---> ln-733-env-configurator (via Skill tool)
              Input: detected environment variables
              Output: .env.example, .env.development, .gitignore updates
```

**Error Handling**:
- If worker fails, log error and continue with others
- Report all failures at the end
- Suggest manual fixes for failed components


**Invocations:**
```
Skill(skill: "ln-731-docker-generator", args: "{projectPath}")
Skill(skill: "ln-732-cicd-generator", args: "{projectPath}")
Skill(skill: "ln-733-env-configurator", args: "{projectPath}")
```

### Phase 4: Configuration Verification

Verify generated configuration:
- Run `docker-compose config` to validate syntax
- Check all referenced files exist
- Verify no secrets in committed files

**Output**: Verification report

### Phase 5: Completion Report

Generate summary:
- List all created files
- Show detected stack configuration
- Provide next steps for user

---

## Generated Files

### Docker (ln-731)
- `Dockerfile.frontend` - Multi-stage build for frontend
- `Dockerfile.backend` - Multi-stage build for backend
- `docker-compose.yml` - Service orchestration
- `docker-compose.override.yml` - Development overrides (optional)
- `.dockerignore` - Build context exclusions

### CI/CD (ln-732)
- `.github/workflows/ci.yml` - Main CI pipeline

### Environment (ln-733)
- `.env.example` - Template with all variables
- `.env.development` - Development defaults
- `.env.production` - Production template (placeholders)
- `.gitignore` updates - Secrets protection

---

## Critical Notes

1. **Auto-detect Only**: No interactive prompts. Uses detected values or sensible defaults.
2. **Idempotent**: Check file existence before creation. Warn before overwriting.
3. **Parallel Execution**: Workers are independent, can run in parallel.
4. **Error Recovery**: Continue on partial failures, report all issues at end.
5. **Version Pinning**: Use detected versions, not hardcoded values.

---

**TodoWrite format (mandatory):**
```
- Invoke ln-731-docker-generator (pending)
- Invoke ln-732-cicd-generator (pending)
- Invoke ln-733-env-configurator (pending)
- Verify configuration (pending)
- Generate completion report (pending)
```

## Worker Invocation (MANDATORY)

| Phase | Worker | Context |
|-------|--------|---------|
| 3a | ln-731-docker-generator | Shared (Skill tool) — Dockerfiles, docker-compose, .dockerignore |
| 3b | ln-732-cicd-generator | Shared (Skill tool) — CI/CD pipeline configuration |
| 3c | ln-733-env-configurator | Shared (Skill tool) — environment files and .gitignore |

**All workers:** Invoke via Skill tool — workers see coordinator context.

## Definition of Done

- [ ] Pre-flight validation passed
- [ ] Stack auto-detected successfully
- [ ] All workers completed (or failures documented)
- [ ] `docker-compose config` validates successfully
- [ ] No secrets in generated files
- [ ] Completion report displayed

---

## Reference Files

- Worker: `../ln-731-docker-generator/SKILL.md`
- Worker: `../ln-732-cicd-generator/SKILL.md`
- Worker: `../ln-733-env-configurator/SKILL.md`

---

## Meta-Analysis

**MANDATORY READ:** Load `shared/references/meta_analysis_protocol.md`

Skill type: `execution-orchestrator`. Run after all phases complete. Output to chat using the `execution-orchestrator` format.

---

**Version:** 1.1.0
**Last Updated:** 2026-01-10

Related Skills

ln-774-healthcheck-setup

310
from levnikolaevich/claude-code-skills

Configures health check endpoints for Kubernetes readiness/liveness/startup probes. Use when deploying to Kubernetes.

ln-772-error-handler-setup

310
from levnikolaevich/claude-code-skills

Configures global exception handling middleware. Use when adding centralized error handling to .NET or Python backends.

ln-770-crosscutting-setup

310
from levnikolaevich/claude-code-skills

Sets up logging, error handling, CORS, health checks, and API docs. Use when adding cross-cutting concerns to backend projects.

ln-760-security-setup

310
from levnikolaevich/claude-code-skills

Sets up security scanning for secrets and dependency vulnerabilities. Use when adding security infrastructure to a project.

ln-742-precommit-setup

310
from levnikolaevich/claude-code-skills

Configures Husky, lint-staged, commitlint, and Python pre-commit hooks. Use when adding Git hook automation to a project.

ln-740-quality-setup

310
from levnikolaevich/claude-code-skills

Sets up linters, pre-commit hooks, and test infrastructure. Use when adding code quality tooling to a project.

ln-115-devops-docs-creator

310
from levnikolaevich/claude-code-skills

Creates infrastructure.md and runbook.md (Docker-conditional). Use for DevOps documentation in any project.

ln-010-dev-environment-setup

310
from levnikolaevich/claude-code-skills

Installs agents, configures MCP servers, syncs configs, creates and audits instructions. Use after setup or when agents/MCP need alignment.

ln-914-community-responder

310
from levnikolaevich/claude-code-skills

Responds to unanswered GitHub discussions and issues with codebase-informed replies. Use when clearing community question backlog.

ln-913-community-debater

310
from levnikolaevich/claude-code-skills

Launches RFC and debate discussions on GitHub. Use when proposing changes that need community input or voting.

ln-912-community-announcer

310
from levnikolaevich/claude-code-skills

Composes and publishes announcements to GitHub Discussions. Use when sharing releases, updates, or news with the community.

ln-911-github-triager

310
from levnikolaevich/claude-code-skills

Produces prioritized triage report from open GitHub issues, PRs, and discussions. Use when reviewing community backlog.