home / skills / ehtbanton / claudeskillsrepo / gitlab-ci-config-generator

gitlab-ci-config-generator skill

/gitlab-ci-config-generator

This skill generates a complete GitLab CI/CD pipeline configuration (.gitlab-ci.yml) with build, test, and deploy jobs.

npx playbooks add skill ehtbanton/claudeskillsrepo --skill gitlab-ci-config-generator

Review the files below or copy the command above to add this skill to your agents.

Files (2)
SKILL.md
690 B
---
name: gitlab-ci-config-generator
description: Generate GitLab CI/CD pipeline configuration files with stages, jobs, and deployment. Triggers on "create gitlab ci", "generate gitlab-ci.yml", "gitlab pipeline", "gitlab ci config".
---

# GitLab CI Config Generator

Generate GitLab CI/CD pipeline configuration files.

## Output Requirements

**File Output:** `.gitlab-ci.yml`
**Format:** Valid GitLab CI YAML
**Standards:** GitLab CI latest

## When Invoked

Immediately generate a complete GitLab CI pipeline configuration.

## Example Invocations

**Prompt:** "Create GitLab CI for Node.js with Docker deploy"
**Output:** Complete `.gitlab-ci.yml` with test, build, and deploy stages.

Overview

This skill generates complete .gitlab-ci.yml files for GitLab CI/CD pipelines, tailored to project language, build tools, and deployment targets. It creates validated YAML with stages, jobs, artifacts, and common options so pipelines follow current GitLab CI standards. The generator supports Docker, Kubernetes, server SSH deploys, and language-specific tasks like Node.js, Python, and Java.

How this skill works

On trigger phrases such as "create gitlab ci" or "generate gitlab-ci.yml", the skill asks or infers project details (runtime, test command, build steps, registry, deployment target) and outputs a ready-to-use .gitlab-ci.yml. It produces stage ordering, job definitions, image and services blocks, cache and artifact rules, and sample variables for CI/CD secrets. The YAML adheres to GitLab CI latest features and includes comments and minimal customization points.

When to use it

  • Bootstrapping CI/CD for a new repository quickly
  • Converting ad-hoc build scripts into a structured pipeline
  • Creating pipelines that build, test, and push Docker images
  • Deploying to Kubernetes, Docker registries, or SSH hosts
  • Generating a baseline pipeline to iterate and harden later

Best practices

  • Provide concrete commands for test, build, and deploy to avoid ambiguous defaults
  • Use CI/CD variables for secrets and registry credentials, not hard-coded values
  • Keep jobs small and focused; use artifacts and cache to speed pipelines
  • Pin Docker images or use immutable tags for reproducible runs
  • Start with a minimal pipeline and add conditional rules and environments as needed

Example use cases

  • Generate a Node.js pipeline with install, test, build, Docker image build, and push to GitLab Container Registry
  • Create a Python pipeline that runs unit tests, package wheel, and deploys to PyPI or an artifact repository
  • Produce a Java/Maven pipeline that runs mvn test, builds JAR, and deploys to a staging Kubernetes cluster
  • Build a CI that runs linting and security scans in parallel before merge
  • Generate a pipeline for multi-service monorepo with separate build jobs per service

FAQ

Can the generator add deployment to Kubernetes?

Yes — specify the cluster context, image registry, and helm/kubectl commands, and the generator will include a deploy stage with sample manifests or helm steps.

Does it handle secrets and registry credentials?

The output uses CI/CD variables placeholders and recommends storing secrets in GitLab CI variables or a secret manager rather than embedding them in the YAML.