Deploy¶
Ready to deploy your changes in one of our instances:
In this guideline, we will take a look at when the pipeline for different instances is executed.
- Deploy Dev (Development instance)
- Deploy Test (Test instance)
- Deploy Production (Production instance)
Deploy Dev¶
Every time there is a branch dev
or merge_request
to the branch master of Repository
the pipeline stage for dev
is executed.
Pipeline¶
Deploy Test¶
Every commit or merge to the master branch of Repository will run Pipeline and deploy the changes to the Test instance.
Pipeline¶
Deploy Production¶
Every new Tag/release
of the Repository will run Pipeline and
deploy the changes to the Production instance.
Steps¶
Deployment to production requires a new Tag/release
of the Repository.
Meaning we should only deploy to production when we have a new Tag/release
.
1. Before creating a new Tag/release
first we must change the value of TAG_PROD
in GitLab CI/CD variables, to our expected new Tag/release
version.
For example the following change in TAG_PROD
variable:
- v2.0.2
+ v2.0.3
2. Create a new Tag/release
for the Repository, using semantic-versioning.
for example v2.0.3
, same value as in the TAG_PROD
file.
For Example using git:
git tag -a v2.0.3 -m "my version 0.1.2"