- Add main ostree-backport.sh script with distribution selection - Add wrapper scripts: backport-noble.sh and backport-trixie.sh - Add usage-guide.sh for comprehensive documentation - Update CI/CD workflows with improved multi-distribution support - Add test-build.yml workflow for quick validation - Update README.md with multi-distribution documentation - Add CI-CD-IMPROVEMENTS.md with detailed workflow documentation - Remove old .deb files (steam.deb, wget_1.21.4-1ubuntu4.1_amd64.deb) Features: - Ubuntu Noble: Source from Questing, target Noble - Debian Trixie: Source from sid, target Trixie - Enhanced error handling and logging - Manual triggers for single/all distributions - Comprehensive CI/CD documentation
98 lines
No EOL
3.3 KiB
YAML
98 lines
No EOL
3.3 KiB
YAML
name: Test ostree Build
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
inputs:
|
|
target_distro:
|
|
description: 'Target distribution to test'
|
|
required: true
|
|
default: 'noble'
|
|
type: choice
|
|
options:
|
|
- noble
|
|
- trixie
|
|
|
|
env:
|
|
OSTREE_VERSION: "2025.2"
|
|
OSTREE_DEBIAN_REVISION: "1"
|
|
|
|
jobs:
|
|
test-build:
|
|
name: Test Build for ${{ github.event.inputs.target_distro }}
|
|
runs-on: ubuntu-latest
|
|
container:
|
|
image: ubuntu:latest
|
|
steps:
|
|
- name: Setup environment
|
|
run: |
|
|
echo "=== Testing build for ${{ github.event.inputs.target_distro }} ==="
|
|
apt update -y
|
|
apt install -y devscripts build-essential wget git curl jq
|
|
|
|
- name: Checkout repository
|
|
run: |
|
|
git clone https://git.raines.xyz/robojerk/libostree-dev.git /tmp/libostree-dev
|
|
cp -r /tmp/libostree-dev/* .
|
|
cp -r /tmp/libostree-dev/.* . 2>/dev/null || true
|
|
|
|
- name: Test source download
|
|
run: |
|
|
echo "=== Testing source download ==="
|
|
|
|
# Set distribution-specific variables
|
|
if [ "${{ github.event.inputs.target_distro }}" = "noble" ]; then
|
|
POOL_URL="http://archive.ubuntu.com/ubuntu/pool/universe/o/ostree/"
|
|
BACKPORT_SUFFIX="~noble1"
|
|
else
|
|
POOL_URL="http://deb.debian.org/debian/pool/main/o/ostree/"
|
|
BACKPORT_SUFFIX="~trixie1"
|
|
fi
|
|
|
|
echo "Pool URL: $POOL_URL"
|
|
echo "Backport Suffix: $BACKPORT_SUFFIX"
|
|
|
|
# Test download
|
|
wget "${POOL_URL}ostree_${OSTREE_VERSION}-${OSTREE_DEBIAN_REVISION}.dsc" || exit 1
|
|
wget "${POOL_URL}ostree_${OSTREE_VERSION}.orig.tar.xz" || exit 1
|
|
wget "${POOL_URL}ostree_${OSTREE_VERSION}-${OSTREE_DEBIAN_REVISION}.debian.tar.xz" || exit 1
|
|
|
|
echo "✅ Source files downloaded successfully"
|
|
ls -la *.dsc *.tar.xz
|
|
|
|
- name: Test source extraction
|
|
run: |
|
|
echo "=== Testing source extraction ==="
|
|
dpkg-source -x "ostree_${OSTREE_VERSION}-${OSTREE_DEBIAN_REVISION}.dsc" || exit 1
|
|
echo "✅ Source extracted successfully"
|
|
ls -la ostree-${OSTREE_VERSION}/
|
|
|
|
- name: Test changelog modification
|
|
run: |
|
|
echo "=== Testing changelog modification ==="
|
|
cd ostree-${OSTREE_VERSION}
|
|
|
|
if [ "${{ github.event.inputs.target_distro }}" = "noble" ]; then
|
|
BACKPORT_SUFFIX="~noble1"
|
|
TARGET_RELEASE="noble"
|
|
else
|
|
BACKPORT_SUFFIX="~trixie1"
|
|
TARGET_RELEASE="trixie"
|
|
fi
|
|
|
|
dch --newversion "${OSTREE_VERSION}-${OSTREE_DEBIAN_REVISION}${BACKPORT_SUFFIX}" \
|
|
--distribution "${TARGET_RELEASE}-backports" \
|
|
-b \
|
|
"Test backport for ${{ github.event.inputs.target_distro }}." || exit 1
|
|
|
|
echo "✅ Changelog modified successfully"
|
|
head -5 debian/changelog
|
|
|
|
- name: Success summary
|
|
run: |
|
|
echo "=== Test Build Summary ==="
|
|
echo "✅ All tests passed for ${{ github.event.inputs.target_distro }}"
|
|
echo "✅ Source download: OK"
|
|
echo "✅ Source extraction: OK"
|
|
echo "✅ Changelog modification: OK"
|
|
echo ""
|
|
echo "🎯 Ready for full build process" |