Adds CI CD with deb for external deps

This commit is contained in:
torsten committed 2026-11-06 18:15:17 +00:00
1 parent 03d48b76e4
commit 7373cb8d73
82 files changed
+3547 -3

No files matched your search

@@ -0,0 +1,168 @@
# External Dependencies CI/CD Pipelines
This directory contains CI/CD pipelines for 8 external dependencies required for the Legatus project in air-gapped environments.
## Overview
| Dependency | Version | License Type | Pipeline Status |
|------------|---------|--------------|-----------------|
| AVS | 1.0.0 | Contract-based (lifetime) | ✅ Complete |
| ArcGIS | 300.0.0 | Embedded ini-file licenses (lifetime) | ✅ Complete |
| BuildingModels | 1.0.0 | Proprietary | ✅ Complete |
| GeographicLib | 1.52 | MIT | ✅ Complete |
| Schusstafel | 1.0.0 | Proprietary | ✅ Complete |
| dtEntity | 1.0.0 | Open Source | ✅ Complete |
| RTI Connext DDS | 7.7.0 | Commercial license file (lifetime) | ✅ Complete |
| tmsif | 1.0.0 | Contract-based (lifetime) | ✅ Complete |
## Directory Structure
```
external-dependencies/
├── avs/ # AVS dependency pipeline
│ ├── Dockerfile
│ └── Jenkinsfile
├── arcgis/ # ArcGIS Runtime SDK pipeline
│ ├── Dockerfile
│ └── Jenkinsfile
├── buildingmodels/ # BuildingModels dependency pipeline
│ ├── Dockerfile
│ └── Jenkinsfile
├── geographiclib/ # GeographicLib dependency pipeline
│ ├── Dockerfile
│ └── Jenkinsfile
├── schusstafel/ # Schusstafel dependency pipeline
│ ├── Dockerfile
│ └── Jenkinsfile
├── dtentity/ # dtEntity game engine pipeline
│ ├── Dockerfile
│ └── Jenkinsfile
├── rti-connext-dds/ # RTI Connext DDS pipeline
│ ├── Dockerfile
│ └── Jenkinsfile
├── tmsif/ # TMSIF dependency pipeline
│ ├── Dockerfile
│ └── Jenkinsfile
├── scripts/
│ ├── generate-sbom.sh # SBOM generation script
│ ├── download-all-dependencies.sh
│ ├── download-deb-packages.sh
│ └── verify-offline-cache.sh
├── offline-cache/ # Downloaded packages (excluded from git)
├── DEPENDENCIES-INVENTORY.md
├── AIRGAP-SUMMARY.md
└── README.md
```
## License Handling
### RTI Connext DDS (File-Based)
- **License File:** `rti_license.dat` (repository root)
- **Type:** FlexLM commercial license
- **Handling:**
- License file copied into container during build
- `RTI_LICENSE_FILE` environment variable set
- Jenkinsfile copies license from repository root to build context
- **Location in Container:** `/opt/rti_license.dat`
### AVS (Contract-Based)
- **Type:** Lifetime license contract
- **Handling:** No license file required
- **Notes:** License managed at contract level, not file-based
### ArcGIS (Embedded Ini-File Licenses)
- **Type:** Map-specific embedded licenses
- **Handling:** Licenses embedded in 19 `.ini` files
- **Location:** `Lts/Viewer/SituationMap/Map/*.ini`
- **Notes:** Licenses travel with map configuration files
### tmsif (Contract-Based)
- **Type:** Lifetime license contract
- **Handling:** No license file required
- **Notes:** License managed at contract level, not file-based
### Other Dependencies
- **BuildingModels, Schusstafel:** Proprietary, contract-based
- **GeographicLib:** MIT license (open source)
- **dtEntity:** Open source
## Air-Gapped Environment Configuration
All Dockerfiles include:
- Internal Nexus repository: `remote-repo.sl.defence-elec.de:8081`
- Proxy configuration: `http://10.198.80.130:3128`
- Harbor registry: `harbor.sl.defence-elec.de/proxydockerhub`
- Internal CA certificates
- User creation (ctc, rme)
## SBOM Generation
All pipelines generate:
- CycloneDX SBOM (`sbom.json`)
- SLSA provenance (`provenance.json`)
- License report (`licenses.txt`)
SBOM files are stored in `sbom/` subdirectory for each dependency.
## Usage
### Building a Specific Dependency
```bash
cd external-dependencies/<dependency-name>
docker build -t <image-name>:<version> .
```
### Running Jenkins Pipeline
1. Ensure offline cache is available at `/opt/offline-cache/`
2. Configure Harbor credentials in Jenkins
3. Run pipeline from respective Jenkinsfile
### Offline Installation
For air-gapped environments:
1. Run `scripts/download-all-dependencies.sh` in connected environment
2. Transfer `offline-cache/` via secure media (encrypted USB)
3. Mount offline cache in Jenkins container
4. Pipelines will use cached packages
## Verification
Each pipeline includes verification stage:
- AVS: Checks `/opt/AVS/` directory
- ArcGIS: Verifies SDK installation and directory structure
- RTI: Validates license file and environment variable
- Others: Verify installation directories and basic functionality
## Troubleshooting
### License Issues (RTI)
- Ensure `rti_license.dat` is in repository root
- Check `RTI_LICENSE_FILE` environment variable in container
- Verify license server connectivity (if using network license)
### Offline Cache Issues
- Verify cache structure: `qt6/`, `src/`, `deb/`
- Check file permissions in mounted volumes
- Ensure all required packages are downloaded
### Build Failures
- Check proxy configuration in Dockerfile
- Verify internal repository accessibility
- Review CA certificate installation
## Security Considerations
- License files (e.g., `rti_license.dat`) excluded from git via `.gitignore`
- Offline cache (2.3GB) excluded from version control
- Transfer sensitive files via encrypted media only
- Harbor credentials managed via Jenkins credentials store
- All containers run as non-root user (ctc)
## Related Documentation
- `DEPENDENCIES-INVENTORY.md` - Complete dependency inventory
- `AIRGAP-SUMMARY.md` - Air-gapped environment adaptation details
- `offline-cache/README.md` - Offline cache structure and usage
- `scripts/README.md` - Script documentation
+111
View File
@@ -80,6 +80,117 @@ This generates:
- `<package>-provenance.json`: SLSA v1.0 provenance - `<package>-provenance.json`: SLSA v1.0 provenance
- `<package>-licenses.txt`: License compliance report - `<package>-licenses.txt`: License compliance report
## External Dependencies (Proprietary/Custom)
The following 8 external dependencies use a **DEB package-based deployment model** from the internal SCM repository:
### Dependencies List
| Dependency | Version | DEB Package | License Type |
|------------|---------|-------------|--------------|
| AVS | Custom | `libavs-dev` | Contract-based (lifetime) |
| ArcGIS Runtime SDK | 300.0.0 | `libarcgis-maps-sdk-qt-dev` | Embedded ini-file licenses |
| BuildingModels | Custom | `libbuildingmodels-dev` | Internal |
| GeographicLib | Custom | `libgeographiclib-dev` | MIT |
| Schusstafel | Custom | `libschusstafel-dev` | Internal |
| dtEntity | Custom | `libdtentity-dev` | Open Source |
| RTI Connext DDS | 7.7.0 | `librti-connext-dds-7.7.0-dev` | Commercial (license file) |
| tmsif | Custom | `libtmsif-dev` | Contract-based (lifetime) |
### DEB Package Repository
All DEB packages are stored in the internal SCM repository:
- **URL:** `https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general`
- **APT Repository:** `http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu`
- **Signing Key:** `http://10.198.80.75/rme/deb_and_rpm_signage_key.pub`
### Dockerfile Pattern
All 8 Dockerfiles follow this pattern:
```dockerfile
# Install <dependency> from internal SCM repository
# DEB package: <deb-package-name>
# Repository: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
# License handling: <license-type>
# <license-details>
RUN apt-get update && apt-get install -y \
<deb-package-name> \
&& rm -rf /var/lib/apt/lists/*
```
### License Handling
**RTI Connext DDS (7.7.0):**
- License file: `rti_license.dat` (provided at build time)
- Environment variable: `RTI_LICENSE_FILE=/opt/rti_connext_dds-7.7.0/rti_license.dat`
- Commercial license with FlexLM
**ArcGIS Runtime SDK (300.0.0):**
- Licenses embedded in 19 .ini files
- Location: `Lts/Viewer/SituationMap/Map/*.ini`
- Map-specific one-line license strings
**AVS & tmsif:**
- Contract-based licensing (lifetime licenses)
- No license files required
- Customer has physical license contracts
**BuildingModels, GeographicLib, Schusstafel, dtEntity:**
- Internal or open source
- No license files required
### Jenkinsfile Pattern
All 8 Jenkinsfiles include:
```groovy
stage('Prepare License Files') {
steps {
// License handling: <license-type>
// <license-details>
// DEB package installed from internal SCM repository
// Repository: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
// Package: <deb-package-name>
sh '''
apt-get update
apt-get install -y <deb-package-name>
'''
}
}
```
### DEB Package Build Pipelines
Each dependency has a DEB package build directory:
```
external-dependencies/deb-packages/
├── avs/ # AVS DEB package build
├── arcgis/ # ArcGIS DEB package build
├── buildingmodels/ # BuildingModels DEB package build
├── geographiclib/ # GeographicLib DEB package build
├── schusstafel/ # Schusstafel DEB package build
├── dtentity/ # dtEntity DEB package build
├── rti-connext-dds/ # RTI Connext DDS DEB package build
└── tmsif/ # tmsif DEB package build
```
Each directory contains:
- `debian/` directory with control files
- Build scripts for package creation
- README with packaging instructions
### Installation in Air-Gapped Environment
1. DEB packages are built and uploaded to internal SCM repository
2. CI/CD pipelines configure APT to use internal repository
3. Dockerfiles install packages via `apt-get install`
4. SBOM generation tracks all installed packages
## Air-Gapped Environment Support ## Air-Gapped Environment Support
For air-gapped deployment, offline dependency packages are prepared and transferred via secure media: For air-gapped deployment, offline dependency packages are prepared and transferred via secure media:
+88
View File
@@ -0,0 +1,88 @@
# ArcGIS Maps SDK for Qt Installation
FROM harbor.sl.defence-elec.de/proxydockerhub/library/ubuntu:26.04
ARG RME_USERPASS=ctc
ARG RME_ADMINSRV=10.198.80.75
ARG RME_PROJECT=guez
# Proxy configuration for air-gapped environments
ARG http_proxy="http://10.198.80.130:3128"
ARG no_proxy="localhost,127.0.0.1,defence-elec.de,.defence-elec.de,sl.defence-elec.de,10.198.80.0/23,192.168.133.0/24,141.200.0.0/16,10.184.0.0/15,10.199.101.35,10.199.101.36,10.199.101.158"
ARG HTTP_PROXY=${http_proxy}
ARG https_proxy=${http_proxy}
ARG HTTPS_PROXY=${http_proxy}
ARG NO_PROXY=${no_proxy}
LABEL author="Legatus Team"
LABEL project=${RME_PROJECT}
LABEL version="300.0.0"
LABEL description="ArcGIS Maps SDK for Qt 300.0.0"
ENV DEBIAN_FRONTEND=noninteractive
# OS and PATH configuration
ENV LANG=C.UTF-8 \
LC_ALL=C.UTF-8
# Shell global auf Bash mit sicheren Pipes umstellen
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
# Originale Repositories durch Nexus Proxies ersetzen
RUN echo : > /etc/apt/sources.list && \
echo -e "Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu\n\
Suites: resolute resolute-updates resolute-backports\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu-security\n\
Suites: resolute-security\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: https://internal-repo.sl.defence-elec.de/repository/external-rpms\n\
Suites: general\n\
Components: main\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg" > /etc/apt/sources.list.d/ubuntu.sources
# Create users (install openssl first for password hashing)
RUN apt-get update && apt-get install -y openssl \
&& groupadd ctc -g 1445 || true \
&& groupadd rme -g 1001 || true \
&& useradd -d /shd/CTC/TOOLS -u 1445 -g ctc -m -p $(openssl passwd -5 ${RME_USERPASS}) ctc || true \
&& useradd -d /home/rme -u 1001 -g rme -m -p $(openssl passwd -5 ${RME_USERPASS}) rme || true \
&& rm -rf /var/lib/apt/lists/*
RUN curl -fsSL http://${RME_ADMINSRV}/rme/deb_and_rpm_signage_key.pub --output /etc/apt/keyrings/deb_and_rpm_signage_key.asc \
&& curl -fsSL http://${RME_ADMINSRV}/rme/SL-Netz.crt --output /usr/local/share/ca-certificates/SL-Netz.crt \
&& update-ca-certificates
ARG ARCGIS_VERSION=300.0.0
# Install build dependencies
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential cmake git \
libqt6core6 libqt6gui6 libqt6widgets6 \
qt6-base-dev \
libarcgis-maps-sdk-qt-dev \
&& rm -rf /var/lib/apt/lists/*
# Set ArcGIS SDK path
ENV ARCGIS_SDK_ROOT=/opt/ArcGIS/MapsSDK_Qt_300.0.0
ENV ARCGIS_SDK_DIR=/opt/ArcGIS/MapsSDK_Qt_300.0.0/qt300.0.0/sdk
# LICENSE HANDLING: ArcGIS uses map-specific embedded licensing (no separate license file required)
# Licenses are embedded in .ini files at Lts/Viewer/SituationMap/Map/*.ini (19 files)
# Customer has lifetime license contract for air-gapped environment
# DEB package installed from internal SCM repository
# License strings are embedded in Qt application configuration files
# Verify installation
RUN test -d /opt/ArcGIS/MapsSDK_Qt_300.0.0/qt300.0.0/sdk
USER ctc
WORKDIR /shd/CTC/TOOLS
CMD ["/bin/bash"]
+112
View File
@@ -0,0 +1,112 @@
pipeline {
agent any
environment {
ARCGIS_VERSION = '300.0.0'
HARBOR_REGISTRY = 'harbor.sl.defence-elec.de/proxydockerhub'
IMAGE_NAME = 'arcgis'
IMAGE_TAG = "${ARCGIS_VERSION}"
OFFLINE_CACHE_PATH = '/opt/offline-cache/arcgis'
}
options {
timeout(time: 20, unit: 'MINUTES')
buildDiscarder(logRotator(numToKeepStr: '10'))
}
stages {
stage('Checkout') {
steps {
checkout scm
}
}
stage('Prepare License Files') {
steps {
script {
// LICENSE HANDLING: ArcGIS uses embedded ini-file licenses.
// Map-specific licenses are embedded in 19 .ini files in Lts/Viewer/SituationMap/Map/.
// Customer has lifetime license contract - ini files contain license strings.
// No separate license file required; licenses travel with map configuration.
// DEB package (libarcgis-maps-sdk-qt-dev) will be installed from internal SCM repository.
sh """
echo "ArcGIS license: Embedded in map configuration ini files"
"""
}
}
}
stage('Build ArcGIS Container') {
steps {
script {
dir('external-dependencies/arcgis') {
sh """
docker build \
--build-arg ARCGIS_VERSION=${ARCGIS_VERSION} \
-t ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} \
.
"""
}
}
}
}
stage('Verify ArcGIS') {
steps {
script {
sh """
docker run --rm ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} bash -c '
ls -la /opt/ArcGIS/MapsSDK_Qt_300.0.0/
test -d /opt/ArcGIS/MapsSDK_Qt_300.0.0/qt300.0.0/sdk
'
"""
}
}
}
stage('Generate SBOM') {
steps {
script {
dir('external-dependencies/arcgis') {
sh """
mkdir -p sbom
# Set environment variables for SBOM generation
export GIT_URL="${env.GIT_URL}"
export GIT_COMMIT="${env.GIT_COMMIT}"
export BUILD_NUMBER="${env.BUILD_NUMBER}"
export DOCKERFILE_PATH="external-dependencies/arcgis/Dockerfile"
# Generate CycloneDX SBOM, SLSA provenance, and license report
bash ../scripts/generate-sbom.sh arcgis ${ARCGIS_VERSION} ./sbom
"""
}
}
}
}
stage('Push to Registry') {
steps {
script {
withCredentials([usernamePassword(
credentialsId: 'harbor-credentials',
usernameVariable: 'HARBOR_USER',
passwordVariable: 'HARBOR_PASSWORD'
)]) {
sh """
echo ${HARBOR_PASSWORD} | docker login ${HARBOR_REGISTRY} -u ${HARBOR_USER} --password-stdin
docker push ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG}
docker logout ${HARBOR_REGISTRY}
"""
}
}
}
}
}
post {
always {
cleanWs()
}
}
}
+84
View File
@@ -0,0 +1,84 @@
# AVS Installation
FROM harbor.sl.defence-elec.de/proxydockerhub/library/ubuntu:26.04
ARG RME_USERPASS=ctc
ARG RME_ADMINSRV=10.198.80.75
ARG RME_PROJECT=guez
# Proxy configuration for air-gapped environments
ARG http_proxy="http://10.198.80.130:3128"
ARG no_proxy="localhost,127.0.0.1,defence-elec.de,.defence-elec.de,sl.defence-elec.de,10.198.80.0/23,192.168.133.0/24,141.200.0.0/16,10.184.0.0/15,10.199.101.35,10.199.101.36,10.199.101.158"
ARG HTTP_PROXY=${http_proxy}
ARG https_proxy=${http_proxy}
ARG HTTPS_PROXY=${http_proxy}
ARG NO_PROXY=${no_proxy}
LABEL author="Legatus Team"
LABEL project=${RME_PROJECT}
LABEL version="1.0.0"
LABEL description="AVS library for Legatus"
ENV DEBIAN_FRONTEND=noninteractive
# OS and PATH configuration
ENV LANG=C.UTF-8 \
LC_ALL=C.UTF-8
# Shell global auf Bash mit sicheren Pipes umstellen
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
# Originale Repositories durch Nexus Proxies ersetzen
RUN echo : > /etc/apt/sources.list && \
echo -e "Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu\n\
Suites: resolute resolute-updates resolute-backports\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu-security\n\
Suites: resolute-security\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: https://internal-repo.sl.defence-elec.de/repository/external-rpms\n\
Suites: general\n\
Components: main\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg" > /etc/apt/sources.list.d/ubuntu.sources
# Create users (install openssl first for password hashing)
RUN apt-get update && apt-get install -y openssl \
&& groupadd ctc -g 1445 || true \
&& groupadd rme -g 1001 || true \
&& useradd -d /shd/CTC/TOOLS -u 1445 -g ctc -m -p $(openssl passwd -5 ${RME_USERPASS}) ctc || true \
&& useradd -d /home/rme -u 1001 -g rme -m -p $(openssl passwd -5 ${RME_USERPASS}) rme || true \
&& rm -rf /var/lib/apt/lists/*
RUN curl -fsSL http://${RME_ADMINSRV}/rme/deb_and_rpm_signage_key.pub --output /etc/apt/keyrings/deb_and_rpm_signage_key.asc \
&& curl -fsSL http://${RME_ADMINSRV}/rme/SL-Netz.crt --output /usr/local/share/ca-certificates/SL-Netz.crt \
&& update-ca-certificates
ARG AVS_VERSION=1.0.0
# Install build dependencies
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential cmake git \
libavs-dev \
&& rm -rf /var/lib/apt/lists/*
# Set AVS installation path
ENV AVS_ROOT=/opt/AVS
# LICENSE HANDLING: AVS uses contract-based licensing (no license file required)
# Customer has lifetime license contract for air-gapped environment
# DEB package installed from internal SCM repository
# No license file copy or environment variable needed
# Verify installation
RUN test -f /opt/AVS/lib/libAVS.so || test -d /opt/AVS/include
USER ctc
WORKDIR /shd/CTC/TOOLS
CMD ["/bin/bash"]
+110
View File
@@ -0,0 +1,110 @@
pipeline {
agent any
environment {
AVS_VERSION = '1.0.0'
HARBOR_REGISTRY = 'harbor.sl.defence-elec.de/proxydockerhub'
IMAGE_NAME = 'avs'
IMAGE_TAG = "${AVS_VERSION}"
OFFLINE_CACHE_PATH = '/opt/offline-cache/avs'
}
options {
timeout(time: 20, unit: 'MINUTES')
buildDiscarder(logRotator(numToKeepStr: '10'))
}
stages {
stage('Checkout') {
steps {
checkout scm
}
}
stage('Prepare License Files') {
steps {
script {
// LICENSE HANDLING: AVS uses contract-based licensing.
// Customer has lifetime license contract - no license file required.
// License is managed at contract level, not file-based.
// DEB package (libavs-dev) will be installed from internal SCM repository.
sh """
echo "AVS license: Contract-based (no file required)"
"""
}
}
}
stage('Build AVS Container') {
steps {
script {
dir('external-dependencies/avs') {
sh """
docker build \
--build-arg AVS_VERSION=${AVS_VERSION} \
-t ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} \
.
"""
}
}
}
}
stage('Verify AVS') {
steps {
script {
sh """
docker run --rm ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} bash -c '
ls -la /opt/AVS/
'
"""
}
}
}
stage('Generate SBOM') {
steps {
script {
dir('external-dependencies/avs') {
sh """
mkdir -p sbom
# Set environment variables for SBOM generation
export GIT_URL="${env.GIT_URL}"
export GIT_COMMIT="${env.GIT_COMMIT}"
export BUILD_NUMBER="${env.BUILD_NUMBER}"
export DOCKERFILE_PATH="external-dependencies/avs/Dockerfile"
# Generate CycloneDX SBOM, SLSA provenance, and license report
bash ../scripts/generate-sbom.sh avs ${AVS_VERSION} ./sbom
"""
}
}
}
}
stage('Push to Registry') {
steps {
script {
withCredentials([usernamePassword(
credentialsId: 'harbor-credentials',
usernameVariable: 'HARBOR_USER',
passwordVariable: 'HARBOR_PASSWORD'
)]) {
sh """
echo ${HARBOR_PASSWORD} | docker login ${HARBOR_REGISTRY} -u ${HARBOR_USER} --password-stdin
docker push ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG}
docker logout ${HARBOR_REGISTRY}
"""
}
}
}
}
}
post {
always {
cleanWs()
}
}
}
@@ -0,0 +1,86 @@
# BuildingModels Installation
FROM harbor.sl.defence-elec.de/proxydockerhub/library/ubuntu:26.04
ARG RME_USERPASS=ctc
ARG RME_ADMINSRV=10.198.80.75
ARG RME_PROJECT=guez
# Proxy configuration for air-gapped environments
ARG http_proxy="http://10.198.80.130:3128"
ARG no_proxy="localhost,127.0.0.1,defence-elec.de,.defence-elec.de,sl.defence-elec.de,10.198.80.0/23,192.168.133.0/24,141.200.0.0/16,10.184.0.0/15,10.199.101.35,10.199.101.36,10.199.101.158"
ARG HTTP_PROXY=${http_proxy}
ARG https_proxy=${http_proxy}
ARG HTTPS_PROXY=${http_proxy}
ARG NO_PROXY=${no_proxy}
LABEL author="Legatus Team"
LABEL project=${RME_PROJECT}
LABEL version="1.0.0"
LABEL description="BuildingModels library for Legatus"
ENV DEBIAN_FRONTEND=noninteractive
# OS and PATH configuration
ENV LANG=C.UTF-8 \
LC_ALL=C.UTF-8
# Shell global auf Bash mit sicheren Pipes umstellen
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
# Originale Repositories durch Nexus Proxies ersetzen
RUN echo : > /etc/apt/sources.list && \
echo -e "Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu\n\
Suites: resolute resolute-updates resolute-backports\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu-security\n\
Suites: resolute-security\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: https://internal-repo.sl.defence-elec.de/repository/external-rpms\n\
Suites: general\n\
Components: main\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg" > /etc/apt/sources.list.d/ubuntu.sources
# Create users (install openssl first for password hashing)
RUN apt-get update && apt-get install -y openssl \
&& groupadd ctc -g 1445 || true \
&& groupadd rme -g 1001 || true \
&& useradd -d /shd/CTC/TOOLS -u 1445 -g ctc -m -p $(openssl passwd -5 ${RME_USERPASS}) ctc || true \
&& useradd -d /home/rme -u 1001 -g rme -m -p $(openssl passwd -5 ${RME_USERPASS}) rme || true \
&& rm -rf /var/lib/apt/lists/*
RUN curl -fsSL http://${RME_ADMINSRV}/rme/deb_and_rpm_signage_key.pub --output /etc/apt/keyrings/deb_and_rpm_signage_key.asc \
&& curl -fsSL http://${RME_ADMINSRV}/rme/SL-Netz.crt --output /usr/local/share/ca-certificates/SL-Netz.crt \
&& update-ca-certificates
ARG BUILDINGMODELS_VERSION=1.0.0
# Install build dependencies
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential cmake git \
&& rm -rf /var/lib/apt/lists/*
# Install BuildingModels from DEB package (air-gapped environment)
# DEB package is downloaded from internal SCM repository:
# https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
RUN apt-get update && apt-get install -y --no-install-recommends \
libbuildingmodels-dev=${BUILDINGMODELS_VERSION} \
&& rm -rf /var/lib/apt/lists/*
# Set BuildingModels installation path
ENV BUILDINGMODELS_ROOT=/opt/BuildingModels
ENV BUILDINGMODELS_VERSION=${BUILDINGMODELS_VERSION}
# Verify installation
RUN test -f /opt/BuildingModels/lib/libBuildingModels.so || test -d /opt/BuildingModels/include
USER ctc
WORKDIR /shd/CTC/TOOLS
CMD ["/bin/bash"]
+108
View File
@@ -0,0 +1,108 @@
pipeline {
agent any
environment {
BUILDINGMODELS_VERSION = '1.0.0'
HARBOR_REGISTRY = 'harbor.sl.defence-elec.de/proxydockerhub'
IMAGE_NAME = 'buildingmodels'
IMAGE_TAG = "${BUILDINGMODELS_VERSION}"
OFFLINE_CACHE_PATH = '/opt/offline-cache/buildingmodels'
}
options {
timeout(time: 20, unit: 'MINUTES')
buildDiscarder(logRotator(numToKeepStr: '10'))
}
stages {
stage('Checkout') {
steps {
checkout scm
}
}
stage('Prepare DEB Package Installation') {
steps {
script {
// BuildingModels DEB package (libbuildingmodels-dev) will be installed from internal SCM repository.
// No license file required - open source or contract-based licensing.
sh """
echo "BuildingModels: Will install libbuildingmodels-dev from internal SCM"
"""
}
}
}
stage('Build BuildingModels Container') {
steps {
script {
dir('external-dependencies/buildingmodels') {
sh """
docker build \
--build-arg BUILDINGMODELS_VERSION=${BUILDINGMODELS_VERSION} \
-t ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} \
.
"""
}
}
}
}
stage('Verify BuildingModels') {
steps {
script {
sh """
docker run --rm ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} bash -c '
ls -la /opt/BuildingModels/
'
"""
}
}
}
stage('Generate SBOM') {
steps {
script {
dir('external-dependencies/buildingmodels') {
sh """
mkdir -p sbom
# Set environment variables for SBOM generation
export GIT_URL="${env.GIT_URL}"
export GIT_COMMIT="${env.GIT_COMMIT}"
export BUILD_NUMBER="${env.BUILD_NUMBER}"
export DOCKERFILE_PATH="external-dependencies/buildingmodels/Dockerfile"
# Generate CycloneDX SBOM, SLSA provenance, and license report
bash ../scripts/generate-sbom.sh buildingmodels ${BUILDINGMODELS_VERSION} ./sbom
"""
}
}
}
}
stage('Push to Registry') {
steps {
script {
withCredentials([usernamePassword(
credentialsId: 'harbor-credentials',
usernameVariable: 'HARBOR_USER',
passwordVariable: 'HARBOR_PASSWORD'
)]) {
sh """
echo ${HARBOR_PASSWORD} | docker login ${HARBOR_REGISTRY} -u ${HARBOR_USER} --password-stdin
docker push ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG}
docker logout ${HARBOR_REGISTRY}
"""
}
}
}
}
}
post {
always {
cleanWs()
}
}
}
+132
View File
@@ -0,0 +1,132 @@
/*
* Jenkins Pipeline for building external dependency DEB packages
* for air-gapped environment.
*
* Packages are uploaded to SCM repository:
* http://remote-repo.sl.defence-elec.de:8081/repository/external-rpms/general
*/
pipeline {
agent any
parameters {
choice(
name: 'PACKAGE',
choices: ['avs', 'arcgis', 'tmsif', 'rti-connext-dds', 'buildingmodels', 'geographiclib', 'schusstafel', 'dtentity'],
description: 'Select package to build'
)
string(
name: 'VERSION',
defaultValue: '1.0.0',
description: 'Package version'
)
booleanParam(
name: 'UPLOAD_TO_SCM',
defaultValue: true,
description: 'Upload built package to SCM repository'
)
}
environment {
SCM_REPO = 'http://remote-repo.sl.defence-elec.de:8081/repository/external-rpms/general'
DEB_PACKAGE_DIR = "${env.WORKSPACE}/external-dependencies/deb-packages/${params.PACKAGE}"
}
stages {
stage('Checkout') {
steps {
checkout scm
}
}
stage('Validate Package Structure') {
steps {
script {
def requiredFiles = [
'debian/control',
'debian/rules',
'debian/changelog',
'debian/compat',
'debian/source/format'
]
requiredFiles.each { file ->
if (!fileExists("${DEB_PACKAGE_DIR}/${file}")) {
error "Missing required file: ${file}"
}
}
}
}
}
stage('Build DEB Package') {
steps {
dir("${DEB_PACKAGE_DIR}") {
sh '''
# Install build dependencies
sudo apt-get update
sudo apt-get install -y debhelper devscripts build-essential
# Build the package
debuild -us -uc -b
'''
}
}
}
stage('Upload to SCM') {
when {
expression { return params.UPLOAD_TO_SCM }
}
steps {
script {
// Upload to Nexus SCM repository
withCredentials([usernamePassword(
credentialsId: 'scm-repo-credentials',
usernameVariable: 'SCM_USER',
passwordVariable: 'SCM_PASS'
)]) {
sh '''
# Find the built .deb file
DEB_FILE=$(find ${DEB_PACKAGE_DIR}/.. -name "*.deb" -type f | head -1)
if [ -z "$DEB_FILE" ]; then
echo "No .deb file found!"
exit 1
fi
echo "Uploading $DEB_FILE to SCM repository..."
# Upload to Nexus repository using curl with PUT
curl -u "${SCM_USER}:${SCM_PASS}" \
--request PUT \
--upload-file "$DEB_FILE" \
"${SCM_REPO}/$(basename $DEB_FILE)" \
--fail \
--show-error
echo "Package uploaded successfully to: ${SCM_REPO}/$(basename $DEB_FILE)"
'''
}
}
}
}
stage('Archive Artifacts') {
steps {
archiveArtifacts artifacts: "${DEB_PACKAGE_DIR}/../*.deb", allowEmptyArchive: true
}
}
}
post {
always {
cleanWs()
}
success {
echo "Package ${params.PACKAGE} version ${params.VERSION} built and uploaded successfully!"
}
failure {
echo "Build failed for package ${params.PACKAGE}"
}
}
}
@@ -0,0 +1,253 @@
# DEB Package Build Pipelines
This directory contains DEB package build configurations for all 8 external dependencies used in the Legatus project.
## Overview
All external dependencies are packaged as native DEB packages (format: 3.0 native) and stored in the internal SCM repository. During CI/CD, packages are installed via apt instead of copying files into Docker containers. This approach provides:
- **Reproducible builds**: Standard Ubuntu packaging with debhelper
- **Version management**: Semantic versioning with proper dependencies
- **Air-gapped support**: Packages stored in internal SCM repository at `http://remote-repo.sl.defence-elec.de:8081/repository/external-rpms/general/`
- **Compliance**: License files included in packages where required
- **Maintainability**: Standard Ubuntu package management tools
- **Clean Dockerfiles**: No COPY commands for proprietary dependencies
## Directory Structure
```
deb-packages/
├── README.md # This file
├── Jenkinsfile # Jenkins pipeline for building and uploading
├── avs/ # AVS DEB package
│ ├── debian/ # Debian control files
│ │ ├── control # Package metadata and dependencies
│ │ ├── rules # Build rules with override_dh_auto_install
│ │ ├── changelog # Version history
│ │ └── source/
│ │ └── format # Package format (3.0 native)
├── arcgis/ # ArcGIS Runtime SDK DEB package
├── buildingmodels/ # BuildingModels DEB package
├── geographiclib/ # GeographicLib DEB package
├── schusstafel/ # Schusstafel DEB package
├── dtentity/ # dtEntity DEB package
├── rti-connext-dds/ # RTI Connext DDS DEB package (includes license)
└── tmsif/ # tmsif DEB package
```
## Package Names
| Directory | DEB Package Name | Version | Description |
|-----------|------------------|---------|-------------|
| avs | `libavs-dev` | 1.0.0 | AVS library development files |
| arcgis | `libarcgis-dev` | 1.0.0 | ArcGIS Runtime SDK for Qt |
| buildingmodels | `libbuildingmodels-dev` | 1.0.0 | Building models library |
| geographiclib | `libgeographiclib-dev` | 1.0.0 | Geographic calculations library |
| schusstafel | `libschusstafel-dev` | 1.0.0 | Schusstafel library |
| dtentity | `libdtentity-dev` | 1.0.0 | dtEntity game engine |
| rti-connext-dds | `librti-connext-dds-7.7.0-dev` | 7.7.0 | RTI Connext DDS middleware (includes license) |
| tmsif | `libtmsif-dev` | 1.0.0 | TMSIF library |
## Building DEB Packages
### Prerequisites
- Ubuntu 26.04 build environment
- `devscripts` package
- `debhelper` (>= 12) package
- Build dependencies for each package (see `debian/control`)
### Manual Build
```bash
cd external-dependencies/deb-packages/geographiclib
debuild -us -uc -b
```
This creates a binary-only DEB package without signing in the parent directory.
### Build Scripts
**Build single package:**
```bash
cd external-dependencies/deb-packages
./build-package.sh geographiclib 1.0.0
```
**Build all packages:**
```bash
cd external-dependencies/deb-packages
./build-all-packages.sh
```
Build output is stored in `external-dependencies/deb-packages/output/`
### Jenkins Pipeline
Use the Jenkinsfile to build and upload packages:
```bash
# In Jenkins, select package name and version
# Pipeline will build and upload to SCM repository automatically
```
## Package Structure
### Control File Example (AVS)
```
Source: avs
Section: libs
Priority: optional
Maintainer: Legatus Team <legatus@defence-elec.de>
Build-Depends: debhelper (>= 12), qt6-base-dev, ...
Package: libavs-dev
Architecture: amd64
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: AVS library development files
Development files and headers for the AVS library
used in the Legatus project.
Vcs-Browser: https://internal-repo.sl.defence-elec.de
Vcs-Git: https://internal-repo.sl.defence-elec.de/git/avs.git
```
### Installation Path
All packages install to `/opt/{DependencyName}` directory structure:
- Installation root: `/opt/{DependencyName}/`
- Headers: `/opt/{DependencyName}/include/`
- Libraries: `/opt/{DependencyName}/lib/`
- CMake configs: `/opt/{DependencyName}/cmake/`
- Licenses: `/opt/{DependencyName}/` (RTI) or `/usr/share/doc/<package>/copyright`
## Uploading to SCM Repository
### Jenkins Pipeline
The Jenkinsfile automates building and uploading:
```groovy
// Parameters:
// - PACKAGE_NAME: avs, arcgis, buildingmodels, etc.
// - PACKAGE_VERSION: 1.0.0
// - SCM_URL: http://remote-repo.sl.defence-elec.de:8081/repository/external-rpms/general/
// - CREDENTIALS_ID: Jenkins credentials ID for SCM authentication
pipeline {
agent any
parameters {
choice(name: 'PACKAGE_NAME', choices: ['avs', 'arcgis', 'buildingmodels', 'geographiclib', 'schusstafel', 'dtentity', 'rti-connext-dds', 'tmsif'])
string(name: 'PACKAGE_VERSION', defaultValue: '1.0.0')
}
stages {
stage('Build') {
steps {
sh "cd external-dependencies/deb-packages/\${PACKAGE_NAME} && debuild -us -uc -b"
}
}
stage('Upload') {
steps {
sh "curl -u \${SCM_CREDENTIALS} --upload-file ../lib\${PACKAGE_NAME}-dev_\${PACKAGE_VERSION}_amd64.deb \${SCM_URL}"
}
}
}
}
```
### Manual Upload
```bash
curl -u <username>:<password> \
--upload-file libavs-dev_1.0.0_amd64.deb \
http://remote-repo.sl.defence-elec.de:8081/repository/external-rpms/general/
```
## License Handling
### RTI Connext DDS
The RTI package includes the commercial license file:
- `rti_license.dat` included in DEB package at `/opt/rti_connext_dds-7.7.0/rti_license.dat`
- DEB package installs to `/opt/rti_connext_dds-7.7.0/`
- FlexLM license validated at runtime
### ArcGIS Runtime SDK
- Map-specific licenses embedded in .ini files
- Licenses included in DEB package
- Located in `/opt/ArcGIS/MapsSDK_Qt_300.0.0/`
### AVS & tmsif
- Customer lifetime license contracts
- No license files required in DEB package
- License contracts maintained separately by customer
### Other Packages
- Open source or internal licenses
- Standard copyright file in `/usr/share/doc/<package>/copyright`
## Verification
After installation, verify packages:
```bash
# Check installed packages
dpkg -l | grep libavs-dev
# List installed files
dpkg -L libavs-dev
# Check package info
apt-cache show libavs-dev
# Verify installation path
ls -la /opt/AVS/
# Verify dependencies
ldd /opt/AVS/lib/libavs.so
```
## Usage in Dockerfiles
Example Dockerfile using DEB packages from SCM:
```dockerfile
FROM ubuntu:26.04
# Configure APT repository for internal SCM
RUN echo "deb [trusted=yes] http://remote-repo.sl.defence-elec.de:8081/repository/external-rpms/general/ /" > /etc/apt/sources.list.d/scm.list
# Install all external dependencies
RUN apt-get update && apt-get install -y \
libavs-dev \
libarcgis-dev \
libbuildingmodels-dev \
libgeographiclib-dev \
libschusstafel-dev \
libdtentity-dev \
librti-connext-dds-7.7.0-dev \
libtmsif-dev \
&& rm -rf /var/lib/apt/lists/*
# Verify installation
RUN ls -la /opt/AVS /opt/ArcGIS /opt/RTI
```
## Security Considerations
- **Include license files** in DEB packages where required (RTI, ArcGIS)
- **Sign packages** with internal signing key before distribution
- **Verify checksums** after upload to repository
- **Maintain chain of custody** for proprietary packages
- **Use HTTPS** for SCM repository access in production
## References
- [Ubuntu Packaging Guide](https://ubuntu.com/server/docs/packaging)
- [Debian New Maintainers' Guide](https://www.debian.org/doc/manuals/maint-guide/)
- [Internal SCM Repository](https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general)
- [Main README](../README.md)
@@ -0,0 +1,76 @@
#!/bin/bash
# ArcGIS DEB Package Build Script
# Builds libarcgis-maps-sdk-qt-dev DEB package for internal SCM repository
set -e
PACKAGE_NAME="libarcgis-maps-sdk-qt-dev"
VERSION="300.0.0"
ARCHITECTURE="amd64"
MAINTAINER="Legatus Team <legatus@defence-elec.de>"
DESCRIPTION="ArcGIS Maps SDK for Qt - development files (embedded ini-file licenses)"
# Create package structure
DEB_DIR="deb-package"
rm -rf "$DEB_DIR"
mkdir -p "$DEB_DIR/DEBIAN"
mkdir -p "$DEB_DIR/opt/ArcGIS/MapsSDK_Qt_300.0.0"
mkdir -p "$DEB_DIR/opt/offline-cache/arcgis"
# Copy ArcGIS files from external/ArcGIS
if [ -d "../../external/ArcGIS" ]; then
cp -r ../../external/ArcGIS/* "$DEB_DIR/opt/ArcGIS/MapsSDK_Qt_300.0.0/"
fi
# Create control file
cat > "$DEB_DIR/DEBIAN/control" << EOF
Package: $PACKAGE_NAME
Version: $VERSION
Architecture: $ARCHITECTURE
Maintainer: $MAINTAINER
Depends: libqt6core6, libqt6gui6, libqt6widgets6, libqt6positioning6
Section: libdevel
Priority: optional
Description: $DESCRIPTION
ArcGIS Maps SDK for Qt (version 300.0.0) for Legatus.
.
License: Embedded ini-file licenses
Map-specific licenses embedded in Lts/Viewer/SituationMap/Map/*.ini files.
EOF
# Create postinst script
cat > "$DEB_DIR/DEBIAN/postinst" << 'EOF'
#!/bin/bash
set -e
echo "ArcGIS DEB package installed successfully"
echo "License: Embedded ini-file licenses in Lts/Viewer/SituationMap/Map/*.ini"
# Set permissions
chmod -R 755 /opt/ArcGIS
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postinst"
# Create postrm script
cat > "$DEB_DIR/DEBIAN/postrm" << 'EOF'
#!/bin/bash
set -e
echo "ArcGIS DEB package removed"
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postrm"
# Build DEB package
echo "Building DEB package: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd "$DEB_DIR"
dpkg-deb --build . "../${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd ..
echo "DEB package created: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
echo "Size: $(du -h ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb | cut -f1)"
@@ -0,0 +1,7 @@
libarcgis-maps-sdk-qt-dev (300.0.0) stable; urgency=medium
* Initial release for air-gapped environment
* ArcGIS Maps SDK for Qt with embedded ini-file licenses
* Installs to /opt/ArcGIS
-- Legatus Team <legatus@defence-elec.de> Mon, 01 Jan 2024 00:00:00 +0000
@@ -0,0 +1 @@
12
@@ -0,0 +1,22 @@
Source: libarcgis-maps-sdk-qt-dev
Section: contrib/devel
Priority: optional
Maintainer: Legatus Team <legatus@defence-elec.de>
Build-Depends: debhelper (>= 12), qt6-base-dev
Standards-Version: 4.6.0
Vcs-Browser: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
Vcs-Git: https://internal-repo.sl.defence-elec.de/external-rpms/general/libarcgis-maps-sdk-qt-dev.git
Package: libarcgis-maps-sdk-qt-dev
Architecture: amd64
Depends: libqt6core6, libqt6gui6, libqt6widgets6, ${shlibs:Depends}, ${misc:Depends}
Description: ArcGIS Maps SDK for Qt - development files (embedded ini-file licenses)
ArcGIS Maps SDK for Qt 300.0.0 for Legatus.
.
License: Embedded ini-file licenses
Map-specific licenses embedded in Lts/Viewer/SituationMap/Map/*.ini files.
Customer has lifetime license contract.
.
This package contains the development files for ArcGIS Maps SDK for Qt.
.
Available from SCM: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
@@ -0,0 +1,17 @@
#!/usr/bin/make -f
# Allow override of source path for building in CI/CD or local environments
# Default: /opt (production build machine)
# Can be overridden via DEB_BUILD_OPT_PATH environment variable
OPT_BASE ?= /opt
%:
dh $@
override_dh_auto_install:
dh_auto_install
install -d debian/libarcgis-dev/opt/ArcGIS
cp -r $(OPT_BASE)/ArcGIS/* debian/libarcgis-dev/opt/ArcGIS/
override_dh_strip:
dh_strip --no-automatic-dbgsym
@@ -0,0 +1 @@
3.0 (native)
@@ -0,0 +1,76 @@
#!/bin/bash
# AVS DEB Package Build Script
# Builds libavs-dev DEB package for internal SCM repository
set -e
PACKAGE_NAME="libavs-dev"
VERSION="1.0.0"
ARCHITECTURE="amd64"
MAINTAINER="Legatus Team <legatus@defence-elec.de>"
DESCRIPTION="AVS library - development files (contract-based license)"
# Create package structure
DEB_DIR="deb-package"
rm -rf "$DEB_DIR"
mkdir -p "$DEB_DIR/DEBIAN"
mkdir -p "$DEB_DIR/opt/AVS"
mkdir -p "$DEB_DIR/opt/offline-cache/avs"
# Copy AVS files from external/AVS
if [ -d "../../external/AVS" ]; then
cp -r ../../external/AVS/* "$DEB_DIR/opt/AVS/"
fi
# Create control file
cat > "$DEB_DIR/DEBIAN/control" << EOF
Package: $PACKAGE_NAME
Version: $VERSION
Architecture: $ARCHITECTURE
Maintainer: $MAINTAINER
Depends: libqt6core6, libqt6gui6, libqt6widgets6
Section: libdevel
Priority: optional
Description: $DESCRIPTION
AVS (Application Visualization System) library for Legatus.
.
License: Contract-based (no file required)
Customer has lifetime license contract.
EOF
# Create postinst script
cat > "$DEB_DIR/DEBIAN/postinst" << 'EOF'
#!/bin/bash
set -e
echo "AVS DEB package installed successfully"
echo "License: Contract-based (no file required)"
# Set permissions
chmod -R 755 /opt/AVS
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postinst"
# Create postrm script
cat > "$DEB_DIR/DEBIAN/postrm" << 'EOF'
#!/bin/bash
set -e
echo "AVS DEB package removed"
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postrm"
# Build DEB package
echo "Building DEB package: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd "$DEB_DIR"
dpkg-deb --build . "../${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd ..
echo "DEB package created: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
echo "Size: $(du -h ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb | cut -f1)"
@@ -0,0 +1,7 @@
libavs-dev (1.0.0) stable; urgency=medium
* Initial release for air-gapped environment
* AVS library with contract-based lifetime license
* Installs to /opt/AVS
-- Legatus Team <legatus@defence-elec.de> Mon, 01 Jan 2024 00:00:00 +0000
@@ -0,0 +1 @@
12
@@ -0,0 +1,21 @@
Source: libavs-dev
Section: contrib/devel
Priority: optional
Maintainer: Legatus Team <legatus@defence-elec.de>
Build-Depends: debhelper (>= 12), qt6-base-dev
Standards-Version: 4.6.0
Vcs-Browser: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
Vcs-Git: https://internal-repo.sl.defence-elec.de/external-rpms/general/libavs-dev.git
Package: libavs-dev
Architecture: amd64
Depends: libqt6core6, libqt6gui6, libqt6widgets6, ${shlibs:Depends}, ${misc:Depends}
Description: AVS library - development files (contract-based license)
AVS (Application Visualization System) library for Legatus.
.
License: Contract-based (no file required)
Customer has lifetime license contract.
.
This package contains the development files for AVS library.
.
Available from SCM: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
@@ -0,0 +1,17 @@
#!/usr/bin/make -f
# Allow override of source path for building in CI/CD or local environments
# Default: /opt (production build machine)
# Can be overridden via DEB_BUILD_OPT_PATH environment variable
OPT_BASE ?= /opt
%:
dh $@
override_dh_auto_install:
dh_auto_install
install -d debian/libavs-dev/opt/AVS
cp -r $(OPT_BASE)/AVS/* debian/libavs-dev/opt/AVS/
override_dh_strip:
dh_strip --no-automatic-dbgsym
@@ -0,0 +1 @@
3.0 (native)
+51
View File
@@ -0,0 +1,51 @@
#!/bin/bash
# Build all DEB packages for external dependencies
# Usage: ./build-all-packages.sh
set -e
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
PACKAGES=("avs" "arcgis" "buildingmodels" "geographiclib" "schusstafel" "dtentity" "rti-connext-dds" "tmsif")
OUTPUT_DIR="${SCRIPT_DIR}/output"
VERSION="1.0.0"
echo "========================================"
echo "DEB Package Build Script"
echo "========================================"
echo ""
# Create output directory
mkdir -p "${OUTPUT_DIR}"
# Build each package
for pkg in "${PACKAGES[@]}"; do
echo "Building package: ${pkg}"
echo "----------------------------------------"
# Call build-package.sh for each package
"${SCRIPT_DIR}/build-package.sh" "${pkg}" "${VERSION}"
# Move generated .deb files to output directory
# Extract package name from control file
pkg_name=$(grep -m1 "^Package:" "${SCRIPT_DIR}/${pkg}/debian/control" | awk '{print $2}')
if [ -z "${pkg_name}" ]; then
pkg_name="lib${pkg}-dev"
fi
if [ -f "${SCRIPT_DIR}/${pkg_name}_${VERSION}_amd64.deb" ]; then
mv "${SCRIPT_DIR}/${pkg_name}_${VERSION}_amd64.deb" "${OUTPUT_DIR}/"
echo "✓ Built: ${pkg_name}_${VERSION}_amd64.deb"
fi
echo ""
done
echo "========================================"
echo "Build Summary"
echo "========================================"
echo ""
echo "Output directory: ${OUTPUT_DIR}"
echo ""
ls -lh "${OUTPUT_DIR}"/*.deb 2>/dev/null || echo "No .deb files found"
echo ""
echo "Build complete!"
+206
View File
@@ -0,0 +1,206 @@
#!/bin/bash
# Build a single DEB package
# Usage: ./build-package.sh <package-dir-name> [version]
#
# Package directory names and their corresponding DEB package names:
# arcgis -> libarcgis-maps-sdk-qt-dev
# avs -> libavs-dev
# buildingmodels -> libbuildingmodels-dev
# dtentity -> libdtentity-dev
# geographiclib -> libgeographiclib-dev
# rti-connext-dds -> librti-connext-dds-7.7.0-dev
# schusstafel -> libschusstafel-dev
# tmsif -> libtmsif-dev
set -e
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
PACKAGE_DIR_NAME="$1"
VERSION="${2:-1.0.0}"
if [ -z "${PACKAGE_DIR_NAME}" ]; then
echo "Usage: ./build-package.sh <package-dir-name> [version]"
echo "Example: ./build-package.sh geographiclib 1.0.0"
echo ""
echo "Available package directories:"
echo " arcgis, avs, buildingmodels, dtentity, geographiclib, rti-connext-dds, schusstafel, tmsif"
exit 1
fi
PACKAGE_DIR="${SCRIPT_DIR}/${PACKAGE_DIR_NAME}"
if [ ! -d "${PACKAGE_DIR}/debian" ]; then
echo "ERROR: Package directory not found: ${PACKAGE_DIR}"
exit 1
fi
# Extract actual package name from control file
PACKAGE_NAME=$(grep "^Package:" "${PACKAGE_DIR}/debian/control" | cut -d' ' -f2)
if [ -z "${PACKAGE_NAME}" ]; then
echo "ERROR: Could not extract package name from control file"
exit 1
fi
echo "Package directory: ${PACKAGE_DIR_NAME}"
echo "DEB package name: ${PACKAGE_NAME}"
# Determine expected /opt path and source path based on package directory
case "${PACKAGE_DIR_NAME}" in
arcgis)
OPT_PATH="/opt/ArcGIS/MapsSDK_Qt_300.0.0"
SRC_PATH="${SCRIPT_DIR}/../../external/ArcGIS"
;;
avs)
OPT_PATH="/opt/AVS"
SRC_PATH="${SCRIPT_DIR}/../../external/AVS"
;;
buildingmodels)
OPT_PATH="/opt/BuildingModels"
SRC_PATH="${SCRIPT_DIR}/../../external/BuildingModels"
;;
dtentity)
OPT_PATH="/opt/dtEntity"
SRC_PATH="${SCRIPT_DIR}/../../external/dtEntity"
;;
geographiclib)
OPT_PATH="/opt/GeographicLib"
SRC_PATH="${SCRIPT_DIR}/../../external/GeographicLib"
;;
rti-connext-dds)
OPT_PATH="/opt/rti_connext_dds-7.7.0"
SRC_PATH="${SCRIPT_DIR}/../../external/rti_connext_dds-7.7.0"
;;
schusstafel)
OPT_PATH="/opt/Schusstafel"
SRC_PATH="${SCRIPT_DIR}/../../external/Schusstafel"
;;
tmsif)
OPT_PATH="/opt/tmsif"
SRC_PATH="${SCRIPT_DIR}/../../external/tmsif"
;;
*)
echo "ERROR: Unknown package directory: ${PACKAGE_DIR_NAME}"
exit 1
;;
esac
echo "Source path: ${SRC_PATH}"
echo "Target /opt path: ${OPT_PATH}"
echo "========================================"
echo "Building DEB Package: ${PACKAGE_NAME}"
echo "Version: ${VERSION}"
echo "========================================"
echo ""
# Check if dependency exists in source location
if [ ! -d "${SRC_PATH}" ]; then
echo "ERROR: Dependency not found at ${SRC_PATH}"
echo ""
echo "Ensure the dependency is present in the external directory."
exit 1
fi
# Create temporary /opt structure for build
TEMP_OPT_BASE="/tmp/deb-build-opt"
TEMP_OPT="${TEMP_OPT_BASE}${OPT_PATH}"
mkdir -p "${TEMP_OPT}"
echo "Setting up temporary /opt structure..."
cp -r "${SRC_PATH}"/* "${TEMP_OPT}/"
# For RTI, also copy license file if it exists
if [ "${PACKAGE_DIR_NAME}" = "rti-connext-dds" ]; then
LICENSE_FILE="${SCRIPT_DIR}/../../rti_license.dat"
if [ -f "${LICENSE_FILE}" ]; then
echo "Including RTI license file in build..."
cp "${LICENSE_FILE}" "${TEMP_OPT}/rti_license.dat"
else
echo "WARNING: RTI license file not found at ${LICENSE_FILE}"
echo "The package will be built without the license file."
fi
fi
echo "Temporary /opt structure created at: ${TEMP_OPT}"
echo ""
cd "${PACKAGE_DIR}"
# Clean previous builds
echo "Cleaning previous build artifacts..."
rm -rf debian/.debhelper debian/*.debhelper debian/files debian/substvars 2>/dev/null || true
rm -f ../${PACKAGE_NAME}_*.deb 2>/dev/null || true
# Build package with OPT_BASE environment variable
echo "Building package..."
export DEB_BUILD_OPT_PATH="${TEMP_OPT_BASE}"
echo "Using OPT_BASE: ${DEB_BUILD_OPT_PATH}"
# Create package build directory structure
PKG_BUILD_DIR="debian/${PACKAGE_NAME}"
rm -rf "${PKG_BUILD_DIR}"
mkdir -p "${PKG_BUILD_DIR}/opt"
# Copy files from temporary /opt to package structure
echo "Copying files to package structure..."
cp -r "${TEMP_OPT_BASE}/${DIR_NAME}"/* "${PKG_BUILD_DIR}/"
# Create DEBIAN control directory
mkdir -p "${PKG_BUILD_DIR}/DEBIAN"
# Generate control file
cat > "${PKG_BUILD_DIR}/DEBIAN/control" << EOF
Package: ${PACKAGE_NAME}
Version: ${VERSION}
Section: devel
Priority: optional
Architecture: amd64
Maintainer: Legatus Team <legatus@defence-elec.de>
Description: ${PACKAGE_NAME} for air-gapped environment
Built from source in ./external/ directory
EOF
# Generate changelog
cat > "${PKG_BUILD_DIR}/DEBIAN/changelog" << EOF
${PACKAGE_NAME} (${VERSION}) stable; urgency=medium
* Initial release for air-gapped environment
* Built from ./external/ source directory
-- Legatus Team <legatus@defence-elec.de> $(date -R)
EOF
# Set proper permissions
chmod -R 755 "${PKG_BUILD_DIR}/DEBIAN"
find "${PKG_BUILD_DIR}/opt" -type d -exec chmod 755 {} \;
find "${PKG_BUILD_DIR}/opt" -type f -exec chmod 644 {} \;
# Build the package
echo "Creating DEB package..."
dpkg-deb --root-owner-group --build "${PKG_BUILD_DIR}" ../${PACKAGE_NAME}_${VERSION}_amd64.deb
# Clean up temporary structure
echo "Cleaning up temporary /opt structure..."
rm -rf "${TEMP_OPT_BASE}"
# Clean up build directory
rm -rf "${PKG_BUILD_DIR}"
# Verify output
DEB_FILE="${SCRIPT_DIR}/${PACKAGE_NAME}_${VERSION}_amd64.deb"
if [ -f "${DEB_FILE}" ]; then
echo ""
echo "========================================"
echo "Build Successful!"
echo "========================================"
echo "Package: ${DEB_FILE}"
echo "Size: $(du -h "${DEB_FILE}" | cut -f1)"
echo ""
echo "Package contents:"
dpkg -c "${DEB_FILE}" | head -20
echo ""
echo "To upload to SCM repository:"
echo " curl -u <credentials> --upload-file ${DEB_FILE} http://remote-repo.sl.defence-elec.de:8081/repository/external-rpms/general/"
else
echo "ERROR: Package file not found: ${DEB_FILE}"
exit 1
fi
@@ -0,0 +1,74 @@
#!/bin/bash
# BuildingModels DEB Package Build Script
# Builds libbuildingmodels-dev DEB package for internal SCM repository
set -e
PACKAGE_NAME="libbuildingmodels-dev"
VERSION="1.0.0"
ARCHITECTURE="amd64"
MAINTAINER="Legatus Team <legatus@defence-elec.de>"
DESCRIPTION="BuildingModels library - development files"
# Create package structure
DEB_DIR="deb-package"
rm -rf "$DEB_DIR"
mkdir -p "$DEB_DIR/DEBIAN"
mkdir -p "$DEB_DIR/opt/BuildingModels"
mkdir -p "$DEB_DIR/opt/offline-cache/buildingmodels"
# Copy BuildingModels files from external/BuildingModels
if [ -d "../../external/BuildingModels" ]; then
cp -r ../../external/BuildingModels/* "$DEB_DIR/opt/BuildingModels/"
fi
# Create control file
cat > "$DEB_DIR/DEBIAN/control" << EOF
Package: $PACKAGE_NAME
Version: $VERSION
Architecture: $ARCHITECTURE
Maintainer: $MAINTAINER
Depends: libqt6core6, libqt6gui6, libqt6widgets6
Section: libdevel
Priority: optional
Description: $DESCRIPTION
BuildingModels library for Legatus.
.
License: Standard (no special license file required)
EOF
# Create postinst script
cat > "$DEB_DIR/DEBIAN/postinst" << 'EOF'
#!/bin/bash
set -e
echo "BuildingModels DEB package installed successfully"
# Set permissions
chmod -R 755 /opt/BuildingModels
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postinst"
# Create postrm script
cat > "$DEB_DIR/DEBIAN/postrm" << 'EOF'
#!/bin/bash
set -e
echo "BuildingModels DEB package removed"
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postrm"
# Build DEB package
echo "Building DEB package: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd "$DEB_DIR"
dpkg-deb --build . "../${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd ..
echo "DEB package created: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
echo "Size: $(du -h ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb | cut -f1)"
@@ -0,0 +1,7 @@
libbuildingmodels-dev (1.0.0) stable; urgency=medium
* Initial release for air-gapped environment
* BuildingModels library with standard license
* Installs to /opt/BuildingModels
-- Legatus Team <legatus@defence-elec.de> Mon, 01 Jan 2024 00:00:00 +0000
@@ -0,0 +1 @@
12
@@ -0,0 +1,18 @@
Source: libbuildingmodels-dev
Section: libdevel
Priority: optional
Maintainer: Legatus Team <legatus@defence-elec.de>
Build-Depends: debhelper (>= 12), qt6-base-dev
Standards-Version: 4.6.0
Vcs-Browser: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
Vcs-Git: https://internal-repo.sl.defence-elec.de/git/external/buildingmodels.git
Package: libbuildingmodels-dev
Architecture: amd64
Depends: libqt6core6, libqt6gui6, libqt6widgets6, ${shlibs:Depends}, ${misc:Depends}
Description: BuildingModels library - development files
BuildingModels library for Legatus.
.
License: Standard (no special requirements)
.
This package contains the development files for BuildingModels library.
@@ -0,0 +1,17 @@
#!/usr/bin/make -f
# Allow override of source path for building in CI/CD or local environments
# Default: /opt (production build machine)
# Can be overridden via DEB_BUILD_OPT_PATH environment variable
OPT_BASE ?= /opt
%:
dh $@
override_dh_auto_install:
dh_auto_install
install -d debian/libbuildingmodels-dev/opt/BuildingModels
cp -r $(OPT_BASE)/BuildingModels/* debian/libbuildingmodels-dev/opt/BuildingModels/
override_dh_strip:
dh_strip --no-automatic-dbgsym
@@ -0,0 +1 @@
3.0 (native)
@@ -0,0 +1,74 @@
#!/bin/bash
# dtEntity DEB Package Build Script
# Builds libdtentity-dev DEB package for internal SCM repository
set -e
PACKAGE_NAME="libdtentity-dev"
VERSION="1.0.0"
ARCHITECTURE="amd64"
MAINTAINER="Legatus Team <legatus@defence-elec.de>"
DESCRIPTION="dtEntity game engine - development files"
# Create package structure
DEB_DIR="deb-package"
rm -rf "$DEB_DIR"
mkdir -p "$DEB_DIR/DEBIAN"
mkdir -p "$DEB_DIR/opt/dtEntity"
mkdir -p "$DEB_DIR/opt/offline-cache/dtentity"
# Copy dtEntity files from external/dtEntity
if [ -d "../../external/dtEntity" ]; then
cp -r ../../external/dtEntity/* "$DEB_DIR/opt/dtEntity/"
fi
# Create control file
cat > "$DEB_DIR/DEBIAN/control" << EOF
Package: $PACKAGE_NAME
Version: $VERSION
Architecture: $ARCHITECTURE
Maintainer: $MAINTAINER
Depends: libqt6core6, libqt6gui6, libqt6widgets6, libstdc++6
Section: libdevel
Priority: optional
Description: $DESCRIPTION
dtEntity game engine for Legatus.
.
License: Open source (no special license file required)
EOF
# Create postinst script
cat > "$DEB_DIR/DEBIAN/postinst" << 'EOF'
#!/bin/bash
set -e
echo "dtEntity DEB package installed successfully"
# Set permissions
chmod -R 755 /opt/dtEntity
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postinst"
# Create postrm script
cat > "$DEB_DIR/DEBIAN/postrm" << 'EOF'
#!/bin/bash
set -e
echo "dtEntity DEB package removed"
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postrm"
# Build DEB package
echo "Building DEB package: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd "$DEB_DIR"
dpkg-deb --build . "../${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd ..
echo "DEB package created: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
echo "Size: $(du -h ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb | cut -f1)"
@@ -0,0 +1,7 @@
libdtentity-dev (1.0.0) stable; urgency=medium
* Initial release for air-gapped environment
* dtEntity game engine with open source/contract license
* Installs to /opt/dtEntity
-- Legatus Team <legatus@defence-elec.de> Mon, 01 Jan 2024 00:00:00 +0000
@@ -0,0 +1 @@
12
@@ -0,0 +1,18 @@
Source: libdtentity-dev
Section: libdevel
Priority: optional
Maintainer: Legatus Team <legatus@defence-elec.de>
Build-Depends: debhelper (>= 12), qt6-base-dev
Standards-Version: 4.6.0
Vcs-Browser: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
Vcs-Git: https://internal-repo.sl.defence-elec.de/git/external/dtentity.git
Package: libdtentity-dev
Architecture: amd64
Depends: libqt6core6, libqt6gui6, libqt6widgets6, ${shlibs:Depends}, ${misc:Depends}
Description: dtEntity game engine - development files
dtEntity game engine for Legatus.
.
License: Open source / contract-based (no file required)
.
This package contains the development files for dtEntity game engine.
@@ -0,0 +1,17 @@
#!/usr/bin/make -f
# Allow override of source path for building in CI/CD or local environments
# Default: /opt (production build machine)
# Can be overridden via DEB_BUILD_OPT_PATH environment variable
OPT_BASE ?= /opt
%:
dh $@
override_dh_auto_install:
dh_auto_install
install -d debian/libdtentity-dev/opt/dtEntity
cp -r $(OPT_BASE)/dtEntity/* debian/libdtentity-dev/opt/dtEntity/
override_dh_strip:
dh_strip --no-automatic-dbgsym
@@ -0,0 +1 @@
3.0 (native)
@@ -0,0 +1,74 @@
#!/bin/bash
# GeographicLib DEB Package Build Script
# Builds libgeographiclib-dev DEB package for internal SCM repository
set -e
PACKAGE_NAME="libgeographiclib-dev"
VERSION="2.3"
ARCHITECTURE="amd64"
MAINTAINER="Legatus Team <legatus@defence-elec.de>"
DESCRIPTION="GeographicLib library - development files"
# Create package structure
DEB_DIR="deb-package"
rm -rf "$DEB_DIR"
mkdir -p "$DEB_DIR/DEBIAN"
mkdir -p "$DEB_DIR/opt/GeographicLib"
mkdir -p "$DEB_DIR/opt/offline-cache/geographiclib"
# Copy GeographicLib files from external/GeographicLib
if [ -d "../../external/GeographicLib" ]; then
cp -r ../../external/GeographicLib/* "$DEB_DIR/opt/GeographicLib/"
fi
# Create control file
cat > "$DEB_DIR/DEBIAN/control" << EOF
Package: $PACKAGE_NAME
Version: $VERSION
Architecture: $ARCHITECTURE
Maintainer: $MAINTAINER
Depends: libc6, libgcc1, libstdc++6
Section: libdevel
Priority: optional
Description: $DESCRIPTION
GeographicLib library for geodesic calculations.
.
License: MIT/X11 (open source)
EOF
# Create postinst script
cat > "$DEB_DIR/DEBIAN/postinst" << 'EOF'
#!/bin/bash
set -e
echo "GeographicLib DEB package installed successfully"
# Set permissions
chmod -R 755 /opt/GeographicLib
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postinst"
# Create postrm script
cat > "$DEB_DIR/DEBIAN/postrm" << 'EOF'
#!/bin/bash
set -e
echo "GeographicLib DEB package removed"
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postrm"
# Build DEB package
echo "Building DEB package: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd "$DEB_DIR"
dpkg-deb --build . "../${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd ..
echo "DEB package created: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
echo "Size: $(du -h ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb | cut -f1)"
@@ -0,0 +1,7 @@
libgeographiclib-dev (2.3) stable; urgency=medium
* Initial release for air-gapped environment
* GeographicLib library with MIT-style license
* Installs to /opt/GeographicLib
-- Legatus Team <legatus@defence-elec.de> Mon, 01 Jan 2024 00:00:00 +0000
@@ -0,0 +1,18 @@
Source: libgeographiclib-dev
Section: libdevel
Priority: optional
Maintainer: Legatus Team <legatus@defence-elec.de>
Build-Depends: debhelper (>= 12)
Standards-Version: 4.6.0
Vcs-Browser: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
Vcs-Git: https://internal-repo.sl.defence-elec.de/git/external/geographiclib.git
Package: libgeographiclib-dev
Architecture: amd64
Depends: libgeographiclib23, ${shlibs:Depends}, ${misc:Depends}
Description: GeographicLib library - development files
GeographicLib library for Legatus.
.
License: MIT-style open source
.
This package contains the development files for GeographicLib library.
@@ -0,0 +1,17 @@
#!/usr/bin/make -f
# Allow override of source path for building in CI/CD or local environments
# Default: /opt (production build machine)
# Can be overridden via DEB_BUILD_OPT_PATH environment variable
OPT_BASE ?= /opt
%:
dh $@
override_dh_auto_install:
dh_auto_install
install -d debian/libgeographiclib-dev/opt/GeographicLib
cp -r $(OPT_BASE)/GeographicLib/* debian/libgeographiclib-dev/opt/GeographicLib/
override_dh_strip:
dh_strip --no-automatic-dbgsym
@@ -0,0 +1,7 @@
libgeographiclib-dev (2.3) stable; urgency=medium
* Initial release for air-gapped environment
* GeographicLib library with MIT-style license
* Installs to /opt/GeographicLib
-- Legatus Team <legatus@defence-elec.de> Mon, 01 Jan 2024 00:00:00 +0000
@@ -0,0 +1 @@
12
@@ -0,0 +1,18 @@
Source: libgeographiclib-dev
Section: libdevel
Priority: optional
Maintainer: Legatus Team <legatus@defence-elec.de>
Build-Depends: debhelper (>= 12)
Standards-Version: 4.6.0
Vcs-Browser: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
Vcs-Git: https://internal-repo.sl.defence-elec.de/git/external/geographiclib.git
Package: libgeographiclib-dev
Architecture: amd64
Depends: libgeographiclib23, ${shlibs:Depends}, ${misc:Depends}
Description: GeographicLib library - development files
GeographicLib library for Legatus.
.
License: MIT-style open source
.
This package contains the development files for GeographicLib library.
@@ -0,0 +1,17 @@
#!/usr/bin/make -f
# Allow override of source path for building in CI/CD or local environments
# Default: /opt (production build machine)
# Can be overridden via DEB_BUILD_OPT_PATH environment variable
OPT_BASE ?= /opt
%:
dh $@
override_dh_auto_install:
dh_auto_install
install -d debian/libgeographiclib-dev/opt/GeographicLib
cp -r $(OPT_BASE)/GeographicLib/* debian/libgeographiclib-dev/opt/GeographicLib/
override_dh_strip:
dh_strip --no-automatic-dbgsym
@@ -0,0 +1 @@
3.0 (native)
@@ -0,0 +1,84 @@
#!/bin/bash
# RTI Connext DDS DEB Package Build Script
# Builds librti-connext-dds-7.7.0-dev DEB package for internal SCM repository
set -e
PACKAGE_NAME="librti-connext-dds-7.7.0-dev"
VERSION="7.7.0"
ARCHITECTURE="amd64"
MAINTAINER="Legatus Team <legatus@defence-elec.de>"
DESCRIPTION="RTI Connext DDS 7.7.0 Pro - development files (commercial license)"
# Create package structure
DEB_DIR="deb-package"
rm -rf "$DEB_DIR"
mkdir -p "$DEB_DIR/DEBIAN"
mkdir -p "$DEB_DIR/opt/rti_connext_dds-7.7.0"
mkdir -p "$DEB_DIR/opt/offline-cache/rti"
# Copy RTI files from external/rti_connext_dds-7.7.0
if [ -d "../../external/rti_connext_dds-7.7.0" ]; then
cp -r ../../external/rti_connext_dds-7.7.0/* "$DEB_DIR/opt/rti_connext_dds-7.7.0/"
fi
# Copy license file
if [ -f "../../../rti_license.dat" ]; then
cp ../../../rti_license.dat "$DEB_DIR/opt/rti_connext_dds-7.7.0/rti_license.dat"
fi
# Create control file
cat > "$DEB_DIR/DEBIAN/control" << EOF
Package: $PACKAGE_NAME
Version: $VERSION
Architecture: $ARCHITECTURE
Maintainer: $MAINTAINER
Depends: libqt6core6, libqt6gui6, libqt6widgets6, libstdc++6, libc6
Section: libdevel
Priority: optional
Description: $DESCRIPTION
RTI Connext DDS 7.7.0 Pro for Legatus.
.
License: Commercial FlexLM license
License file: /opt/rti_connext_dds-7.7.0/rti_license.dat
Set RTI_LICENSE_FILE environment variable.
EOF
# Create postinst script
cat > "$DEB_DIR/DEBIAN/postinst" << 'EOF'
#!/bin/bash
set -e
echo "RTI Connext DDS DEB package installed successfully"
echo "License: Commercial FlexLM license"
echo "License file: /opt/rti_connext_dds-7.7.0/rti_license.dat"
echo "Set RTI_LICENSE_FILE environment variable to use the library."
# Set permissions
chmod -R 755 /opt/rti_connext_dds-7.7.0
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postinst"
# Create postrm script
cat > "$DEB_DIR/DEBIAN/postrm" << 'EOF'
#!/bin/bash
set -e
echo "RTI Connext DDS DEB package removed"
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postrm"
# Build DEB package
echo "Building DEB package: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd "$DEB_DIR"
dpkg-deb --build . "../${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd ..
echo "DEB package created: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
echo "Size: $(du -h ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb | cut -f1)"
@@ -0,0 +1,8 @@
librti-connext-dds-7.7.0-dev (7.7.0) stable; urgency=medium
* Initial release for air-gapped environment
* RTI Connext DDS 7.7.0 Pro with commercial FlexLM license
* Includes rti_license.dat for license validation
* Installs to /opt/rti_connext_dds-7.7.0
-- Legatus Team <legatus@defence-elec.de> Mon, 01 Jan 2024 00:00:00 +0000
@@ -0,0 +1 @@
12
@@ -0,0 +1,22 @@
Source: librti-connext-dds-7.7.0-dev
Section: contrib/devel
Priority: optional
Maintainer: Legatus Team <legatus@defence-elec.de>
Build-Depends: debhelper (>= 12), qt6-base-dev
Standards-Version: 4.6.0
Vcs-Browser: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
Vcs-Git: https://internal-repo.sl.defence-elec.de/external-rpms/general/librti-connext-dds-7.7.0-dev.git
Package: librti-connext-dds-7.7.0-dev
Architecture: amd64
Depends: libqt6core6, libqt6gui6, libqt6widgets6, libstdc++6, libc6, ${shlibs:Depends}, ${misc:Depends}
Description: RTI Connext DDS 7.7.0 Pro - development files (commercial license)
RTI Connext DDS 7.7.0 Pro for Legatus.
.
License: Commercial FlexLM license
License file: /opt/rti_connext_dds-7.7.0/rti_license.dat
Set RTI_LICENSE_FILE environment variable.
.
This package contains the development files for RTI Connext DDS 7.7.0 Pro.
.
Available from SCM: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
@@ -0,0 +1,27 @@
#!/usr/bin/make -f
# Allow override of source path for building in CI/CD or local environments
# Default: /opt (production build machine)
# Can be overridden via DEB_BUILD_OPT_PATH environment variable
OPT_BASE ?= /opt
%:
dh $@
override_dh_auto_install:
dh_auto_install
install -d debian/librti-connext-dds-7.7.0-dev/opt/rti_connext_dds-7.7.0
cp -r $(OPT_BASE)/rti_connext_dds-7.7.0/* debian/librti-connext-dds-7.7.0-dev/opt/rti_connext_dds-7.7.0/
install -d debian/librti-connext-dds-7.7.0-dev/opt/rti_connext_dds-7.7.0/etc
# Copy license from build machine or project root
if [ -f $(OPT_BASE)/rti_connext_dds-7.7.0/rti_license.dat ]; then \
cp $(OPT_BASE)/rti_connext_dds-7.7.0/rti_license.dat debian/librti-connext-dds-7.7.0-dev/opt/rti_connext_dds-7.7.0/rti_license.dat; \
elif [ -f ../../../../rti_license.dat ]; then \
cp ../../../../rti_license.dat debian/librti-connext-dds-7.7.0-dev/opt/rti_connext_dds-7.7.0/rti_license.dat; \
else \
echo "ERROR: rti_license.dat not found!"; \
exit 1; \
fi
override_dh_strip:
dh_strip --no-automatic-dbgsym
@@ -0,0 +1 @@
3.0 (native)
@@ -0,0 +1,74 @@
#!/bin/bash
# Schusstafel DEB Package Build Script
# Builds libschusstafel-dev DEB package for internal SCM repository
set -e
PACKAGE_NAME="libschusstafel-dev"
VERSION="1.0.0"
ARCHITECTURE="amd64"
MAINTAINER="Legatus Team <legatus@defence-elec.de>"
DESCRIPTION="Schusstafel library - development files"
# Create package structure
DEB_DIR="deb-package"
rm -rf "$DEB_DIR"
mkdir -p "$DEB_DIR/DEBIAN"
mkdir -p "$DEB_DIR/opt/Schusstafel"
mkdir -p "$DEB_DIR/opt/offline-cache/schusstafel"
# Copy Schusstafel files from external/Schusstafel
if [ -d "../../external/Schusstafel" ]; then
cp -r ../../external/Schusstafel/* "$DEB_DIR/opt/Schusstafel/"
fi
# Create control file
cat > "$DEB_DIR/DEBIAN/control" << EOF
Package: $PACKAGE_NAME
Version: $VERSION
Architecture: $ARCHITECTURE
Maintainer: $MAINTAINER
Depends: libqt6core6, libqt6gui6, libqt6widgets6
Section: libdevel
Priority: optional
Description: $DESCRIPTION
Schusstafel library for Legatus.
.
License: Standard (no special license file required)
EOF
# Create postinst script
cat > "$DEB_DIR/DEBIAN/postinst" << 'EOF'
#!/bin/bash
set -e
echo "Schusstafel DEB package installed successfully"
# Set permissions
chmod -R 755 /opt/Schusstafel
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postinst"
# Create postrm script
cat > "$DEB_DIR/DEBIAN/postrm" << 'EOF'
#!/bin/bash
set -e
echo "Schusstafel DEB package removed"
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postrm"
# Build DEB package
echo "Building DEB package: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd "$DEB_DIR"
dpkg-deb --build . "../${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd ..
echo "DEB package created: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
echo "Size: $(du -h ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb | cut -f1)"
@@ -0,0 +1,7 @@
libschusstafel-dev (1.0.0) stable; urgency=medium
* Initial release for air-gapped environment
* Schusstafel library with standard license
* Installs to /opt/Schusstafel
-- Legatus Team <legatus@defence-elec.de> Mon, 01 Jan 2024 00:00:00 +0000
@@ -0,0 +1 @@
12
@@ -0,0 +1,18 @@
Source: libschusstafel-dev
Section: libdevel
Priority: optional
Maintainer: Legatus Team <legatus@defence-elec.de>
Build-Depends: debhelper (>= 12), qt6-base-dev
Standards-Version: 4.6.0
Vcs-Browser: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
Vcs-Git: https://internal-repo.sl.defence-elec.de/git/external/schusstafel.git
Package: libschusstafel-dev
Architecture: amd64
Depends: libqt6core6, libqt6gui6, libqt6widgets6, ${shlibs:Depends}, ${misc:Depends}
Description: Schusstafel library - development files
Schusstafel library for Legatus.
.
License: Standard (no special requirements)
.
This package contains the development files for Schusstafel library.
@@ -0,0 +1,17 @@
#!/usr/bin/make -f
# Allow override of source path for building in CI/CD or local environments
# Default: /opt (production build machine)
# Can be overridden via DEB_BUILD_OPT_PATH environment variable
OPT_BASE ?= /opt
%:
dh $@
override_dh_auto_install:
dh_auto_install
install -d debian/libschusstafel-dev/opt/Schusstafel
cp -r $(OPT_BASE)/Schusstafel/* debian/libschusstafel-dev/opt/Schusstafel/
override_dh_strip:
dh_strip --no-automatic-dbgsym
@@ -0,0 +1 @@
3.0 (native)
@@ -0,0 +1,76 @@
#!/bin/bash
# tmsif DEB Package Build Script
# Builds libtmsif-dev DEB package for internal SCM repository
set -e
PACKAGE_NAME="libtmsif-dev"
VERSION="1.0.0"
ARCHITECTURE="amd64"
MAINTAINER="Legatus Team <legatus@defence-elec.de>"
DESCRIPTION="TMSIF library - development files (contract-based license)"
# Create package structure
DEB_DIR="deb-package"
rm -rf "$DEB_DIR"
mkdir -p "$DEB_DIR/DEBIAN"
mkdir -p "$DEB_DIR/opt/tmsif"
mkdir -p "$DEB_DIR/opt/offline-cache/tmsif"
# Copy tmsif files from external/tmsif
if [ -d "../../external/tmsif" ]; then
cp -r ../../external/tmsif/* "$DEB_DIR/opt/tmsif/"
fi
# Create control file
cat > "$DEB_DIR/DEBIAN/control" << EOF
Package: $PACKAGE_NAME
Version: $VERSION
Architecture: $ARCHITECTURE
Maintainer: $MAINTAINER
Depends: libqt6core6, libqt6gui6, libqt6widgets6
Section: libdevel
Priority: optional
Description: $DESCRIPTION
TMSIF library for Legatus.
.
License: Contract-based (no file required)
Customer has lifetime license contract.
EOF
# Create postinst script
cat > "$DEB_DIR/DEBIAN/postinst" << 'EOF'
#!/bin/bash
set -e
echo "TMSIF DEB package installed successfully"
echo "License: Contract-based (no file required)"
# Set permissions
chmod -R 755 /opt/tmsif
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postinst"
# Create postrm script
cat > "$DEB_DIR/DEBIAN/postrm" << 'EOF'
#!/bin/bash
set -e
echo "TMSIF DEB package removed"
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postrm"
# Build DEB package
echo "Building DEB package: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd "$DEB_DIR"
dpkg-deb --build . "../${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd ..
echo "DEB package created: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
echo "Size: $(du -h ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb | cut -f1)"
@@ -0,0 +1,7 @@
libtmsif-dev (1.0.0) stable; urgency=medium
* Initial release for air-gapped environment
* TMSIF library with contract-based lifetime license
* Installs to /opt/tmsif
-- Legatus Team <legatus@defence-elec.de> Mon, 01 Jan 2024 00:00:00 +0000
@@ -0,0 +1 @@
12
@@ -0,0 +1,21 @@
Source: libtmsif-dev
Section: contrib/devel
Priority: optional
Maintainer: Legatus Team <legatus@defence-elec.de>
Build-Depends: debhelper (>= 12), qt6-base-dev
Standards-Version: 4.6.0
Vcs-Browser: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
Vcs-Git: https://internal-repo.sl.defence-elec.de/external-rpms/general/libtmsif-dev.git
Package: libtmsif-dev
Architecture: amd64
Depends: libqt6core6, libqt6gui6, libqt6widgets6, ${shlibs:Depends}, ${misc:Depends}
Description: TMSIF library - development files (contract-based license)
TMSIF library for Legatus.
.
License: Contract-based (no file required)
Customer has lifetime license contract.
.
This package contains the development files for TMSIF library.
.
Available from SCM: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
@@ -0,0 +1,17 @@
#!/usr/bin/make -f
# Allow override of source path for building in CI/CD or local environments
# Default: /opt (production build machine)
# Can be overridden via DEB_BUILD_OPT_PATH environment variable
OPT_BASE ?= /opt
%:
dh $@
override_dh_auto_install:
dh_auto_install
install -d debian/libtmsif-dev/opt/tmsif
cp -r $(OPT_BASE)/tmsif/* debian/libtmsif-dev/opt/tmsif/
override_dh_strip:
dh_strip --no-automatic-dbgsym
@@ -0,0 +1 @@
3.0 (native)
+89
View File
@@ -0,0 +1,89 @@
# dtEntity Installation
FROM harbor.sl.defence-elec.de/proxydockerhub/library/ubuntu:26.04
ARG RME_USERPASS=ctc
ARG RME_ADMINSRV=10.198.80.75
ARG RME_PROJECT=guez
# Proxy configuration for air-gapped environments
ARG http_proxy="http://10.198.80.130:3128"
ARG no_proxy="localhost,127.0.0.1,defence-elec.de,.defence-elec.de,sl.defence-elec.de,10.198.80.0/23,192.168.133.0/24,141.200.0.0/16,10.184.0.0/15,10.199.101.35,10.199.101.36,10.199.101.158"
ARG HTTP_PROXY=${http_proxy}
ARG https_proxy=${http_proxy}
ARG HTTPS_PROXY=${http_proxy}
ARG NO_PROXY=${no_proxy}
LABEL author="Legatus Team"
LABEL project=${RME_PROJECT}
LABEL version="1.0.0"
LABEL description="dtEntity Game Engine"
ENV DEBIAN_FRONTEND=noninteractive
# OS and PATH configuration
ENV LANG=C.UTF-8 \
LC_ALL=C.UTF-8
# Shell global auf Bash mit sicheren Pipes umstellen
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
# Originale Repositories durch Nexus Proxies ersetzen
RUN echo : > /etc/apt/sources.list && \
echo -e "Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu\n\
Suites: resolute resolute-updates resolute-backports\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu-security\n\
Suites: resolute-security\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: https://internal-repo.sl.defence-elec.de/repository/external-rpms\n\
Suites: general\n\
Components: main\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg" > /etc/apt/sources.list.d/ubuntu.sources
# Create users (install openssl first for password hashing)
RUN apt-get update && apt-get install -y openssl \
&& groupadd ctc -g 1445 || true \
&& groupadd rme -g 1001 || true \
&& useradd -d /shd/CTC/TOOLS -u 1445 -g ctc -m -p $(openssl passwd -5 ${RME_USERPASS}) ctc || true \
&& useradd -d /home/rme -u 1001 -g rme -m -p $(openssl passwd -5 ${RME_USERPASS}) rme || true \
&& rm -rf /var/lib/apt/lists/*
RUN curl -fsSL http://${RME_ADMINSRV}/rme/deb_and_rpm_signage_key.pub --output /etc/apt/keyrings/deb_and_rpm_signage_key.asc \
&& curl -fsSL http://${RME_ADMINSRV}/rme/SL-Netz.crt --output /usr/local/share/ca-certificates/SL-Netz.crt \
&& update-ca-certificates
# Install build dependencies
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential cmake git \
libqt6core6 libqt6gui6 libqt6widgets6 \
qt6-base-dev \
&& rm -rf /var/lib/apt/lists/*
# Install dtEntity from DEB package (air-gapped environment)
# DEB package is downloaded from internal SCM repository:
# https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
RUN apt-get update && apt-get install -y --no-install-recommends \
libdtentity-dev=${DTENTITY_VERSION} \
&& rm -rf /var/lib/apt/lists/*
# Set dtEntity environment variables
ENV DTENTITY_VERSION=1.0.0
ENV DTENTITY_INSTALL_DIR=/opt/dtEntity
ENV DTENTITY_INCLUDE_DIR=/opt/dtEntity/include
ENV DTENTITY_LIB_DIR=/opt/dtEntity/lib64
# Verify installation
RUN test -d /opt/dtEntity/include && \
test -d /opt/dtEntity/lib64
USER ctc
WORKDIR /shd/CTC/TOOLS
CMD ["/bin/bash"]
+110
View File
@@ -0,0 +1,110 @@
pipeline {
agent any
environment {
DTENTITY_VERSION = '1.0.0'
HARBOR_REGISTRY = 'harbor.sl.defence-elec.de/proxydockerhub'
IMAGE_NAME = 'dtentity'
IMAGE_TAG = "${DTENTITY_VERSION}"
OFFLINE_CACHE_PATH = '/opt/offline-cache/dtEntity'
}
options {
timeout(time: 20, unit: 'MINUTES')
buildDiscarder(logRotator(numToKeepStr: '10'))
}
stages {
stage('Checkout') {
steps {
checkout scm
}
}
stage('Prepare DEB Package Installation') {
steps {
script {
// dtEntity DEB package (libdtentity-dev) will be installed from internal SCM repository.
// No license file required - open source (LGPL license).
sh """
echo "dtEntity: Will install libdtentity-dev from internal SCM"
"""
}
}
}
stage('Build dtEntity Container') {
steps {
script {
dir('external-dependencies/dtentity') {
sh """
docker build \
--build-arg DTENTITY_VERSION=${DTENTITY_VERSION} \
-t ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} \
.
"""
}
}
}
}
stage('Verify dtEntity') {
steps {
script {
sh """
docker run --rm ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} bash -c '
ls -la /opt/dtEntity/
test -d /opt/dtEntity/include
test -d /opt/dtEntity/lib64
'
"""
}
}
}
stage('Generate SBOM') {
steps {
script {
dir('external-dependencies/dtentity') {
sh """
mkdir -p sbom
# Set environment variables for SBOM generation
export GIT_URL="${env.GIT_URL}"
export GIT_COMMIT="${env.GIT_COMMIT}"
export BUILD_NUMBER="${env.BUILD_NUMBER}"
export DOCKERFILE_PATH="external-dependencies/dtentity/Dockerfile"
# Generate CycloneDX SBOM, SLSA provenance, and license report
bash ../scripts/generate-sbom.sh dtentity ${DTENTITY_VERSION} ./sbom
"""
}
}
}
}
stage('Push to Registry') {
steps {
script {
withCredentials([usernamePassword(
credentialsId: 'harbor-credentials',
usernameVariable: 'HARBOR_USER',
passwordVariable: 'HARBOR_PASSWORD'
)]) {
sh """
echo ${HARBOR_PASSWORD} | docker login ${HARBOR_REGISTRY} -u ${HARBOR_USER} --password-stdin
docker push ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG}
docker logout ${HARBOR_REGISTRY}
"""
}
}
}
}
}
post {
always {
cleanWs()
}
}
}
@@ -0,0 +1,86 @@
# GeographicLib Installation
FROM harbor.sl.defence-elec.de/proxydockerhub/library/ubuntu:26.04
ARG RME_USERPASS=ctc
ARG RME_ADMINSRV=10.198.80.75
ARG RME_PROJECT=guez
# Proxy configuration for air-gapped environments
ARG http_proxy="http://10.198.80.130:3128"
ARG no_proxy="localhost,127.0.0.1,defence-elec.de,.defence-elec.de,sl.defence-elec.de,10.198.80.0/23,192.168.133.0/24,141.200.0.0/16,10.184.0.0/15,10.199.101.35,10.199.101.36,10.199.101.158"
ARG HTTP_PROXY=${http_proxy}
ARG https_proxy=${http_proxy}
ARG HTTPS_PROXY=${http_proxy}
ARG NO_PROXY=${no_proxy}
LABEL author="Legatus Team"
LABEL project=${RME_PROJECT}
LABEL version="2.0"
LABEL description="GeographicLib for Legatus"
ENV DEBIAN_FRONTEND=noninteractive
# OS and PATH configuration
ENV LANG=C.UTF-8 \
LC_ALL=C.UTF-8
# Shell global auf Bash mit sicheren Pipes umstellen
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
# Originale Repositories durch Nexus Proxies ersetzen
RUN echo : > /etc/apt/sources.list && \
echo -e "Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu\n\
Suites: resolute resolute-updates resolute-backports\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu-security\n\
Suites: resolute-security\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: https://internal-repo.sl.defence-elec.de/repository/external-rpms\n\
Suites: general\n\
Components: main\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg" > /etc/apt/sources.list.d/ubuntu.sources
# Create users (install openssl first for password hashing)
RUN apt-get update && apt-get install -y openssl \
&& groupadd ctc -g 1445 || true \
&& groupadd rme -g 1001 || true \
&& useradd -d /shd/CTC/TOOLS -u 1445 -g ctc -m -p $(openssl passwd -5 ${RME_USERPASS}) ctc || true \
&& useradd -d /home/rme -u 1001 -g rme -m -p $(openssl passwd -5 ${RME_USERPASS}) rme || true \
&& rm -rf /var/lib/apt/lists/*
RUN curl -fsSL http://${RME_ADMINSRV}/rme/deb_and_rpm_signage_key.pub --output /etc/apt/keyrings/deb_and_rpm_signage_key.asc \
&& curl -fsSL http://${RME_ADMINSRV}/rme/SL-Netz.crt --output /usr/local/share/ca-certificates/SL-Netz.crt \
&& update-ca-certificates
ARG GEOGRAPHICLIB_VERSION=2.0
# Install build dependencies
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential cmake git \
&& rm -rf /var/lib/apt/lists/*
# Install GeographicLib from DEB package (air-gapped environment)
# DEB package is downloaded from internal SCM repository:
# https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
RUN apt-get update && apt-get install -y --no-install-recommends \
libgeographiclib-dev=${GEOGRAPHICLIB_VERSION} \
&& rm -rf /var/lib/apt/lists/*
# Set GeographicLib installation path
ENV GEOGRAPHICLIB_ROOT=/opt/GeographicLib
ENV GEOGRAPHICLIB_VERSION=${GEOGRAPHICLIB_VERSION}
# Verify installation
RUN test -f /opt/GeographicLib/lib/libGeographicLib.so || test -d /opt/GeographicLib/include
USER ctc
WORKDIR /shd/CTC/TOOLS
CMD ["/bin/bash"]
+108
View File
@@ -0,0 +1,108 @@
pipeline {
agent any
environment {
GEOGRAPHICLIB_VERSION = '2.0'
HARBOR_REGISTRY = 'harbor.sl.defence-elec.de/proxydockerhub'
IMAGE_NAME = 'geographiclib'
IMAGE_TAG = "${GEOGRAPHICLIB_VERSION}"
OFFLINE_CACHE_PATH = '/opt/offline-cache/geographiclib'
}
options {
timeout(time: 20, unit: 'MINUTES')
buildDiscarder(logRotator(numToKeepStr: '10'))
}
stages {
stage('Checkout') {
steps {
checkout scm
}
}
stage('Prepare DEB Package Installation') {
steps {
script {
// GeographicLib DEB package (libgeographiclib-dev) will be installed from internal SCM repository.
// No license file required - open source (MIT/X11 license).
sh """
echo "GeographicLib: Will install libgeographiclib-dev from internal SCM"
"""
}
}
}
stage('Build GeographicLib Container') {
steps {
script {
dir('external-dependencies/geographiclib') {
sh """
docker build \
--build-arg GEOGRAPHICLIB_VERSION=${GEOGRAPHICLIB_VERSION} \
-t ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} \
.
"""
}
}
}
}
stage('Verify GeographicLib') {
steps {
script {
sh """
docker run --rm ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} bash -c '
ls -la /opt/GeographicLib/
'
"""
}
}
}
stage('Generate SBOM') {
steps {
script {
dir('external-dependencies/geographiclib') {
sh """
mkdir -p sbom
# Set environment variables for SBOM generation
export GIT_URL="${env.GIT_URL}"
export GIT_COMMIT="${env.GIT_COMMIT}"
export BUILD_NUMBER="${env.BUILD_NUMBER}"
export DOCKERFILE_PATH="external-dependencies/geographiclib/Dockerfile"
# Generate CycloneDX SBOM, SLSA provenance, and license report
bash ../scripts/generate-sbom.sh geographiclib ${GEOGRAPHICLIB_VERSION} ./sbom
"""
}
}
}
}
stage('Push to Registry') {
steps {
script {
withCredentials([usernamePassword(
credentialsId: 'harbor-credentials',
usernameVariable: 'HARBOR_USER',
passwordVariable: 'HARBOR_PASSWORD'
)]) {
sh """
echo ${HARBOR_PASSWORD} | docker login ${HARBOR_REGISTRY} -u ${HARBOR_USER} --password-stdin
docker push ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG}
docker logout ${HARBOR_REGISTRY}
"""
}
}
}
}
}
post {
always {
cleanWs()
}
}
}
@@ -0,0 +1,94 @@
# RTI Connext DDS 7.7.0 Installation
FROM harbor.sl.defence-elec.de/proxydockerhub/library/ubuntu:26.04
ARG RME_USERPASS=ctc
ARG RME_ADMINSRV=10.198.80.75
ARG RME_PROJECT=guez
# Proxy configuration for air-gapped environments
ARG http_proxy="http://10.198.80.130:3128"
ARG no_proxy="localhost,127.0.0.1,defence-elec.de,.defence-elec.de,sl.defence-elec.de,10.198.80.0/23,192.168.133.0/24,141.200.0.0/16,10.184.0.0/15,10.199.101.35,10.199.101.36,10.199.101.158"
ARG HTTP_PROXY=${http_proxy}
ARG https_proxy=${http_proxy}
ARG HTTPS_PROXY=${http_proxy}
ARG NO_PROXY=${no_proxy}
LABEL author="Legatus Team"
LABEL project=${RME_PROJECT}
LABEL version="7.7.0"
LABEL description="RTI Connext DDS 7.7.0 Pro"
ENV DEBIAN_FRONTEND=noninteractive
# OS and PATH configuration
ENV LANG=C.UTF-8 \
LC_ALL=C.UTF-8
# Shell global auf Bash mit sicheren Pipes umstellen
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
# Originale Repositories durch Nexus Proxies ersetzen
RUN echo : > /etc/apt/sources.list && \
echo -e "Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu\n\
Suites: resolute resolute-updates resolute-backports\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu-security\n\
Suites: resolute-security\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: https://internal-repo.sl.defence-elec.de/repository/external-rpms\n\
Suites: general\n\
Components: main\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg" > /etc/apt/sources.list.d/ubuntu.sources
# Create users (install openssl first for password hashing)
RUN apt-get update && apt-get install -y openssl \
&& groupadd ctc -g 1445 || true \
&& groupadd rme -g 1001 || true \
&& useradd -d /shd/CTC/TOOLS -u 1445 -g ctc -m -p $(openssl passwd -5 ${RME_USERPASS}) ctc || true \
&& useradd -d /home/rme -u 1001 -g rme -m -p $(openssl passwd -5 ${RME_USERPASS}) rme || true \
&& rm -rf /var/lib/apt/lists/*
RUN curl -fsSL http://${RME_ADMINSRV}/rme/deb_and_rpm_signage_key.pub --output /etc/apt/keyrings/deb_and_rpm_signage_key.asc \
&& curl -fsSL http://${RME_ADMINSRV}/rme/SL-Netz.crt --output /usr/local/share/ca-certificates/SL-Netz.crt \
&& update-ca-certificates
ARG RTI_VERSION=7.7.0
# Install build dependencies
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential cmake git \
libqt6core6 libqt6gui6 libqt6widgets6 \
qt6-base-dev \
librti-connext-dds-7.7.0-dev \
&& rm -rf /var/lib/apt/lists/*
# Copy RTI license file (commercial lifetime license)
# License file copied from Jenkins workspace into container
COPY --chown=ctc:ctc rti_license.dat /opt/rti_connext_dds-7.7.0/rti_license.dat
# Set RTI environment variables
ENV RTI_VERSION=7.7.0
ENV RTI_INSTALL_DIR=/opt/rti_connext_dds-7.7.0
ENV RTI_LICENSE_FILE=/opt/rti_connext_dds-7.7.0/rti_license.dat
ENV NDDSHOME=/opt/rti_connext_dds-7.7.0
# LICENSE HANDLING: RTI uses FlexLM license file (rti_license.dat)
# Commercial lifetime license for air-gapped environment
# License file must be provided in Jenkins workspace and copied into container
# DEB package installed from internal SCM repository
# Verify installation
RUN test -f /opt/rti_connext_dds-7.7.0/rti_license.dat && \
test -d /opt/rti_connext_dds-7.7.0/include
USER ctc
WORKDIR /shd/CTC/TOOLS
CMD ["/bin/bash"]
+115
View File
@@ -0,0 +1,115 @@
pipeline {
agent any
environment {
RTI_VERSION = '7.7.0'
HARBOR_REGISTRY = 'harbor.sl.defence-elec.de/proxydockerhub'
IMAGE_NAME = 'rti-connext-dds'
IMAGE_TAG = "${RTI_VERSION}"
OFFLINE_CACHE_PATH = '/opt/offline-cache/rti_connext_dds-7.7.0'
RTI_LICENSE_FILE = '/opt/rti_connext_dds-7.7.0/rti_license.dat'
}
options {
timeout(time: 20, unit: 'MINUTES')
buildDiscarder(logRotator(numToKeepStr: '10'))
}
stages {
stage('Checkout') {
steps {
checkout scm
}
}
stage('Prepare License Files') {
steps {
script {
// LICENSE HANDLING: RTI uses file-based licensing.
// License file (rti_license.dat) must be copied into container for FlexLM discovery.
// Customer has lifetime commercial license.
// DEB package (librti-connext-dds-7.7.0-dev) will be installed from internal SCM repository.
sh """
mkdir -p ${env.WORKSPACE}/rti-license-staging
cp ${env.WORKSPACE}/rti_license.dat ${env.WORKSPACE}/rti-license-staging/
echo "RTI license file prepared: rti_license.dat"
"""
}
}
}
stage('Build RTI Container') {
steps {
script {
dir('external-dependencies/rti-connext-dds') {
sh """
docker build \
--build-arg RTI_VERSION=${RTI_VERSION} \
-t ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} \
.
"""
}
}
}
}
stage('Verify RTI') {
steps {
script {
sh """
docker run --rm ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} bash -c '
ls -la /opt/rti_connext_dds-7.7.0/
test -f /opt/rti_connext_dds-7.7.0/rti_license.dat
test -d /opt/rti_connext_dds-7.7.0/include
'
"""
}
}
}
stage('Generate SBOM') {
steps {
script {
dir('external-dependencies/rti-connext-dds') {
sh """
mkdir -p sbom
# Set environment variables for SBOM generation
export GIT_URL="${env.GIT_URL}"
export GIT_COMMIT="${env.GIT_COMMIT}"
export BUILD_NUMBER="${env.BUILD_NUMBER}"
export DOCKERFILE_PATH="external-dependencies/rti-connext-dds/Dockerfile"
# Generate CycloneDX SBOM, SLSA provenance, and license report
bash ../scripts/generate-sbom.sh rti-connext-dds ${RTI_VERSION} ./sbom
"""
}
}
}
}
stage('Push to Registry') {
steps {
script {
withCredentials([usernamePassword(
credentialsId: 'harbor-credentials',
usernameVariable: 'HARBOR_USER',
passwordVariable: 'HARBOR_PASSWORD'
)]) {
sh """
echo ${HARBOR_PASSWORD} | docker login ${HARBOR_REGISTRY} -u ${HARBOR_USER} --password-stdin
docker push ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG}
docker logout ${HARBOR_REGISTRY}
"""
}
}
}
}
}
post {
always {
cleanWs()
}
}
}
@@ -0,0 +1,86 @@
# Schusstafel Installation
FROM harbor.sl.defence-elec.de/proxydockerhub/library/ubuntu:26.04
ARG RME_USERPASS=ctc
ARG RME_ADMINSRV=10.198.80.75
ARG RME_PROJECT=guez
# Proxy configuration for air-gapped environments
ARG http_proxy="http://10.198.80.130:3128"
ARG no_proxy="localhost,127.0.0.1,defence-elec.de,.defence-elec.de,sl.defence-elec.de,10.198.80.0/23,192.168.133.0/24,141.200.0.0/16,10.184.0.0/15,10.199.101.35,10.199.101.36,10.199.101.158"
ARG HTTP_PROXY=${http_proxy}
ARG https_proxy=${http_proxy}
ARG HTTPS_PROXY=${http_proxy}
ARG NO_PROXY=${no_proxy}
LABEL author="Legatus Team"
LABEL project=${RME_PROJECT}
LABEL version="1.0.0"
LABEL description="Schusstafel library for Legatus"
ENV DEBIAN_FRONTEND=noninteractive
# OS and PATH configuration
ENV LANG=C.UTF-8 \
LC_ALL=C.UTF-8
# Shell global auf Bash mit sicheren Pipes umstellen
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
# Originale Repositories durch Nexus Proxies ersetzen
RUN echo : > /etc/apt/sources.list && \
echo -e "Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu\n\
Suites: resolute resolute-updates resolute-backports\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu-security\n\
Suites: resolute-security\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: https://internal-repo.sl.defence-elec.de/repository/external-rpms\n\
Suites: general\n\
Components: main\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg" > /etc/apt/sources.list.d/ubuntu.sources
# Create users (install openssl first for password hashing)
RUN apt-get update && apt-get install -y openssl \
&& groupadd ctc -g 1445 || true \
&& groupadd rme -g 1001 || true \
&& useradd -d /shd/CTC/TOOLS -u 1445 -g ctc -m -p $(openssl passwd -5 ${RME_USERPASS}) ctc || true \
&& useradd -d /home/rme -u 1001 -g rme -m -p $(openssl passwd -5 ${RME_USERPASS}) rme || true \
&& rm -rf /var/lib/apt/lists/*
RUN curl -fsSL http://${RME_ADMINSRV}/rme/deb_and_rpm_signage_key.pub --output /etc/apt/keyrings/deb_and_rpm_signage_key.asc \
&& curl -fsSL http://${RME_ADMINSRV}/rme/SL-Netz.crt --output /usr/local/share/ca-certificates/SL-Netz.crt \
&& update-ca-certificates
ARG SCHUSSTAFEL_VERSION=1.0.0
# Install build dependencies
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential cmake git \
&& rm -rf /var/lib/apt/lists/*
# Install Schusstafel from DEB package (air-gapped environment)
# DEB package is downloaded from internal SCM repository:
# https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
RUN apt-get update && apt-get install -y --no-install-recommends \
libschusstafel-dev=${SCHUSSTAFEL_VERSION} \
&& rm -rf /var/lib/apt/lists/*
# Set Schusstafel installation path
ENV SCHUSSTAFEL_ROOT=/opt/Schusstafel
ENV SCHUSSTAFEL_VERSION=${SCHUSSTAFEL_VERSION}
# Verify installation
RUN test -f /opt/Schusstafel/lib/libSchusstafel.so || test -d /opt/Schusstafel/include
USER ctc
WORKDIR /shd/CTC/TOOLS
CMD ["/bin/bash"]
+108
View File
@@ -0,0 +1,108 @@
pipeline {
agent any
environment {
SCHUSSTAFEL_VERSION = '1.0.0'
HARBOR_REGISTRY = 'harbor.sl.defence-elec.de/proxydockerhub'
IMAGE_NAME = 'schusstafel'
IMAGE_TAG = "${SCHUSSTAFEL_VERSION}"
OFFLINE_CACHE_PATH = '/opt/offline-cache/schusstafel'
}
options {
timeout(time: 20, unit: 'MINUTES')
buildDiscarder(logRotator(numToKeepStr: '10'))
}
stages {
stage('Checkout') {
steps {
checkout scm
}
}
stage('Prepare DEB Package Installation') {
steps {
script {
// Schusstafel DEB package (libschusstafel-dev) will be installed from internal SCM repository.
// No license file required - open source or contract-based licensing.
sh """
echo "Schusstafel: Will install libschusstafel-dev from internal SCM"
"""
}
}
}
stage('Build Schusstafel Container') {
steps {
script {
dir('external-dependencies/schusstafel') {
sh """
docker build \
--build-arg SCHUSSTAFEL_VERSION=${SCHUSSTAFEL_VERSION} \
-t ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} \
.
"""
}
}
}
}
stage('Verify Schusstafel') {
steps {
script {
sh """
docker run --rm ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} bash -c '
ls -la /opt/Schusstafel/
'
"""
}
}
}
stage('Generate SBOM') {
steps {
script {
dir('external-dependencies/schusstafel') {
sh """
mkdir -p sbom
# Set environment variables for SBOM generation
export GIT_URL="${env.GIT_URL}"
export GIT_COMMIT="${env.GIT_COMMIT}"
export BUILD_NUMBER="${env.BUILD_NUMBER}"
export DOCKERFILE_PATH="external-dependencies/schusstafel/Dockerfile"
# Generate CycloneDX SBOM, SLSA provenance, and license report
bash ../scripts/generate-sbom.sh schusstafel ${SCHUSSTAFEL_VERSION} ./sbom
"""
}
}
}
}
stage('Push to Registry') {
steps {
script {
withCredentials([usernamePassword(
credentialsId: 'harbor-credentials',
usernameVariable: 'HARBOR_USER',
passwordVariable: 'HARBOR_PASSWORD'
)]) {
sh """
echo ${HARBOR_PASSWORD} | docker login ${HARBOR_REGISTRY} -u ${HARBOR_USER} --password-stdin
docker push ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG}
docker logout ${HARBOR_REGISTRY}
"""
}
}
}
}
}
post {
always {
cleanWs()
}
}
}
+84
View File
@@ -0,0 +1,84 @@
# tmsif Installation
FROM harbor.sl.defence-elec.de/proxydockerhub/library/ubuntu:26.04
ARG RME_USERPASS=ctc
ARG RME_ADMINSRV=10.198.80.75
ARG RME_PROJECT=guez
# Proxy configuration for air-gapped environments
ARG http_proxy="http://10.198.80.130:3128"
ARG no_proxy="localhost,127.0.0.1,defence-elec.de,.defence-elec.de,sl.defence-elec.de,10.198.80.0/23,192.168.133.0/24,141.200.0.0/16,10.184.0.0/15,10.199.101.35,10.199.101.36,10.199.101.158"
ARG HTTP_PROXY=${http_proxy}
ARG https_proxy=${http_proxy}
ARG HTTPS_PROXY=${http_proxy}
ARG NO_PROXY=${no_proxy}
LABEL author="Legatus Team"
LABEL project=${RME_PROJECT}
LABEL version="1.0.0"
LABEL description="tmsif library for Legatus"
ENV DEBIAN_FRONTEND=noninteractive
# OS and PATH configuration
ENV LANG=C.UTF-8 \
LC_ALL=C.UTF-8
# Shell global auf Bash mit sicheren Pipes umstellen
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
# Originale Repositories durch Nexus Proxies ersetzen
RUN echo : > /etc/apt/sources.list && \
echo -e "Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu\n\
Suites: resolute resolute-updates resolute-backports\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: http://remote-repo.sl.defence-elec.de:8081/repository/ubuntu-security\n\
Suites: resolute-security\n\
Components: main restricted universe multiverse\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg\n\
\n\
Types: deb\n\
URIs: https://internal-repo.sl.defence-elec.de/repository/external-rpms\n\
Suites: general\n\
Components: main\n\
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg" > /etc/apt/sources.list.d/ubuntu.sources
# Create users (install openssl first for password hashing)
RUN apt-get update && apt-get install -y openssl \
&& groupadd ctc -g 1445 || true \
&& groupadd rme -g 1001 || true \
&& useradd -d /shd/CTC/TOOLS -u 1445 -g ctc -m -p $(openssl passwd -5 ${RME_USERPASS}) ctc || true \
&& useradd -d /home/rme -u 1001 -g rme -m -p $(openssl passwd -5 ${RME_USERPASS}) rme || true \
&& rm -rf /var/lib/apt/lists/*
RUN curl -fsSL http://${RME_ADMINSRV}/rme/deb_and_rpm_signage_key.pub --output /etc/apt/keyrings/deb_and_rpm_signage_key.asc \
&& curl -fsSL http://${RME_ADMINSRV}/rme/SL-Netz.crt --output /usr/local/share/ca-certificates/SL-Netz.crt \
&& update-ca-certificates
ARG TMSIF_VERSION=1.0.0
# Install build dependencies
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential cmake git \
libtmsif-dev \
&& rm -rf /var/lib/apt/lists/*
# Set tmsif installation path
ENV TMSIF_ROOT=/opt/tmsif
# LICENSE HANDLING: TMSIF uses contract-based licensing (no license file required)
# Customer has lifetime license contract for air-gapped environment
# DEB package installed from internal SCM repository
# No license file copy or environment variable needed
# Verify installation
RUN test -f /opt/tmsif/lib/libtmsif.so || test -d /opt/tmsif/include
USER ctc
WORKDIR /shd/CTC/TOOLS
CMD ["/bin/bash"]
+110
View File
@@ -0,0 +1,110 @@
pipeline {
agent any
environment {
TMSIF_VERSION = '1.0.0'
HARBOR_REGISTRY = 'harbor.sl.defence-elec.de/proxydockerhub'
IMAGE_NAME = 'tmsif'
IMAGE_TAG = "${TMSIF_VERSION}"
OFFLINE_CACHE_PATH = '/opt/offline-cache/tmsif'
}
options {
timeout(time: 20, unit: 'MINUTES')
buildDiscarder(logRotator(numToKeepStr: '10'))
}
stages {
stage('Checkout') {
steps {
checkout scm
}
}
stage('Prepare License Files') {
steps {
script {
// LICENSE HANDLING: TMSIF uses contract-based licensing.
// Customer has lifetime license contract - no license file required.
// License is managed at contract level, not file-based.
// DEB package (libtmsif-dev) will be installed from internal SCM repository.
sh """
echo "TMSIF license: Contract-based (no file required)"
"""
}
}
}
stage('Build tmsif Container') {
steps {
script {
dir('external-dependencies/tmsif') {
sh """
docker build \
--build-arg TMSIF_VERSION=${TMSIF_VERSION} \
-t ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} \
.
"""
}
}
}
}
stage('Verify tmsif') {
steps {
script {
sh """
docker run --rm ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG} bash -c '
ls -la /opt/tmsif/
'
"""
}
}
}
stage('Generate SBOM') {
steps {
script {
dir('external-dependencies/tmsif') {
sh """
mkdir -p sbom
# Set environment variables for SBOM generation
export GIT_URL="${env.GIT_URL}"
export GIT_COMMIT="${env.GIT_COMMIT}"
export BUILD_NUMBER="${env.BUILD_NUMBER}"
export DOCKERFILE_PATH="external-dependencies/tmsif/Dockerfile"
# Generate CycloneDX SBOM, SLSA provenance, and license report
bash ../scripts/generate-sbom.sh tmsif ${TMSIF_VERSION} ./sbom
"""
}
}
}
}
stage('Push to Registry') {
steps {
script {
withCredentials([usernamePassword(
credentialsId: 'harbor-credentials',
usernameVariable: 'HARBOR_USER',
passwordVariable: 'HARBOR_PASSWORD'
)]) {
sh """
echo ${HARBOR_PASSWORD} | docker login ${HARBOR_REGISTRY} -u ${HARBOR_USER} --password-stdin
docker push ${HARBOR_REGISTRY}/${IMAGE_NAME}:${IMAGE_TAG}
docker logout ${HARBOR_REGISTRY}
"""
}
}
}
}
}
post {
always {
cleanWs()
}
}
}
@@ -210,14 +210,32 @@ RUN apt-get update \
# Already installed in base dependencies # Already installed in base dependencies
# ============================================================================= # =============================================================================
# Runtime Mount Points for Proprietary Dependencies # External Dependencies from DEB Packages
# ============================================================================= # =============================================================================
RUN mkdir -p /opt/RTI /opt/ArcGIS # Configure internal SCM repository for external dependencies
RUN echo "deb [trusted=yes] http://remote-repo.sl.defence-elec.de:8081/repository/external-rpms/general/ ./" > /etc/apt/sources.list.d/scm-external.list
RUN apt-get update && apt-get install -y --no-install-recommends \
libavs-dev \
libarcgis-dev \
libbuildingmodels-dev \
libgeographiclib-dev \
libschusstafel-dev \
libdtentity-dev \
librti-connext-dds-7.7.0-dev \
libtmsif-dev \
&& rm -rf /var/lib/apt/lists/*
# ============================================================================= # =============================================================================
# Environment Variables # Environment Variables
# ============================================================================= # =============================================================================
ENV DDS_PATH=/opt/RTI ENV DDS_PATH=/opt/rti_connext_dds-7.7.0
ENV RTI_LICENSE_FILE=/opt/rti_connext_dds-7.7.0/rti_license.dat
ENV RTI_CONNEXT_HOME=/opt/rti_connext_dds-7.7.0
ENV NDDSHOME=/opt/rti_connext_dds-7.7.0
ENV PATH=/opt/rti_connext_dds-7.7.0/bin:$PATH
ENV LD_LIBRARY_PATH=/opt/rti_connext_dds-7.7.0/lib/x64Linux4gcc7.3.0:$LD_LIBRARY_PATH
ENV CMAKE_PREFIX_PATH=/opt/rti_connext_dds-7.7.0/lib/cmake:$CMAKE_PREFIX_PATH
ENV ARCGIS_SDK_ROOT=/opt/ArcGIS/MapsSDK_Qt_300.0.0 ENV ARCGIS_SDK_ROOT=/opt/ArcGIS/MapsSDK_Qt_300.0.0
# ============================================================================= # =============================================================================