-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #11664 from DefectDojo/release/2.42.3
Release: Merge release into master from: release/2.42.3
- Loading branch information
Showing
63 changed files
with
73,641 additions
and
51,449 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
name: Update Sample Data | ||
|
||
env: | ||
GIT_USERNAME: "DefectDojo release bot" | ||
GIT_EMAIL: "[email protected]" | ||
|
||
on: | ||
workflow_dispatch: # Trigger manually | ||
schedule: | ||
# Run on the 1st day of January, April, July, and October at midnight UTC | ||
- cron: '0 0 1 1,4,7,10 *' | ||
|
||
jobs: | ||
run-binary-and-create-pr: | ||
runs-on: ubuntu-latest | ||
steps: | ||
# Checkout the repository | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
with: | ||
ref: ${{ github.ref_name || 'dev'}} | ||
|
||
- name: Run binary | ||
run: | | ||
./fixture-updater dojo/fixtures/defect_dojo_sample_data.json | ||
mv output.json dojo/fixtures/defect_dojo_sample_data.json | ||
- name: Configure git | ||
run: | | ||
git config --global user.name "${{ env.GIT_USERNAME }}" | ||
git config --global user.email "${{ env.GIT_EMAIL }}" | ||
- name: Create and switch to a new branch | ||
run: | | ||
git checkout -b update-file-$(date +%Y%m%d%H%M%S) | ||
git add dojo/fixtures/defect_dojo_sample_data.json | ||
git commit -m "Update sample data" | ||
- name: Push branch | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
git push --set-upstream origin $(git rev-parse --abbrev-ref HEAD) | ||
- name: Create Pull Request | ||
uses: peter-evans/create-pull-request@v5 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
commit-message: "Update sample data" | ||
branch: ${{ github.ref_name || 'dev'}} | ||
base: dev | ||
title: "Update sample data" | ||
body: "This pull request updates the sample data." |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.