security-docker

Audit Dockerfiles and Docker Compose configurations for security vulnerabilities.

Updated Feb 9, 2025
One-click install
npx skills add https://github.com/xeon826/dotfiles --skill security-docker-xeon826
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: security-docker
Source: https://github.com/xeon826/dotfiles/tree/main/opencode/skill/security-docker
Command: npx skills add https://github.com/xeon826/dotfiles --skill security-docker-xeon826

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires rg, and includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill helps identify and mitigate common security vulnerabilities in Dockerfiles and Docker Compose configurations, protecting your containerized applications from misconfigurations and potential breaches.

Core Features & Use Cases

  • Dockerfile Auditing: Detects secrets in ENV/ARG, insecure COPY commands, and lack of non-root users.
  • Docker Compose Review: Flags exposed sensitive ports, privileged container settings, and dangerous volume mounts.
  • Use Case: Before deploying a new microservice, run this Skill to automatically scan its Dockerfile and docker-compose.yml for critical security flaws like exposed database ports or hardcoded API keys.

Quick Start

Run the security-docker skill to audit the Dockerfile and docker-compose.yml in the current directory.

Frequently Asked Questions about security-docker

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I audit a Dockerfile for security vulnerabilities like exposed secrets?

Docker Compose security auditing flags exposed sensitive ports, privileged container settings, and dangerous volume mounts. Scanning docker-compose.yml identifies misconfigurations like exposed database ports that could lead to potential breaches before deploying microservices.

What security risks should I check before deploying a Docker container?

Before deploying a Docker container, check for exposed secrets in ENV/ARG, insecure COPY commands, lack of non-root user execution, privileged container settings, and dangerous volume mounts. Scanning Dockerfiles and docker-compose.yml identifies these critical security flaws.

Can I detect privileged container settings and dangerous volume mounts in docker-compose.yml?

Yes, you can detect privileged container settings and dangerous volume mounts in docker-compose.yml. Docker Compose review flags these security risks along with exposed sensitive ports to protect your containerized applications from misconfigurations and potential breaches.

Does Dockerfile security auditing check for non-root user execution?

Yes, Dockerfile security auditing checks for non-root user execution. It detects the lack of non-root users along with secrets in ENV/ARG and insecure COPY commands to help mitigate common security vulnerabilities in your containerized applications.