Skip to content

Update dependencies #13

Update dependencies

Update dependencies #13

Workflow file for this run

name: Update dependencies
on:
schedule:
- cron: "0 4 * * 1" # Every Monday 04:00 UTC
workflow_dispatch:
jobs:
update:
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
- uses: actions/checkout@v4
- name: Run update script
run: |
sudo apt-get install -y jq
./scripts/update.sh
- uses: docker/setup-buildx-action@v3
- name: Test build Docker images
run: |
for version in 8.2 8.3 8.4 8.5; do
echo "Building PHP $version..."
docker buildx build --platform linux/amd64 "$version/"
done
- name: Create Pull Request
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
git add 8.2/Dockerfile 8.3/Dockerfile 8.4/Dockerfile 8.5/Dockerfile README.md
if git diff --staged --quiet; then
echo "Already up to date."
exit 0
fi
BRANCH="chore/update-dependencies-$(date +%Y-%m-%d)"
git checkout -b "$BRANCH"
git commit -m "chore: update Composer and Node to latest patch versions"
git push origin "$BRANCH"
gh pr create \
--base main \
--head "$BRANCH" \
--title "chore: update Composer and Node to latest patch versions" \
--body "Automated dependency update — Docker test builds passed." \
|| echo "PR already exists, skipping."