Upgrade Security Compliance Management in an air-gapped environment

When your Bolt runner does not have internet access, download the required image archives on an internet-connected machine and transfer them to the air-gapped runner. Restore your site-specific configuration before running the upgrade plan.

Before you begin:
  • You need an internet-connected machine to download the image archives. This machine does not need Docker, Podman, or Linux.

  • Ensure that the required runtime environment (Docker or Podman) is installed on the SCM host. The upgrade plan cannot install a runtime without internet access.

  • Ensure you are running Bolt 3.27.2 or later on the air-gapped Bolt runner.

  • If you are upgrading from an SCM version earlier than 3.7.1 to the latest version of SCM, you must upgrade to 3.7.1 first, then upgrade to the latest version.

Download image archives

Download the image archives on an internet-connected machine. The following manifest is for SCM 3.10.0.

Save the downloaded archives in downloads/comply/images/ relative to the Bolt project directory. The procedure backs up the existing project, prepares the updated project and image archives on an internet-connected machine, then transfers them to the air-gapped runner before restoring site-specific configuration.

  1. Rename your current Bolt project directory to preserve it as a backup:

    Copy
    mv comply-bolt-project comply-bolt-project-backup

    This directory contains your encrypted secrets, certificates, and target configuration. You will restore these from the backup in a later step.

  2. On the internet-connected machine, switch to the comply-bolt-project directory used to download the image archives:
    Copy
    cd comply-bolt-project
  3. Edit the bolt-project.yaml file to specify the new version of the module and your Forge API token. Change the modules and module-install sections to:
    Copy
    --- 
    name: comply_bolt_project
    modules:
    - name: puppetlabs/complyadm
      version_requirement: 3.y.z

    module-install:
      forge:
         authorization_token: 'Bearer <your API token>'
         baseurl: https://forgeapi.puppet.com
  4. Install the complyadm module using the command: bolt module install.
  5. Copy the updated Bolt project directory and downloaded image archives to the air-gapped runner. Save the archives in downloads/comply/images/ relative to the project directory.
  6. Restore your site-specific configuration from the backup by copying across your keys, data, and inventory:
    Copy
    cp -r ../comply-bolt-project-backup/keys/ keys/
    cp -r ../comply-bolt-project-backup/data/ data/
    cp -r ../comply-bolt-project-backup/ssh/ ssh/
    cp ../comply-bolt-project-backup/hiera.yaml hiera.yaml
    cp ../comply-bolt-project-backup/inventory.yaml inventory.yaml

    These items are unique to your installation. keys/ holds the PKCS7 keypair used to decrypt your secrets, data/ contains your encrypted configuration (hostnames, credentials, certificates), hiera.yaml wires the keys to the data directory, and inventory.yaml defines your SCM target. Without them, the upgrade plan cannot connect to or configure your installation.

  7. Run the upgrade plan:

    bolt plan run complyadm::upgrade

    The plan prompts you to make a backup. Respond to this prompt with y to make a backup. Because the image archives are saved in downloads/comply/images/, the plan uses the local cache automatically. You see output confirming that an image is served from the local cache:

    Archive '...comply-assessor_4.60.0.tar.gz' for role 'ui' exists in local cache, not updating.
    Archive '...comply-assessor_4.60.0.tar.gz' for 'ui' role does not exist on 'scm', uploading.
    [...]
    Plan completed successfully with no result

Optional parameters

You can pass the following parameters to skip interactive prompts or modify upgrade behavior:

Parameter Type Default Description
ignore_failing_preflights Boolean false When true, the plan continues even if preflight checks (OS, memory, CPU, required packages) do not pass.
upload_images Boolean true Must remain true for air-gapped upgrades. Setting this to false would cause the SCM host to attempt to pull images directly from the registry, which fails without internet access.

Examples

Skip preflight checks on an air-gapped:

Copy
bolt plan run complyadm::upgrade ignore_failing_preflights=true

What the plan does

The upgrade plan performs the following steps in order:

  1. Verifies your Bolt version is supported.

  2. Optionally runs complyadm::backup to back up the database and volumes.

  3. Runs preflight checks (architecture, runtime, memory, OS, CPU, required packages).

  4. Skips container runtime installation. In an air-gapped environment the runtime must already be present on the SCM host.

  5. Uploads container images from the local archive directory (downloads/comply/images/) to the target. Images already present on the target are skipped.

  6. Detects whether a major PostgreSQL version bump has occurred. If so, it automatically stops services, backs up the database, removes the old volume, applies the new version, and restores the backup.

  7. Applies updated configuration to all roles (database, backend, UI).

  8. Waits for services to become healthy.

  9. Runs cleanup tasks.

Results
Security Compliance Management is upgraded to the new version using the downloaded local images. No internet access is required during the upgrade itself.

You can verify the upgrade by navigating to your Security Compliance Management web console, or by running:

bolt plan run complyadm::validate