Add attic-client (s390x) and geesefs to flake-hub, rewrite CI in xonsh
Move attic-client s390x cross-compilation from building/s390x/attic-client-s390x and geesefs from building/s390x/geesefs-s390x into flake-hub. Replace ci/build.sh with ci/build.xsh. All packages now built and pushed to attic via the existing Woodpecker pipeline on push to main.
This commit is contained in:
-22
@@ -1,22 +0,0 @@
|
||||
#!/bin/sh
|
||||
# Build all flake-hub packages and push to attic
|
||||
set -e
|
||||
|
||||
ARCH="$1"
|
||||
ATTIC_CACHE="attic-infra-cache-k3s-1"
|
||||
ATTIC_SERVER="https://nix-cache-upload.oleks.space"
|
||||
|
||||
echo "=== Building flake-hub packages for ${ARCH} ==="
|
||||
|
||||
# Setup attic
|
||||
attic=$(nix build --inputs-from . nixpkgs#attic-client --print-out-paths --no-link)/bin/attic
|
||||
"${attic}" login ci "${ATTIC_SERVER}" "${ATTIC_TOKEN}"
|
||||
|
||||
echo "Building packages..."
|
||||
out=$(nix build ".#packages.${ARCH}.hello-world" --print-build-logs --print-out-paths --no-link)
|
||||
"${attic}" push "${ATTIC_CACHE}" "${out}"
|
||||
|
||||
out=$(nix build ".#packages.${ARCH}.xonsh" --print-build-logs --print-out-paths --no-link)
|
||||
"${attic}" push "${ATTIC_CACHE}" "${out}"
|
||||
|
||||
echo "✅ Build completed for ${ARCH}"
|
||||
@@ -0,0 +1,29 @@
|
||||
#!/usr/bin/env xonsh
|
||||
"""Build all flake-hub packages and push to attic."""
|
||||
|
||||
import sys
|
||||
|
||||
ARCH = sys.argv[1]
|
||||
ATTIC_CACHE = "attic-infra-cache-k3s-1"
|
||||
ATTIC_SERVER = "https://nix-cache-upload.oleks.space"
|
||||
|
||||
print(f"=== Building flake-hub packages for {ARCH} ===")
|
||||
|
||||
# Setup attic
|
||||
attic = $(nix build --inputs-from . nixpkgs#attic-client --print-out-paths --no-link).strip() + "/bin/attic"
|
||||
@(attic) login ci @(ATTIC_SERVER) $ATTIC_TOKEN
|
||||
|
||||
# Common packages (all arches)
|
||||
packages = ["hello-world", "geesefs", "xonsh"]
|
||||
|
||||
# Cross-only packages
|
||||
if ARCH == "s390x-linux":
|
||||
packages += ["attic-client"]
|
||||
|
||||
print("Building packages...")
|
||||
for pkg in packages:
|
||||
print(f"--- {pkg} ---")
|
||||
out = $(nix build @(f".#packages.{ARCH}.{pkg}") --print-build-logs --print-out-paths --no-link).strip()
|
||||
@(attic) push @(ATTIC_CACHE) @(out)
|
||||
|
||||
print(f"Build completed for {ARCH}")
|
||||
Reference in New Issue
Block a user