Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Exclude the Git version control folder
.git
.gitignore
.github/

# General exclusions
pytest.ini
README.md
TODO.md
tests/
compose.yml

# Nix develop
flake.lock
flake.nix
11 changes: 10 additions & 1 deletion .github/workflows/dev_build_push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,11 @@ jobs:
# Only allow running on the dev branch
if: github.ref == 'refs/heads/dev'

permissions:
contents: write # Needed to create tags and releases
packages: write # Needed to push to GHCR
id-token: write # For trusted publishing

steps:
- name: Checkout dev branch
uses: actions/checkout@v4
Expand All @@ -25,11 +30,15 @@ jobs:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Create lowercase repository name
id: repo
run: echo "name=${GITHUB_REPOSITORY,,}" >> $GITHUB_OUTPUT

- name: Build and push :dev image
uses: docker/build-push-action@v6
with:
context: .
push: true
tags: ghcr.io/${{ github.repository }}:dev
tags: ghcr.io/${{ steps.repo.outputs.name }}:dev
cache-from: type=gha
cache-to: type=gha,mode=max
42 changes: 42 additions & 0 deletions .github/workflows/security_scan.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: security scan
on:
push:
branches:
- main
pull_request:

permissions:
contents: read
security-events: write

jobs:
gosec_zizmor:
name: security scan
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
with:
persist-credentials: false
- uses: actions/setup-go@v6
with:
go-version: stable
- name: Run Gosec Security Scanner
uses: securego/gosec@6be2b51fd78feca86af91f5186b7964d76cb1256 # v2.22.10
with:
args: "-no-fail -fmt json -out results.json ./..."

- name: Check Gosec Results
run: |
FOUND=$(jq '.Stats.found // 0' results.json)
echo "Gosec found $FOUND issue(s)"
if [ "$FOUND" -gt 0 ]; then
echo "❌ Security issues detected! Please fix them before merging."
exit 1
else
echo "✅ No security issues found."
fi

- name: Run zizmor 🌈
uses: zizmorcore/zizmor-action@e639db99335bc9038abc0e066dfcd72e23d26fb4 # v0.3.0
with:
inputs: .
Loading