Skip to content

~95% on SimpleQA (e.g. Qwen3.6-27B on a 3090). Supports all local and cloud LLMs (llama.cpp, Ollama, Google, ...). 10+ search engines - arXiv, PubMed, your private documents. Everything Local & Encrypted.

feat: add Hadolint Dockerfile linting workflow

LearningCircuit5df5105ef219
diff --git a/.github/workflows/hadolint.yml b/.github/workflows/hadolint.yml
new file mode 100644
index 0000000000..18ff573b1d
--- /dev/null
+++ b/.github/workflows/hadolint.yml
@@ -0,0 +1,99 @@
+name: Hadolint Dockerfile Linting
+
+on:
+ push:
+ branches: [ main, dev ]
+ paths:
+ - '**/Dockerfile*'
+ - '.github/workflows/hadolint.yml'
+ pull_request:
+ branches: [ main, dev ]
+ paths:
+ - '**/Dockerfile*'
+ - '.github/workflows/hadolint.yml'
+ workflow_dispatch:
+ schedule:
+ # Run weekly on Tuesday at 9 AM UTC
+ - cron: '0 9 * * 2'
+
+jobs:
+ hadolint:
+ name: Hadolint Dockerfile Analysis
+ runs-on: ubuntu-latest
+ permissions:
+ contents: read
+ security-events: write
+ pull-requests: write
+
+ steps:
+ - name: Checkout repository
+ uses: actions/checkout@v5
+
+ - name: Run Hadolint on Dockerfile
+ uses: hadolint/[email protected]
+ with:
+ dockerfile: Dockerfile
+ format: sarif
+ output-file: hadolint.sarif
+ no-fail: true
+ verbose: true
+
+ - name: Upload Hadolint results to GitHub Security
+ uses: github/codeql-action/upload-sarif@v4
+ if: always()
+ with:
+ sarif_file: hadolint.sarif
+ category: hadolint
+
+ - name: Upload Hadolint results as artifact
+ uses: actions/upload-artifact@v4
+ if: always()
+ with:
+ name: hadolint-results
+ path: hadolint.sarif
+ retention-days: 30
+
+ - name: Run Hadolint with detailed output
+ uses: hadolint/[email protected]
+ if: always()
+ with:
+ dockerfile: Dockerfile
+ format: tty
+ no-fail: true
+ continue-on-error: true
+
+ - name: Display Hadolint summary
+ if: always()
+ run: |
+ echo "## Hadolint Dockerfile Analysis Summary" >> $GITHUB_STEP_SUMMARY
+ echo "" >> $GITHUB_STEP_SUMMARY
+ echo "✅ Hadolint analysis completed" >> $GITHUB_STEP_SUMMARY
+ echo "" >> $GITHUB_STEP_SUMMARY
+ echo "### What is Hadolint?" >> $GITHUB_STEP_SUMMARY
+ echo "Hadolint is a Dockerfile linter that checks for best practices and common mistakes:" >> $GITHUB_STEP_SUMMARY
+ echo "" >> $GITHUB_STEP_SUMMARY
+ echo "#### Security Checks" >> $GITHUB_STEP_SUMMARY
+ echo "- 🔒 Running as root user" >> $GITHUB_STEP_SUMMARY
+ echo "- 🔑 Using latest tag" >> $GITHUB_STEP_SUMMARY
+ echo "- 📦 Missing version pinning" >> $GITHUB_STEP_SUMMARY
+ echo "- ⚠️ Exposed secrets in build args" >> $GITHUB_STEP_SUMMARY
+ echo "" >> $GITHUB_STEP_SUMMARY
+ echo "#### Best Practices" >> $GITHUB_STEP_SUMMARY
+ echo "- 🎯 Layer optimization" >> $GITHUB_STEP_SUMMARY
+ echo "- 🗑️ Cleaning package manager cache" >> $GITHUB_STEP_SUMMARY
+ echo "- 📝 Using COPY instead of ADD" >> $GITHUB_STEP_SUMMARY
+ echo "- 🔧 Proper WORKDIR usage" >> $GITHUB_STEP_SUMMARY
+ echo "- 💾 Efficient layer caching" >> $GITHUB_STEP_SUMMARY
+ echo "" >> $GITHUB_STEP_SUMMARY
+ echo "#### Build Efficiency" >> $GITHUB_STEP_SUMMARY
+ echo "- 🚀 Multi-stage build opportunities" >> $GITHUB_STEP_SUMMARY
+ echo "- 📦 Unnecessary packages" >> $GITHUB_STEP_SUMMARY
+ echo "- 🔄 Combining RUN commands" >> $GITHUB_STEP_SUMMARY
+ echo "" >> $GITHUB_STEP_SUMMARY
+ echo "📊 **Results:**" >> $GITHUB_STEP_SUMMARY
+ echo "- Detailed results uploaded to GitHub Security tab" >> $GITHUB_STEP_SUMMARY
+ echo "- SARIF file available in artifacts" >> $GITHUB_STEP_SUMMARY
+ echo "" >> $GITHUB_STEP_SUMMARY
+ echo "🔗 **Links:**" >> $GITHUB_STEP_SUMMARY
+ echo "- [Security Tab](https://github.com/${{ github.repository }}/security/code-scanning)" >> $GITHUB_STEP_SUMMARY
+ echo "- [Hadolint Rules](https://github.com/hadolint/hadolint#rules)" >> $GITHUB_STEP_SUMMARY