initial packer jobs
This commit is contained in:
parent
19c7d2ee86
commit
e9662d4764
55
maintenance/alt-images/packer.groovy
Normal file
55
maintenance/alt-images/packer.groovy
Normal file
@ -0,0 +1,55 @@
|
||||
def baseName = 'maintenance/packer'
|
||||
def vms = ['qemu']
|
||||
def platforms = ['8.2', 'sisyphus']
|
||||
def baseDistrVersion = '8.2'
|
||||
def distrs = ['srv', 'ws', 'kws']
|
||||
def githubProject = 'altlinuxteam/alt-packer'
|
||||
def githubBranch = 'jenkins'
|
||||
def packerCachePath = '/data/iso_images/template/iso' // our PVE specific path
|
||||
|
||||
platforms.each { p ->
|
||||
distrs.each { d ->
|
||||
vms.each { v ->
|
||||
def jobName = "${baseName}-${v}-${d}-${p}"
|
||||
job(jobName) {
|
||||
label('kvm && bigmem && nix')
|
||||
scm {
|
||||
github(githubProject, githubBranch)
|
||||
}
|
||||
wrappers {
|
||||
colorizeOutput()
|
||||
timestamps()
|
||||
}
|
||||
steps {
|
||||
shell("""#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
set -x
|
||||
|
||||
rm -rf output-*
|
||||
rm -f results/*
|
||||
|
||||
nix-shell -p gnumake packer --run " \
|
||||
make \
|
||||
-e VM_TYPE=${v} \
|
||||
-e BASE_VERSION=${baseDistrVersion} \
|
||||
-e TARGET_VERSION=${p} \
|
||||
-e PACKER_CACHE_DIR=${packerCachePath} \
|
||||
${d}"
|
||||
|
||||
for ext in tar.gz md5 sha1; do
|
||||
mv results/${d}.${v}.\${ext} results/alt-${d}-${p}-${v}.\${ext}
|
||||
done
|
||||
""".stripIndent()
|
||||
)
|
||||
}
|
||||
|
||||
publishers {
|
||||
archiveArtifacts {
|
||||
pattern('results/*')
|
||||
onlyIfSuccessful(true)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user