You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{kola,kolaTestIso}: workaround issue with accessDenied from dir()
When using `dir()` in the kola and kolaTestIso jobs we are getting a
permission denied error if the directory is isn't under the env.WORKSPACE
directory.
Let's go back to using a `cd ${cosaDir}` for now to workaround this while
we find better solutions. This `cd ${cosaDir}` will have no effect on
multi-arch where we'll be operating in a remote session anyway.
cosa remote-session sync ${env.WORKSPACE}/ :/var/tmp/kola/${name}/
64
+
cd ${cosaDir} && cosa shell -- mkdir -p /var/tmp/kola
65
+
cd ${cosaDir} && cosa remote-session sync ${env.WORKSPACE}/ :/var/tmp/kola/${name}/
66
66
""")
67
67
}
68
68
args +="--exttest /var/tmp/kola/${name}"
@@ -87,23 +87,23 @@ def call(params = [:]) {
87
87
// do a single run in that case.
88
88
id = marker ==""?"kola":"kola-${marker}"
89
89
ids += id
90
-
shwrap("cosa kola run ${rerun} --output-dir=${outputDir}/${id} --build=${buildID}${archArg}${platformArgs} --parallel ${parallel}${args}${extraArgs}")
90
+
shwrap("cd ${cosaDir} && cosa kola run ${rerun} --output-dir=${outputDir}/${id} --build=${buildID}${archArg}${platformArgs} --parallel ${parallel}${args}${extraArgs}")
91
91
} else {
92
92
// basic run
93
93
if (!params['skipBasicScenarios']) {
94
94
id = marker ==""?"kola-basic":"kola-basic-${marker}"
95
95
ids += id
96
-
shwrap("cosa kola run ${rerun} --output-dir=${outputDir}/${id} --basic-qemu-scenarios")
96
+
shwrap("cd ${cosaDir} && cosa kola run ${rerun} --output-dir=${outputDir}/${id} --basic-qemu-scenarios")
97
97
}
98
98
// normal run (without reprovision tests because those require a lot of memory)
99
99
id = marker ==""?"kola":"kola-${marker}"
100
100
ids += id
101
-
shwrap("cosa kola run ${rerun} --output-dir=${outputDir}/${id} --build=${buildID}${archArg}${platformArgs} --tag '!reprovision' --parallel ${parallel}${args}")
101
+
shwrap("cd ${cosaDir} && cosa kola run ${rerun} --output-dir=${outputDir}/${id} --build=${buildID}${archArg}${platformArgs} --tag '!reprovision' --parallel ${parallel}${args}")
102
102
103
103
// re-provision tests (not run with --parallel argument to kola)
104
104
id = marker ==""?"kola-reprovision":"kola-reprovision-${marker}"
105
105
ids += id
106
-
shwrap("cosa kola run ${rerun} --output-dir=${outputDir}/${id} --build=${buildID}${archArg}${platformArgs} --tag reprovision ${args}")
106
+
shwrap("cd ${cosaDir} && cosa kola run ${rerun} --output-dir=${outputDir}/${id} --build=${buildID}${archArg}${platformArgs} --tag reprovision ${args}")
107
107
}
108
108
}
109
109
@@ -115,7 +115,7 @@ def call(params = [:]) {
115
115
try {
116
116
def id = marker ==""?"kola-upgrade":"kola-upgrade-${marker}"
117
117
ids += id
118
-
shwrap("cosa kola ${rerun} --output-dir=${outputDir}/${id} --upgrades --build=${buildID}${archArg}${platformArgs}")
118
+
shwrap("cd ${cosaDir} && cosa kola ${rerun} --output-dir=${outputDir}/${id} --upgrades --build=${buildID}${archArg}${platformArgs}")
119
119
} catch(e) {
120
120
if (params["allowUpgradeFail"]) {
121
121
warnError(message: 'Upgrade Failed') {
@@ -128,22 +128,19 @@ def call(params = [:]) {
128
128
}
129
129
}
130
130
131
-
// Run the Kola tests from the cosaDir
132
-
dir(cosaDir) {
133
-
try {
134
-
if (kolaRuns.size() ==1) {
135
-
kolaRuns.each { k, v-> v() }
136
-
} else {
137
-
parallel(kolaRuns)
138
-
}
139
-
} finally {
140
-
for (id in ids) {
141
-
// sanity check kola actually ran and dumped its output
142
-
shwrap("cosa shell -- test -d ${outputDir}/${id}")
0 commit comments