Multiply updates
* Fix output processing
for predictable qemu artifact naming
* install-recommends=false for ubuntu16
* add zerofree for lvm case
* Fix PACKER_ARGS pass
Change-Id: I023b73963aeb7c1d562dbc6b1e414363de913d90
diff --git a/packer-image-buid.groovy b/packer-image-buid.groovy
index a87918f..87ef652 100644
--- a/packer-image-buid.groovy
+++ b/packer-image-buid.groovy
@@ -135,7 +135,7 @@
}
stage("Build Instance") {
- def _packer_args = "${job_env.get(PACKER_ARGS, '')}"
+ def _packer_args = job_env.get('PACKER_ARGS', '')
def _packer_log = "${workspace}/packer.log"
// clean old log, for correct status grepping
if (fileExists(_packer_log)) {
@@ -237,8 +237,8 @@
// collect artifacts
// TODO make it possible, process multiply artifacts by one run.
dir('images/') {
- sh(script: 'find .', returnStdout: true)
- def _files = findFiles(glob: "*qemu*/${imageName}*")
+ sh(script: 'find .')
+ def _files = findFiles(glob: "*qemu*/*${imageName}*.qcow2")
if (_files.size() > 1) {
common.warningMsg("Multiply artifacts detected!Only first one will be processed!")
} else if (_files.size() == 0) {