ostree/.cci.jenkinsfile
Jonathan Lebon 52810a41b9
ci: bump cosaPod memory requirement to 5Gi
We're hitting memory limits when running the reprovisioning tests. We
should investigate why we need 1Gi of overhead, but for now to get
unblocked let's just bump it.
2022-10-26 06:42:06 +00:00

69 lines
2.0 KiB
Plaintext

// Documentation: https://github.com/coreos/coreos-ci/blob/main/README-upstream-ci.md
stage("Build") {
def n = 5
buildPod(memory: "2Gi", cpu: "${n}") {
checkout scm
stage("Static analysis") {
shwrap("./ci/codestyle.sh")
}
stage("Core build") {
shwrap("""
# fetch tags so `git describe` gives a nice NEVRA when building the RPM
git fetch origin --tags
git submodule update --init
env MAKE_JOBS=${n} SKIP_INSTALLDEPS=1 ./ci/build.sh
""")
}
stage("Unit tests") {
try {
shwrap("""
make check
make syntax-check
""")
} finally {
shwrap("cat test-suite.log || true")
archiveArtifacts allowEmptyArchive: true, artifacts: 'test-suite.log'
}
}
stage("Build installed tests") {
shwrap("make -C tests/kolainst")
}
stage("Generate artifacts") {
shwrap("""
make install DESTDIR=\$(pwd)/installed/rootfs
make -C tests/kolainst install DESTDIR=\$(pwd)/installed/tests
""")
}
stash includes: "installed/", name: 'build'
}
}
// Build FCOS and run kola tests.
// Both kola and kolaTestIso require 4G max. Add 1G for overhead.
cosaPod(runAsUser: 0, memory: "5Gi", cpu: "4") {
stage("Build FCOS") {
checkout scm
unstash 'build'
shwrap("""
# Move the bits into the cosa pod
rsync -rlv installed/rootfs/ /
rsync -rlv installed/tests/ /
coreos-assembler init --force https://github.com/coreos/fedora-coreos-config
mkdir -p overrides/rootfs
# And override the on-host bits
mv installed/rootfs/* overrides/rootfs/
rm installed -rf
coreos-assembler fetch
coreos-assembler build
coreos-assembler buildextend-metal
coreos-assembler buildextend-metal4k
coreos-assembler buildextend-live --fast
""")
}
kola(cosaDir: "${env.WORKSPACE}")
kolaTestIso(cosaDir: "${env.WORKSPACE}", skipMetal4k: true, skipMultipath: true)
}