Frameworks
Play Framework .dockerignore
.dockerignore for frameworks projects
.dockerignore Content
# ============================================================================
# Created by https://dockerignore.com/
# COMPREHENSIVE FRAMEWORK TEMPLATE for Play Framework
# Website: https://www.playframework.com/
# Repository: https://github.com/playframework/playframework
# ============================================================================
# ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
# TEMPLATE OVERVIEW & USAGE NOTES
# ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
# • TEMPLATE TYPE: COMPREHENSIVE FRAMEWORK TEMPLATE
# • PURPOSE: Play Framework specific ignore patterns
# • DESIGN PHILOSOPHY: Self-contained with all necessary patterns including security
# • COMBINATION GUIDANCE: Use standalone - no need to combine with other templates
# • SECURITY CONSIDERATIONS: Includes security patterns for .env files and credentials
# • BEST PRACTICES: Review before use, test with your specific Play Framework setup
# • OFFICIAL SOURCES: Play Framework community patterns and best practices
# ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
# • PURPOSE: Docker ignore patterns for Play Framework (Scala/Java) projects
# • DESIGN PHILOSOPHY: Self-contained with all necessary patterns including security,
# dependencies, and framework-specific artifacts
# • COMBINATION GUIDANCE: Combine with scala.dockerignore or java.dockerignore for complete coverage
# • SECURITY CONSIDERATIONS: Security patterns placed first for maximum protection
# • BEST PRACTICES: Play Framework has specific build directories - ensure target/, project/target are excluded
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# SECURITY & SENSITIVE DATA PROTECTION (ALWAYS FIRST!)
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# CRITICAL: Prevent sensitive data from being included in Docker images
# ENVIRONMENT VARIABLES & CONFIGURATION FILES
.env
.env.*
.env.*.local
.env.development
.env.development.local
.env.example
.env.local
.env.production
.env.production.local
.env.sample
.env.staging
.env.staging.local
.env.template
.env.test
.env.test.local
# APPLICATION SECRETS & CREDENTIALS
**/config/credentials.*
**/config/secrets.*
**/keys/
**/passwords/
**/private/
**/secrets/
*.auth
*.authz
*.password
*.secret
*.secrets
*.token
*_tokens
*password*
apikeys.*
appsettings.Development.json
appsettings.Local.json
appsettings.Staging.json
connectionstrings.config
credentials
credentials.*
credentials.json
credentials.yaml
credentials.yml
id_rsa
id_rsa.pub
jwt-secret
jwt-secret.*
oauth-credentials.*
passwd
private-key.pem
private.pem
secret
secret.*
secrets.json
secrets.yaml
secrets.yml
session-secret
ssh-key
ssh-key.pem
ssl-cert.*
ssl-key.*
# SECURITY CERTIFICATES & KEYS
*.cer
*.crt
*.csr
*.der
*.key
*.p12
*.p7b
*.p7c
*.pem
*.pfx
*.spc
*.sst
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# PLAY FRAMEWORK-SPECIFIC PATTERNS
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# Play Framework build directories (SBT/Maven)
**/dist/
**/logs/
**/project/project/
**/project/target/
**/target/
# Play-specific directories
**/conf/evolutions/
**/test-reports/
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# DEPENDENCY MANAGEMENT & BUILD TOOLS
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# SBT (Scala Build Tool) artifacts
**/.sbt/
**/project/**/*.class
**/project/**/*.jar
**/project/**/target/
project/project/
project/target/
# Maven artifacts
**/.m2/
**/.mvn/
**/mvnw
**/mvnw.cmd
**/pom.xml.*
**/pom.xml.versionsBackup
# Ivy cache
**/.ivy/
**/.ivy2/
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# SCALA/JAVA BUILD ARTIFACTS
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# Compiled classes and jars
**/*.class
**/*.jar
# Build reports
**/dependency-reduced-pom.xml
**/dependency-updates-report.html
**/license-reports/
**/out/
**/reports/
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# DEVELOPMENT & RUNTIME ARTIFACTS
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# Log files
*.log
# Runtime directories
**/run/
**/var/run/
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# CACHE AND TEMPORARY FILES
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# General cache directories
**/.cache/
**/.eslintcache
**/.next/cache/
**/.parcel-cache/
**/.swc/
**/.turbo/
**/.vite/
**/cache/
# Build tool caches
**/.esbuild/
**/.nx/
# Temporary files
**/temp/
**/tmp/
*.temp
*.tmp
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# TESTING AND QUALITY ASSURANCE
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# Test output and reports
**/.nyc_output/
**/.test-output/
**/nyc_output/
**/test-output/
.audit.out
.benchmark.out
.performance.out
.profile.out
.profiling.out
.scan.out
.security.out
# Test coverage
**/coverage/
**/lcov.info
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# EDITOR AND IDE CONFIGURATION
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# IDE-specific files
**/*.swo
**/*.swp
**/.idea/
**/.vscode/
*~
.DS_Store
.ropeproject
__pycache__
# Editor configuration
.editorconfig
.project
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# VERSION CONTROL AND COLLABORATION
# ••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
# Git and version control
.git
.gitattributes
.gitignore
.gitmodules
.gitreview
# Collaboration tools
.hg
.svn
CVS
# ============================================================================
# TEMPLATE VALIDATION & BEST PRACTICES
# ============================================================================
# 1. Validate with: docker build --no-cache .
# 2. Check context size reduction: docker build --no-cache . 2>&1 | grep "context"
# 3. Test pattern effectiveness with Play Framework project
# 4. Combine with scala.dockerignore or java.dockerignore for language-specific patterns
# 5. Play-specific: Ensure target/ and project/target directories are excluded
# 6. Review security patterns regularly for compliance