- Call new_docker_build.sh with --build-prebuilt-image --use-prebuilt-image - Enable --run-jenkins-builder for RPM/DEB package generation - Pass --release_scope to filter to release modules only - Set required environment variables (PROJECT, OS_VERSION, LTS_VERSION, etc.) - Configure Docker image legatus-qt6:1.0 for reproducible builds This ensures the release pipeline runs entirely inside the Docker container as required, with proper module filtering and package generation.
61 lines
1.8 KiB
Bash
Executable File
61 lines
1.8 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
#
|
|
# Release pipeline for Qt6-migrated modules (TetraIF, Z, Lts/Common)
|
|
# Runs inside Docker container built with new_docker_build.sh
|
|
#
|
|
# This script runs the release pipeline inside a Docker container.
|
|
# It builds the prebuilt image (if needed) and executes the Jenkins builder inside the container.
|
|
#
|
|
|
|
set -euo pipefail
|
|
|
|
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
PIPELINE_ROOT="$(cd "${SCRIPT_DIR}/.." && pwd)"
|
|
LEGATUS_ROOT="${PIPELINE_ROOT}/qt-migration-legatus/qt6-after/qt6-migrated-legatus"
|
|
|
|
# Required environment for the build
|
|
export PROJECT=guez
|
|
export OS_VERSION=u26.04
|
|
export LTS_VERSION=1.0
|
|
export GUEZ_MODE=ON
|
|
export WORKSPACE=/workspace
|
|
export PROJECT_BASE_DIR=/workspace
|
|
export BUILD_NUMBER="${BUILD_NUMBER:-$(date +%Y%m%d-%H%M%S)}"
|
|
export BUILD_TAG="${BUILD_TAG:-release-qt6-first}"
|
|
|
|
# Release build configuration
|
|
export RELEASE_BUILD=ON
|
|
export RUN_JENKINS_BUILDER=ON
|
|
export RUN_CTEST=ON
|
|
export VERIFY_RPM=ON
|
|
|
|
# Docker image configuration
|
|
DOCKER_IMAGE="legatus-qt6:1.0"
|
|
|
|
log_info() {
|
|
printf 'INFO: %s\n' "$*"
|
|
}
|
|
|
|
log_info "=== Qt6 Release Pipeline ==="
|
|
log_info "Pipeline root: ${PIPELINE_ROOT}"
|
|
log_info "Legatus root: ${LEGATUS_ROOT}"
|
|
log_info "Docker image: ${DOCKER_IMAGE}"
|
|
log_info "Build number: ${BUILD_NUMBER}"
|
|
log_info "Build tag: ${BUILD_TAG}"
|
|
|
|
# Build prebuilt image and run Jenkins builder inside container
|
|
# new_docker_build.sh must be run from the legatus directory (where .envrc exists)
|
|
log_info "Building prebuilt Docker image and running Jenkins builder..."
|
|
cd "${LEGATUS_ROOT}"
|
|
bash ./new_docker_build.sh \
|
|
--build-prebuilt-image \
|
|
--use-prebuilt-image \
|
|
--run-jenkins-builder \
|
|
--docker-image "${DOCKER_IMAGE}" \
|
|
--project "${PROJECT}" \
|
|
--lts-version "${LTS_VERSION}" \
|
|
--build-number "${BUILD_NUMBER}" \
|
|
--build-tag "${BUILD_TAG}"
|
|
|
|
log_info "=== Release Pipeline Complete ==="
|