mirror of
https://github.com/coreos/coreos-assembler.git
synced 2026-02-05 18:44:56 +01:00
cci.jenkinsfile: add in workaround for pod pull issue
We are seeing an issue where the first time we try to create a pod from a just created image it fails. Here we bake in an initial pod that we allow to fail to work around the problem while we investigate.
This commit is contained in:
@@ -9,9 +9,20 @@ properties([
|
||||
// an imageStream for it
|
||||
def cpuCount = 6
|
||||
def cpuCount_s = cpuCount.toString()
|
||||
def memory = (cpuCount * 1536) as Integer
|
||||
def imageName = buildImage(env: [ENABLE_GO_RACE_DETECTOR: "1", GOMAXPROCS: cpuCount_s], cpu: cpuCount_s)
|
||||
|
||||
def memory = (cpuCount * 1536) as Integer
|
||||
// We are seeing an issue where the first time we try to create a pod
|
||||
// from a just created image it fails. Here we bake in an initial pod
|
||||
// that we allow to fail to work around the problem while we investigate.
|
||||
try {
|
||||
pod(image: imageName + ":latest", kvm: true, cpu: "${cpuCount}", memory: "${memory}Mi") {
|
||||
shwrap("Initial pod creation worked!")
|
||||
}
|
||||
} catch(e) {
|
||||
echo "Initial pod creation failed. Continuing."
|
||||
}
|
||||
|
||||
pod(image: imageName + ":latest", kvm: true, cpu: "${cpuCount}", memory: "${memory}Mi") {
|
||||
checkout scm
|
||||
|
||||
|
||||
Reference in New Issue
Block a user