...
Source code - Mostly Git but can Liquibase Business projects can be checked into any source code provider (e.g. , TFS, SVN, etc.)
Build and deploy - Most common build tool is Jenkins but it can also easily integrate with other on-prem and cloud hosted tools, e.g., Bamboo, Azure DevOps, etc.
Artifacts repository - It is a common practice to use an artifacts repository such as Nexus or Artifactory to store versioned artifacts so that teams are always ready to deploy any version
Typical automation workflow
Initially, a user would create a new Liquibase Business project using the GUI and then check in the project into source code. It is typical to commit Liquibase Business project into the same repository as your SQL scripts.
Once the project is in source code, then the pipeline workflow would look like this:
Checkout repository
...
Deploy to DEV (first environment in the pipeline)
...
Create a versioned artifact
...
Deploy versioned artifact to TEST
...
, STAGE or PROD
...
Pseudo Code
1. Checkout repository
Code Block | ||
---|---|---|
| ||
# Clone specific repo into your workspace git clone <git_repo_url> # Checkout specific branch git checkout <git_branch> |
2. Deploy to DEV (first environment in the pipeline)
Code Block |
---|
# Deploy to your DEV (first environment intin hethe pipeline) hammer deploy DEV --labels="<specify_labels>" |
3. Create a versioned artifact
Code Block | ||
---|---|---|
| ||
# zip up the artifact or package using your favorite packaging method zip -q -r ${BUILD_NUMBER}.zip * # upload to Artifactory or Nexus |
4. Deploy versioned artifact to TEST, STAGE or PROD
Code Block | ||
---|---|---|
| ||
# download specific versioned artifact from Artifactory or Nexus # deploy to TEST, STAGE or PROD hammer deploy TEST --labels="<specify_labels>" |
...