Docker Compose Validator

DevOps & Containerization• Online docker-compose.yml Syntax & Spec Inspector

Validate, Lint & Troubleshoot Docker Compose Files

Validate docker-compose.yml files against the official Compose Spec. Detect syntax errors, host port overlaps, undeclared named volumes, broken networks, and container security vulnerabilities completely client-side.

Valid Compose Spec
0 warnings, 1 security alert
Presets:
4
Services
2
Host Ports
5
Volumes
2
Networks
0
Errors
1
Security
docker-compose.yml(81 lines)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
Press Tab to indent 2 spaces.

Plaintext Secret in Environment: 'POSTGRES_PASSWORD_FILE'service: db

Service 'db' contains hardcoded credentials in environment variable 'POSTGRES_PASSWORD_FILE'.

security
Recommendation:Reference environment variables from .env file (e.g., 'POSTGRES_PASSWORD_FILE: ${POSTGRES_PASSWORD_FILE}') or use Docker Compose secrets.

Frequently Asked Questions & Compose Spec Best Practices

Why Docker Compose validation matters, how to diagnose port overlaps, and why the client-side architecture keeps your deployment infrastructure secure.

Why is the top-level 'version' attribute deprecated in modern Compose?

Historically, Docker Compose used versions 1, 2, and 3 with differing feature flags. In 2020, Docker donated the specification to the open-source Compose Specification project. Docker Compose v2 merges all capabilities into a unified spec, making the top-level version field obsolete and informational.

How does port collision detection work?

When two or more services publish to the same host port (e.g. "8080:3000" and "8080:80") on the same interface or wildcard 0.0.0.0, Docker cannot bind both sockets. Our validator scans all port definitions, extracts host binding IPs and protocol types, and flags conflicts before deployment.

What is the difference between Named Volumes and Bind Mounts?

Named volumes (e.g., db_data:/var/lib/mysql) are managed directly by Docker inside host storage areas, survive container restarts, and must be declared in top-level volumes:. Bind mounts (e.g., ./nginx.conf:/etc/nginx/nginx.conf) map directly to an arbitrary file or directory on your host machine.

Are my Docker Compose files and infrastructure secrets kept private?

Yes, 100%. In accordance with ToolsAA privacy policies, all YAML parsing, AST evaluation, port matching, and security auditing occur entirely inside your local browser runtime. Zero bytes are uploaded to external APIs or remote logging servers.