ffmpeg-cicd-runners
Complete CI/CD video processing system. PROACTIVELY activate for: (1) GitHub Actions FFmpeg setup, (2) GitLab CI video pipelines, (3) Jenkins declarative pipelines, (4) FFmpeg caching strategies, (5) Windows runner workarounds, (6) GPU-enabled self-hosted runners, (7) Matrix builds for multi-format, (8) Artifact upload/download, (9) Video validation workflows, (10) BtbN/FFmpeg-Builds integration. Provides: YAML workflow examples, Docker container patterns, caching configuration, platform-specific solutions, debugging guides. Ensures: Fast, reliable video processing in CI/CD pipelines.
What this skill does
## CRITICAL GUIDELINES
### Windows File Path Requirements
**MANDATORY: Always Use Backslashes on Windows for File Paths**
When using Edit or Write tools on Windows, you MUST use backslashes (`\`) in file paths, NOT forward slashes (`/`).
---
## Quick Reference
| Platform | Install Method | Example |
|----------|---------------|---------|
| GitHub Actions | `apt-get` or action | `uses: FedericoCarboni/setup-ffmpeg@v3` |
| GitLab CI | Docker image | `image: jrottenberg/ffmpeg:7.1-ubuntu2404` |
| Jenkins | Docker container | `docker { image 'jrottenberg/ffmpeg:7.1' }` |
| Task | YAML Snippet |
|------|--------------|
| Cache FFmpeg | `uses: actions/cache@v4` with `path: /usr/local/bin/ffmpeg` |
| Upload artifact | `uses: actions/upload-artifact@v4` |
| Matrix build | `strategy: { matrix: { format: [mp4, webm, mkv] } }` |
## When to Use This Skill
Use for **CI/CD video processing pipelines**:
- GitHub Actions FFmpeg workflows
- GitLab CI/CD video transcoding
- Jenkins video processing jobs
- Caching FFmpeg for faster builds
- Windows runner workarounds
---
# FFmpeg in CI/CD Pipelines (2025)
Comprehensive guide to using FFmpeg in GitHub Actions, GitLab CI, Jenkins, and other CI/CD systems.
## Overview
### Common CI/CD Use Cases
- **Video validation**: Check uploaded videos meet requirements
- **Transcoding**: Convert videos to multiple formats/resolutions
- **Thumbnail generation**: Create preview images
- **Audio extraction**: Process audio tracks
- **Quality checks**: Validate encoding parameters
- **Testing**: Test video processing pipelines
### Key Considerations
- **Build time**: FFmpeg compilation takes 20-40+ minutes
- **Runner resources**: CPU/memory limits affect processing
- **Caching**: Cache FFmpeg builds for faster runs
- **Platform differences**: Windows runners have unique issues
- **Dependencies**: Codec libraries may need installation
## GitHub Actions
### Install FFmpeg (Quick)
```yaml
name: Video Processing
on: [push, pull_request]
jobs:
process:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install FFmpeg
run: |
sudo apt-get update
sudo apt-get install -y ffmpeg
- name: Check FFmpeg version
run: ffmpeg -version
- name: Process video
run: |
ffmpeg -i input.mp4 -c:v libx264 -crf 23 output.mp4
```
### Install Specific FFmpeg Version
```yaml
jobs:
process:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install FFmpeg 7.1
run: |
wget https://github.com/BtbN/FFmpeg-Builds/releases/download/latest/ffmpeg-n7.1-latest-linux64-gpl-7.1.tar.xz
tar xf ffmpeg-n7.1-latest-linux64-gpl-7.1.tar.xz
sudo cp ffmpeg-n7.1-latest-linux64-gpl-7.1/bin/* /usr/local/bin/
ffmpeg -version
```
### Use FedericoCarboni/setup-ffmpeg Action
```yaml
jobs:
process:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup FFmpeg
uses: FedericoCarboni/setup-ffmpeg@v3
with:
ffmpeg-version: release
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: Process video
run: ffmpeg -i input.mp4 output.webm
```
### Docker-Based FFmpeg
```yaml
jobs:
process:
runs-on: ubuntu-latest
container:
image: jrottenberg/ffmpeg:7.1-ubuntu2404
steps:
- uses: actions/checkout@v4
- name: Process video
run: |
ffmpeg -i input.mp4 -c:v libx264 -crf 23 output.mp4
```
### Caching FFmpeg Build
```yaml
jobs:
build-ffmpeg:
runs-on: ubuntu-latest
steps:
- name: Cache FFmpeg
id: cache-ffmpeg
uses: actions/cache@v4
with:
path: /usr/local/bin/ffmpeg
key: ffmpeg-7.1-linux-${{ runner.arch }}
- name: Build FFmpeg (if not cached)
if: steps.cache-ffmpeg.outputs.cache-hit != 'true'
run: |
wget https://github.com/BtbN/FFmpeg-Builds/releases/download/latest/ffmpeg-n7.1-latest-linux64-gpl-7.1.tar.xz
tar xf ffmpeg-n7.1-latest-linux64-gpl-7.1.tar.xz
sudo cp ffmpeg-n7.1-latest-linux64-gpl-7.1/bin/ffmpeg /usr/local/bin/
```
### Matrix Build (Multiple Platforms)
```yaml
jobs:
process:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- name: Setup FFmpeg
uses: FedericoCarboni/setup-ffmpeg@v3
- name: Process video
run: ffmpeg -i input.mp4 -c:v libx264 output_${{ matrix.os }}.mp4
shell: bash
```
### Windows Runner (Known Issues)
**Issue**: Windows runners take significantly longer (up to 4 hours for vcpkg FFmpeg builds)
**Solutions**:
```yaml
jobs:
windows-ffmpeg:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
# Option 1: Use pre-built binaries (recommended)
- name: Download FFmpeg
run: |
Invoke-WebRequest -Uri "https://github.com/BtbN/FFmpeg-Builds/releases/download/latest/ffmpeg-n7.1-latest-win64-gpl-7.1.zip" -OutFile ffmpeg.zip
Expand-Archive ffmpeg.zip -DestinationPath .
$env:PATH = "$PWD\ffmpeg-n7.1-latest-win64-gpl-7.1\bin;$env:PATH"
ffmpeg -version
# Option 2: Use setup-ffmpeg action
- name: Setup FFmpeg
uses: FedericoCarboni/setup-ffmpeg@v3
- name: Process video
run: ffmpeg -i input.mp4 output.mp4
```
### GPU-Enabled Runners
```yaml
jobs:
gpu-process:
runs-on: [self-hosted, gpu, linux]
steps:
- uses: actions/checkout@v4
- name: Process with NVIDIA GPU
run: |
ffmpeg -hwaccel cuda -hwaccel_output_format cuda \
-i input.mp4 \
-c:v h264_nvenc \
-preset p4 \
output.mp4
```
### Artifact Upload
```yaml
jobs:
process:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install FFmpeg
run: sudo apt-get update && sudo apt-get install -y ffmpeg
- name: Generate outputs
run: |
mkdir -p outputs
ffmpeg -i input.mp4 -vf scale=1920:1080 outputs/1080p.mp4
ffmpeg -i input.mp4 -vf scale=1280:720 outputs/720p.mp4
ffmpeg -i input.mp4 -ss 00:00:05 -vframes 1 outputs/thumbnail.jpg
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: video-outputs
path: outputs/
retention-days: 7
```
### Video Validation Workflow
```yaml
name: Validate Videos
on:
pull_request:
paths:
- '**.mp4'
- '**.webm'
- '**.mov'
jobs:
validate:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install FFmpeg
run: sudo apt-get update && sudo apt-get install -y ffmpeg
- name: Validate videos
run: |
for video in $(find . -name "*.mp4" -o -name "*.webm" -o -name "*.mov"); do
echo "Validating: $video"
# Check if valid
if ! ffprobe -v error "$video"; then
echo "Invalid video: $video"
exit 1
fi
# Get info
duration=$(ffprobe -v error -show_entries format=duration -of default=noprint_wrappers=1:nokey=1 "$video")
resolution=$(ffprobe -v error -select_streams v:0 -show_entries stream=width,height -of csv=p=0 "$video")
echo "Duration: ${duration}s"
echo "Resolution: $resolution"
# Validate constraints
if (( $(echo "$duration > 300" | bc -l) )); then
echo "Video too long: $video ($duration seRelated 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.