Speaker: Egor Stambakio
Organize efficient development process where development cycle takes less time and provides highest quality at the same time.
Highest quality can be achieved due to quality testing in conditions as close to production environment as possible.
Therefore remotely installed application is preferable.
Build and deployment are handled by background job.
Task is an open issue on Github
Create branch for this issue
Commit code to the branch and push branch to Github
Triggers the next stage: build
In every repository there is a directory .circleci with a config.yml file for CircleCI. Without it next phase won't be triggered.
If module can't be deployed (e.g. grails plugin), it is deployed as a part of bigger application.
In this case additional steps are required:
Automates pipeline from commit to deploy
CircleCI build workflow
Triggers the next stage: deploy to Kubernetes cluster
Notes:
Kubernetes cluster is provisioned for development purposes using Azure AKS service.
CircleCI deployment workflow
Every branch is deployed into a separate namespace (e.g. virtual sub-cluster).
When deployment is triggered by previous step, notification is sent into Slack channel providing useful details, e.g. links to deployment, source code, etc.
When deployment is up an running it is accessible in browser via URL, e.g. https://demo.core.dev.opuscapita.com/repo/branch/
Now we know that code is working. Create a pull request for code review
Say 'Hi' to QA:
Notes:
Merge pull request from development branch into the main (usually master) branch.
Recommended merge mode is squash & merge, which creates a single merge commit out of all branch commits.
Here developer should provide message according to particular template and confirm merge.
Properly formatted message will be automatically parsed during following steps and used as a part of release notes.
Delete development branch after merge
Every deployment in cluster has a background job, which tracks branch status and when branch is deleted it deletes deployment from cluster with all related resources.
Hense only relevant installations consume resources; obsolete installations are destroyed automatically.
When deployment is deleted, notification is sent into Slack channel:
Merge into main branch triggers automated CircleCI build on main branch.
If build on main branch is successful go to Minsk Core Multitool
CircleCI starts automated build according to rules defined in release branch in the repository
No more inventing a wheel for every ticket: clear workflow covers all needs in 9/10 cases (and growing as development flow is adjusted to the needs of team).
Nobody needs to wait for someone else. This results in time saving while providing better quality:
This approach provides clear separation of concerns and responsibility: developer is coding, QA is testing, robots assemble all parts. If something breaks along the line, it's easier to debug.
While setup looks unified, developer can easily fine-grain or change it entirely, because configurations for all steps belong to a repository. Configuration for build process can differ per branch, configuration for deployment and release processes can differ per repository.
I encourage developers to follow these guidelines:
I encourage teams to consider this workflow for their development process, because it's completely hands-on and Minsk core team benefits from it on a daily basis.
Any questions?
We are here to help:
Slack: channel #minsk-core-team
Thank you.
Speaker: Egor Stambakio
P. S. How you can find these slides
opuscapita.github.io/minsk-core-presentations