1. Overview
The --upgrade mode enables safe, non-intrusive updates on running JetPatch microservice stacks.
It minimizes risk by skipping installation-time validations and only redeploys services when configuration drift is not detected.
2. Upgrade Flow
Skipped During Upgrade
Prerequisite installs
Environment validation
SSL/keystore/truststore builds
Database ensure
Executed During Upgrade
Configuration synchronization using MD5 +
.newdrift detectionImage pulls with retry/backoff
Service redeployment (only if no drift is detected)
3. Pre-Upgrade Configuration
3.1 Repository Configuration in .env File
Navigate to the extracted deployment directory and edit .env file.
for example:
cd /root/jetpatch-prod-deployment/config/
ls -la
vi .env
Before running the upgrade, update the .env file located in the config/ directory.
This file defines critical environment variables, including the Docker image repository and service versions.
Ensure the following variables are correctly set:
for example:
# Docker image registry location
REPOSITORY=public.ecr.aws/xxxxxxxx/jetpatch/
# JetPatch service versions
MAIN_VERSION=5.0.xxx # get the version details from JETPATCH
WORKER_VERSION=5.0.xxx # get the version details from JETPATCH
.............Explanation of Variables
| Variable | Description |
|---|---|
| REPOSITORY | Points to the Docker image registry for pulling JetPatch service images. Use the public AWS ECR unless using a private registry. |
| MAIN_VERSION | Defines the JetPatch main services version (UI, backend). Must match repository version. |
| WORKER_VERSION | Defines the worker-related service version (agent tasks, patching). Must match repository version. |
4. Upgrade Behavior
4.1 Running Upgrade
Navigate to the extracted deployment directory and edit .env file.
for example:
cd /root/jetpatch-prod-deployment/bin/
Run the below command to upgrade 5.0
# Run safe upgrade
./install.sh --upgrade On Drift Detected
.newfiles are generated (e.g.,docker-compose.override.yml.new)Affected files are listed in logs
Action required: Compare changes and merge manually:
diff docker-compose.override.yml docker-compose.override.yml.new
vi docker-compose.override.yml # apply changes as neededOnce resolved, continue with --finalize.
4.2 Finalizing Upgrade
After resolving drift and merging .new files:
./install.sh --finalizeThis pulls the updated images and completes the upgrade to the new version specified in .env.
5. Compatibility & Risk
Backward compatible: Existing flags (
--install,--refresh,--validate,--finalize) remain unchanged.Non-disruptive: No SSL or DB changes during upgrade.
Comments
0 comments
Please sign in to leave a comment.