Compare commits

..
2 Commits
Author SHA1 Message Date
Hugo Nijhuis-MekkelholtandClaude Opus 4.5 a6d1e96aee Update URLs from code.flowmade.one to git.flowmade.one
Migrate all action files to use the new Gitea server URL.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-30 14:39:01 +01:00
Hugo Nijhuis-MekkelholtandClaude Opus 4.5 a95609d293 Add reusable Forgejo Actions
Composite actions for CI/CD workflows:
- checkout: Clone repo with configurable depth
- docker-build: Build Docker images with multiple tags
- docker-push: Push to Forgejo Packages registry
- create-tag: Auto-increment semantic version tags
- create-issue: Create issues via Forgejo API
- create-pr: Create pull requests via Forgejo API
- comment-pr: Add comments to PRs via Forgejo API

All actions use shell scripts (no Node.js required).

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-25 23:16:20 +01:00
2 changed files with 8 additions and 37 deletions
+3 -21
View File
@@ -20,27 +20,9 @@ runs:
steps: steps:
- shell: bash - shell: bash
run: | run: |
URL="https://oauth2:${{ inputs.token }}@git.flowmade.one/${{ inputs.repository }}.git"
clone() {
if [ "${{ inputs.depth }}" = "0" ]; then if [ "${{ inputs.depth }}" = "0" ]; then
git clone "$URL" . git clone "https://oauth2:${{ inputs.token }}@git.flowmade.one/${{ inputs.repository }}.git" .
else else
git clone --depth "${{ inputs.depth }}" --branch "${{ inputs.ref }}" "$URL" . git clone --depth "${{ inputs.depth }}" --branch "${{ inputs.ref }}" \
"https://oauth2:${{ inputs.token }}@git.flowmade.one/${{ inputs.repository }}.git" .
fi fi
}
# Runner egress is flaky (transient DNS/connection failures to the git
# server); retry with backoff before failing the job.
ok=0
for attempt in 1 2 3; do
if clone; then
ok=1
break
fi
if [ "$attempt" -eq 3 ]; then
break
fi
echo "clone failed, retrying in $((attempt * 10))s..."
sleep $((attempt * 10))
done
[ "$ok" -eq 1 ] || exit 1
+2 -13
View File
@@ -56,18 +56,7 @@ runs:
done <<< "$BUILD_ARGS" done <<< "$BUILD_ARGS"
fi fi
# Build the image; retry on failure. Base-image pulls from external # Build the image
# registries flake on transient runner DNS/network issues, and the docker build $TAG_ARGS $BUILD_ARG_ARGS -f "$DOCKERFILE" "$CONTEXT"
# BuildKit layer cache makes a retry of a failed build cheap.
for attempt in 1 2; do
if docker build $TAG_ARGS $BUILD_ARG_ARGS -f "$DOCKERFILE" "$CONTEXT"; then
break
fi
if [ "$attempt" -eq 2 ]; then
exit 1
fi
echo "build failed, retrying in 30s..."
sleep 30
done
echo "images=$IMAGES" >> $GITHUB_OUTPUT echo "images=$IMAGES" >> $GITHUB_OUTPUT