Closed TanmoySG closed 2 years ago
There are two Artefact Build Workflows required
And a Deployment to Azure Worflow, that will be torndown soon.
Apart from building these artefacts, they are required to be published to GitHub Package Registry and GitHub Releases as well.
There is a requirement for an Automated Workflow - using GitHub Actions - for building and Publishing these. These workflows are to triggered only on specific and special commits like version tagging using git tag
. Not all commits or even versioning should trigger these.
Plan and Observations
This, Strategy A
, triggers builds/workflows only if the version tagged and committed is a Major or Minor Update - so that only Feature-Ready/Feature-full releases are published.
On the other hand this strategy may also lead to Bug Fixes and Enhancements to be skipped for a long time until a Minor or Major Release Candidate is not Ready.
There are two Artefact Build Workflows required
And a Deployment to Azure Worflow, that will be torndown soon.
Apart from building these artefacts, they are required to be published to GitHub Package Registry and GitHub Releases as well.
There is a requirement for an Automated Workflow - using GitHub Actions - for building and Publishing these. These workflows are to triggered only on specific and special commits like version tagging using git tag
. Not all commits or even versioning should trigger these.
Plan and Observations
This, Strategy B
, triggers builds/workflows only if the version tagged and committed is a Major or Minor Update as well as Patch updates - so that both Feature-Ready/Feature-full releases and Bug Fixes are published to the artefacts.
On the other hand this strategy may also lead to frequent adoption changes on the user end.
Currently using dockerize-flask-test repo to test the Strategy in Action.
git
To create a Tag use the git tag
command as,
git tag <tag-name>
The tag-name
can be the version. You may also create an "annotated tag" using -a
flag and a tagging message following the -m
flag.
git tag -a v1.4 -m "my version 1.4"
List the tags
git tag
Push the Tags to remote origin/repo
git push --tags
Learn More at git-scm.com.
Currently there are 3 Branches being maintained
Code changes are made in the dev
branch and merged to main - either periodically to sync code or to sync feature-complete code to main.
dev
. When the Code is tested, and fit for Release
git checkout
.
git checkout main
main
branch, tag the code using git tag
. Use the main
branch-name following the tag name so as to ensure tag points to the latest commit on the main branch and hence the tag refers to production ready code on main branch.
git tag v1.2.34-alpha main
git push --tags
This should trigger the Deployment Workflows and create a Release and a Container is Published.
Note
main
branch. Git tags point to the HEAD (latest commit) in the git tree, when no branch is specified. Hence if a tag is created it points to the latest commit (HEAD) in the tree irrespective of the branch.
git tag v1.2.3
To Specify the Target Branch use the branch name in the git tag command
git tag v1.2.3 branch_name
Now the version v1.2.3 will point to the latest commit in the branch specified instead of the HEAD.
v0.0.1-test
for testing purposes.0.0.1-test
Release - tag/v0.0.1-test0.0.1-test
Containerized and Published - GitHub Docker RegistryPublished tag v0.1.0-alpha
of wIP.
A Release and Deploy Strategy is an essential part of Software Delivery Workflow. Not all Commits need to make it to deployment or release. A versioning system is also a cornerstone of this workflow. Hence a strategic approach is required to keep commits and deployment workflows separate. Currently, on a commit to the
deploy
branch triggers the deployment to Azure which is fine till a separate feature branch exists, but maintaining separate feature branches get tougher with project growing, hence thus Workflow too needs to be triggered only by specific actions like a version tagging or release.There are three deployments that are to be put into this strategy -
[Checkpoints]
v0.1.0-alpha
, First Release with the Workflow.[Issues]
[JFYI]
Versioning
A proper versioning system that should be used in this project is
In the Above
Refer to semver.org or versioning section in notes
Adopted Strategy
Strategy B
, triggers builds/workflows only if the version tagged and committed is a Major or Minor Update as well as Patch updates - so that both Feature-Ready/Feature-full releases and Bug Fixes are published to the artefacts.On the other hand this strategy may also lead to frequent adoption changes on the user end.
Strategy B