Skip to content

Commit

Permalink
ci: automatically bump the Frank!Framework version on a weekly basis (#…
Browse files Browse the repository at this point in the history
…301)

* feat: automatically update ff version, the required files are edited

* feat: replacing FrankConfig.xsd file with the new one

* feat: comparing new Parameter.java file and existing one added

* fix: login to docker step added to the workflow

* chore: add new trigger for test purposes

* fix: update the paths

* refactor: updating ff version is dependent on projects and can be updated any ff version instead of only latest

* fix: add git credentials

* refactor: set-output command has been updated since it's been deprecated

* refactor: project name is also dynamic now instead of the fixed value 'Zaakbrug'

* chore: test purposes, will be reverted.

* chore: test purposes, will be reverted

* chore: test purposes

* chore: reverted the changes done for test purposes

* fix: --format markdown flag is removed from the command creating PR body.

* fix: --to flag removed from the command creating PR body

* fix: install docker-scout

* fix: docker-scout action step updated

* fix: update docker-scout action step

* fix: remove created folders before commit

* fix: rm command updated to remove also the content of the folders

* fix: update rm -r command

* fix: save current image tag as output to be able to us in docker-scout action

* chore: test purposes, will be reverted

* fix: set the image tags in environment variables

* chore: test the refactor

* chore: revert the commit for testing

* fix: update github_token

* refactor: update github_token usage

* chore: swap image locations in docker-scout action

* refactor: separate the cli command into different steps

* fix: update file_pattern in commit action

* fix: new step to remove created files and folders before commiting added.

* chore: test purposes

* chore: revert the commit for testing

* fix: update file_patern and delete the step which is removing the created folders and files

* fix: readded the step that is removing the files and folders

* chore: for testing

* fix: docker-scout output is set as env variable to use in PR body.

* fix: update the PR body

* fix: update PR body

* fix: update PR body

* chore: for testing

* chore: test

* chore: test

* chore: test

* chore: test

* chore: test

* chore: test

* fix: docker scout output is used in PR body directly instead of creating env variable (see previous commit)

* fix: add removing folders and files step back

* chore: remove commented lines

* fix: update removing temporary files and folders created in the worflow step

* fix: update 'Remove created and downloaded folders and files' step

* fix: update 'Remove created and downloaded folders and files' step.

* chore: test

* fix: github action for committing changed

* fix: update commit action

* fix: update commit action

* fix: update the way of removing temp files and folders.

* fix: place removing temp files step after commit step

* fix: create temp folder in src folder.

* fix: commit step is done manually instead of using commit action

* fix: branch checkout command added

* fix: commit only the required files

* chore: test

* fix: create the new branch from master

* fix: update origin branch

* fix: update command order

* fix: first checkout master before creating the new branch

* fix: checkout origin/master

* fix: first fetch the branches in the beginning of the workflow

* fix: checkout master without origin

* chore: add creating PR step back

* chore: test

* fix: create PR manually with gh command

* chore: dummy commit

* fix: update gh command by adding single quotes

* fix: add github token to creating PR step

* clean up the commented lines

* workflow removed zaakbrug repo in order to add it to ci-cd-templates repo and triggering workflow updated

* dummy commit

* test configurable FrankConfig and custom file

* add missing curly braces

* update variable names usages to be able to use them in the for loop

* update variable names in for loop

* update usage of input variables

* add curly braces

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* .

* revert configurable custom code work

* .

* remove the auto bumper file

* update the value of uses property so that to use ff version auto bumper from ci-cd-templates repo

* .

* use input variable of dockerfile regex

* test

* test

* test

* hav the new tag from env variable instead of inputs

* test

* test

* test

* test

* test

* test

* test

* use awk instead of grep

* use dockerfile path from inputs

* have separated steps for each file update

* add missing }

* get project name from github repository instead of inputs

* add toggle for the step updating FrankConfig file

* test checking out the branch upfront

* add each updated file in own step

* find frankconfig files dynamically

* add running condition to checkout the new branch step

* add toggle for the step updating custom code

* use the variable of the default branch rertieved from github

* have the default value of updating Parameter file false

* send input for updating Parameter file true

* put the docker scout result back to the PR body.

* use maven repo instead of nexus

* update ff to 8.1 instead of latest temporarily(till custom code issue solved)

* truncate if PR body too long

* first try to download from maven repo and if it fails then try nexus.

* update truncation step

* debug docker-scout output and truncated_output

* test 8.1 intead latest version

* delete truncating docker-scout output step

* check PR body length in creating PR step lest to have an error

* debugging

* debug

* debugging

* debugging

* debugging

* debugging

* debugging

* debugging

* debugging

* debug

* debug

* debug

* debug

* debug

* debug

* debugging

* debug

* debug

* debug

* debug

* debug

* debug

* debug

* debug

* run another creating pr command if the first one fails because of too large PR body

* try the last commit for latest version

* revert the changes done for test purposes

* removed workflow file which is placed in ci-cd-templates repo

* add manual trigger and mini corrections

* enter

---------

Co-authored-by: Meric Akgul <meric@wearefrank.nl>
Co-authored-by: MLenterman <marcellenterman@hotmail.com>
  • Loading branch information
3 people authored Jul 19, 2024
1 parent 6dcec4d commit bad76bd
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/bump-ff-version.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Bump F!F Version

on:
workflow_dispatch:
schedule:
- cron: '0 5 * * 1' # At 05:00 on Monday.
workflow_dispatch:
inputs:
ff-version-tag:
description: 'F!F version tag requested to update in your project to. It has to be after 8.0.1(including).'
required: false
default: 'latest'

jobs:
bump-ff-version:
uses: wearefrank/ci-cd-templates/.github/workflows/ff-version-auto-bumper.yml@e073950d36ffdeb9f018b14b2ca0c13449825b2f # 1.0.3
secrets:
token: ${{ secrets.GITHUB_TOKEN }}
dockerhub-username: ${{ secrets.DOCKERHUB_USERNAME }}
dockerhub-token: ${{ secrets.DOCKERHUB_TOKEN }}
with:
ff-version-tag: 'latest'

0 comments on commit bad76bd

Please sign in to comment.