feat: add act configuration for local workflow testing

- Add .actrc file to map custom runner labels to Docker images
- Add test-workflow.sh script for easy local testing with act
- Maps php-ci runner to php-ci:latest Docker image
- Maps docker-build runner to docker:latest
- Helps resolve 'ansible: command not found' errors when testing workflows locally
This commit is contained in:
2025-10-31 22:00:09 +01:00
parent e9f0847b1e
commit 798eea093a
2 changed files with 15 additions and 0 deletions

6
.actrc Normal file
View File

@@ -0,0 +1,6 @@
# Act Configuration for local GitHub Actions testing
# Maps runner labels to Docker images
# Format: -P label=image (one per line, or use test-workflow.sh script)
-P php-ci=php-ci:latest
-P docker-build=docker:latest

9
test-workflow.sh Executable file
View File

@@ -0,0 +1,9 @@
#!/bin/bash
# Script to test Gitea workflows locally with act
# Maps custom runner labels to Docker images
act -P php-ci=php-ci:latest \
-P docker-build=docker:latest \
-P ubuntu-latest=ubuntu:latest \
-P ubuntu-22.04=ubuntu:22.04 \
"$@"