mirror of
https://github.com/kevinveenbirkenbach/homepage.veen.world.git
synced 2026-04-07 05:12:19 +00:00
- Replace requirements.txt with pyproject.toml for modern Python packaging - Add unit, integration, lint and security test suites under tests/ - Add utils/export_runtime_requirements.py and utils/check_hadolint_sarif.py - Split monolithic CI into reusable lint.yml, security.yml and tests.yml - Refactor ci.yml to orchestrate reusable workflows; publish on semver tag only - Modernize Dockerfile: pin python:3.12-slim, install via pyproject.toml - Expand Makefile with lint, security, test and CI targets - Add test-e2e via act with portfolio container stop/start around run - Fix navbar_logo_visibility.spec.js: win.fullscreen() → win.enterFullscreen() - Set use_reloader=False in app.run() to prevent double-start in CI - Add app/core.* and build artifacts to .gitignore - Fix apt-get → sudo apt-get in tests.yml e2e job - Fix pip install --ignore-installed to handle stale act cache Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
78 lines
1.8 KiB
YAML
78 lines
1.8 KiB
YAML
name: Lint
|
|
|
|
on:
|
|
workflow_call:
|
|
workflow_dispatch:
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
lint-actions:
|
|
name: Lint GitHub Actions
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v6
|
|
|
|
- name: Run actionlint
|
|
run: docker run --rm -v "$PWD:/repo" -w /repo rhysd/actionlint:latest
|
|
|
|
lint-python:
|
|
name: Lint Python
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v6
|
|
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v6
|
|
with:
|
|
python-version: "3.12"
|
|
|
|
- name: Install lint dependencies
|
|
run: |
|
|
python -m pip install --upgrade pip
|
|
pip install ".[dev]"
|
|
|
|
- name: Ruff lint
|
|
run: ruff check .
|
|
|
|
- name: Ruff format check
|
|
run: ruff format --check .
|
|
|
|
lint-docker:
|
|
name: Lint Dockerfile
|
|
runs-on: ubuntu-latest
|
|
permissions:
|
|
contents: read
|
|
security-events: write
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v6
|
|
|
|
- name: Run hadolint
|
|
id: hadolint
|
|
continue-on-error: true
|
|
uses: hadolint/hadolint-action@2332a7b74a6de0dda2e2221d575162eba76ba5e5
|
|
with:
|
|
dockerfile: ./Dockerfile
|
|
format: sarif
|
|
output-file: hadolint-results.sarif
|
|
failure-threshold: warning
|
|
|
|
- name: Upload hadolint SARIF
|
|
if: always() && github.event_name == 'push'
|
|
uses: github/codeql-action/upload-sarif@v4
|
|
with:
|
|
sarif_file: hadolint-results.sarif
|
|
wait-for-processing: true
|
|
category: hadolint
|
|
|
|
- name: Fail on hadolint warnings
|
|
if: always()
|
|
run: python3 utils/check_hadolint_sarif.py hadolint-results.sarif
|