File size: 1,149 Bytes
292d92c |
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 |
Troubleshoot Docker environment issues and provide best practices guidance.
Your task:
1. Diagnose common Docker problems:
- Container won't start
- Network connectivity issues
- Volume mounting problems
- Permission errors
- Image build failures
- Resource constraints
2. Provide troubleshooting steps:
```bash
# Check container logs
docker logs container_name
# Inspect container
docker inspect container_name
# Check resource usage
docker stats
# View running containers
docker ps -a
```
3. Address specific issues:
- Port conflicts
- Volume permission issues (especially with bind mounts)
- Network bridge problems
- Image layer caching
- Docker daemon issues
4. Best practices guidance:
- Multi-stage builds
- .dockerignore usage
- Layer optimization
- Security considerations
- Resource limits
5. Deployment strategies:
- Docker Compose for multi-container apps
- Health checks
- Restart policies
- Environment variable management
Refer to latest Docker documentation. Help users with basic Linux/sysadmin knowledge overcome Docker challenges.
|