Skip to content

Commit 13d707c

Browse files
committed
Add GC step for AWS and Openstack jobs
1 parent b3771b2 commit 13d707c

File tree

2 files changed

+74
-58
lines changed

2 files changed

+74
-58
lines changed

jobs/kola-aws.Jenkinsfile

Lines changed: 67 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -72,69 +72,79 @@ cosaPod(memory: "512Mi", kvm: false,
7272
credentialsId: 'aws-kola-tests-config')]) {
7373
// A few independent tasks that can be run in parallel
7474
def parallelruns = [:]
75-
76-
parallelruns['Kola:Full'] = {
77-
kola(cosaDir: env.WORKSPACE, parallel: 5,
78-
build: params.VERSION, arch: params.ARCH,
79-
extraArgs: params.KOLA_TESTS,
80-
skipBasicScenarios: true,
81-
platformArgs: '-p=aws --aws-region=us-east-1',
82-
skipKolaTags: stream_info.skip_kola_tags)
83-
}
84-
85-
if (params.ARCH == "x86_64") {
86-
def tests = params.KOLA_TESTS
87-
if (tests == "") {
88-
tests = "basic"
75+
try {
76+
parallelruns['Kola:Full'] = {
77+
kola(cosaDir: env.WORKSPACE, parallel: 5,
78+
build: params.VERSION, arch: params.ARCH,
79+
extraArgs: params.KOLA_TESTS,
80+
skipBasicScenarios: true,
81+
platformArgs: '-p=aws --aws-region=us-east-1',
82+
skipKolaTags: stream_info.skip_kola_tags)
8983
}
90-
parallelruns['Kola:Xen'] = {
91-
// https://github.com/coreos/fedora-coreos-tracker/issues/997
92-
// Run this test on i3.large so we can also run ext.config.platforms.aws.nvme
93-
// to verify access to instance storage nvme disks works
94-
// https://github.com/coreos/fedora-coreos-tracker/issues/1306
95-
// Also add in the ext.config.platforms.aws.assert-xen test just
96-
// to sanity check we are on a Xen instance.
97-
def xen_tests = tests
98-
if (xen_tests == "basic") {
99-
xen_tests = "basic ext.config.platforms.aws.nvme ext.config.platforms.aws.assert-xen"
84+
85+
if (params.ARCH == "x86_64") {
86+
def tests = params.KOLA_TESTS
87+
if (tests == "") {
88+
tests = "basic"
89+
}
90+
parallelruns['Kola:Xen'] = {
91+
// https://github.com/coreos/fedora-coreos-tracker/issues/997
92+
// Run this test on i3.large so we can also run ext.config.platforms.aws.nvme
93+
// to verify access to instance storage nvme disks works
94+
// https://github.com/coreos/fedora-coreos-tracker/issues/1306
95+
// Also add in the ext.config.platforms.aws.assert-xen test just
96+
// to sanity check we are on a Xen instance.
97+
def xen_tests = tests
98+
if (xen_tests == "basic") {
99+
xen_tests = "basic ext.config.platforms.aws.nvme ext.config.platforms.aws.assert-xen"
100+
}
101+
kola(cosaDir: env.WORKSPACE,
102+
build: params.VERSION, arch: params.ARCH,
103+
extraArgs: xen_tests,
104+
skipUpgrade: true,
105+
marker: "xen",
106+
platformArgs: '-p=aws --aws-region=us-east-1 --aws-type=i3.large',
107+
skipKolaTags: stream_info.skip_kola_tags)
108+
}
109+
parallelruns['Kola:Intel-Ice-Lake'] = {
110+
// https://github.com/coreos/fedora-coreos-tracker/issues/1004
111+
kola(cosaDir: env.WORKSPACE,
112+
build: params.VERSION, arch: params.ARCH,
113+
extraArgs: tests,
114+
skipUpgrade: true,
115+
marker: "intel-ice-lake",
116+
platformArgs: '-p=aws --aws-region=us-east-1 --aws-type=m6i.large',
117+
skipKolaTags: stream_info.skip_kola_tags)
118+
}
119+
} else if (params.ARCH == "aarch64") {
120+
def tests = params.KOLA_TESTS
121+
if (tests == "") {
122+
tests = "basic"
123+
}
124+
parallelruns['Kola:Graviton3'] = {
125+
// https://aws.amazon.com/ec2/instance-types/c7g/
126+
kola(cosaDir: env.WORKSPACE,
127+
build: params.VERSION, arch: params.ARCH,
128+
extraArgs: tests,
129+
skipUpgrade: true,
130+
marker: "graviton3",
131+
platformArgs: '-p=aws --aws-region=us-east-1 --aws-type=c7g.xlarge',
132+
skipKolaTags: stream_info.skip_kola_tags)
100133
}
101-
kola(cosaDir: env.WORKSPACE,
102-
build: params.VERSION, arch: params.ARCH,
103-
extraArgs: xen_tests,
104-
skipUpgrade: true,
105-
marker: "xen",
106-
platformArgs: '-p=aws --aws-region=us-east-1 --aws-type=i3.large',
107-
skipKolaTags: stream_info.skip_kola_tags)
108-
}
109-
parallelruns['Kola:Intel-Ice-Lake'] = {
110-
// https://github.com/coreos/fedora-coreos-tracker/issues/1004
111-
kola(cosaDir: env.WORKSPACE,
112-
build: params.VERSION, arch: params.ARCH,
113-
extraArgs: tests,
114-
skipUpgrade: true,
115-
marker: "intel-ice-lake",
116-
platformArgs: '-p=aws --aws-region=us-east-1 --aws-type=m6i.large',
117-
skipKolaTags: stream_info.skip_kola_tags)
118-
}
119-
} else if (params.ARCH == "aarch64") {
120-
def tests = params.KOLA_TESTS
121-
if (tests == "") {
122-
tests = "basic"
123134
}
124-
parallelruns['Kola:Graviton3'] = {
125-
// https://aws.amazon.com/ec2/instance-types/c7g/
126-
kola(cosaDir: env.WORKSPACE,
127-
build: params.VERSION, arch: params.ARCH,
128-
extraArgs: tests,
129-
skipUpgrade: true,
130-
marker: "graviton3",
131-
platformArgs: '-p=aws --aws-region=us-east-1 --aws-type=c7g.xlarge',
132-
skipKolaTags: stream_info.skip_kola_tags)
135+
136+
// process this batch
137+
parallel parallelruns
138+
} finally {
139+
stage('Garbage Collection') {
140+
shwrap("""
141+
ore aws gc --debug \
142+
--credentials-file=\${AWS_CONFIG_FILE} \
143+
--region=us-east-1
144+
""")
133145
}
134146
}
135147

136-
// process this batch
137-
parallel parallelruns
138148
}
139149

140150
currentBuild.result = 'SUCCESS'

jobs/kola-openstack.Jenkinsfile

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,8 +135,14 @@ lock(resource: "kola-openstack-${params.ARCH}") {
135135
--region=${region} delete-image --id=${openstack_image_name}
136136
""")
137137
}
138+
stage('Garbage Collection') {
139+
shwrap("""
140+
ore openstack gc --debug \
141+
--config-file=\${OPENSTACK_KOLA_TESTS_CONFIG} \
142+
--region=${region} \
143+
""")
144+
}
138145
}
139-
140146
}
141147

142148
currentBuild.result = 'SUCCESS'

0 commit comments

Comments
 (0)