[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-commits] [qemu/qemu] 0679f9: docker: Handle exceptions when lookin
From: |
GitHub |
Subject: |
[Qemu-commits] [qemu/qemu] 0679f9: docker: Handle exceptions when looking for docker ... |
Date: |
Fri, 23 Sep 2016 06:30:05 -0700 |
Branch: refs/heads/master
Home: https://github.com/qemu/qemu
Commit: 0679f98b4035c6c3125fc6720a961bb25f916a7a
https://github.com/qemu/qemu/commit/0679f98b4035c6c3125fc6720a961bb25f916a7a
Author: Eduardo Habkost <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M tests/docker/docker.py
Log Message:
-----------
docker: Handle exceptions when looking for docker command
When trying to run docker tests on a host without the docker
command, we get the following Python backtrace:
$ make address@hidden V=1
.../qemu/tests/docker/docker.py build qemu:centos6
.../qemu/tests/docker/dockerfiles/centos6.docker
Traceback (most recent call last):
File ".../qemu/tests/docker/docker.py", line 339, in <module>
sys.exit(main())
File ".../qemu/tests/docker/docker.py", line 336, in main
return args.cmdobj.run(args, argv)
File ".../qemu/tests/docker/docker.py", line 231, in run
dkr = Docker()
File ".../qemu/tests/docker/docker.py", line 98, in __init__
self._command = _guess_docker_command()
File ".../qemu/tests/docker/docker.py", line 41, in _guess_docker_command
stdout=DEVNULL, stderr=DEVNULL) == 0:
File "/usr/lib64/python2.7/subprocess.py", line 523, in call
return Popen(*popenargs, **kwargs).wait()
File "/usr/lib64/python2.7/subprocess.py", line 711, in __init__
errread, errwrite)
File "/usr/lib64/python2.7/subprocess.py", line 1343, in _execute_child
raise child_exception
OSError: [Errno 2] No such file or directory
.../qemu/tests/docker/Makefile.include:47: recipe for target
'docker-image-centos6' failed
make: *** [docker-image-centos6] Error 1
Change _guess_docker_command() to handle OSError exceptions
raised by subprocess.call(), so we will keep looking for other
commands and print a better error message.
New output will be:
$ make address@hidden V=1
.../qemu/tests/docker/docker.py build qemu:centos6
.../qemu/tests/docker/dockerfiles/centos6.docker
Traceback (most recent call last):
File ".../qemu/tests/docker/docker.py", line 343, in <module>
sys.exit(main())
File ".../qemu/tests/docker/docker.py", line 340, in main
return args.cmdobj.run(args, argv)
File ".../qemu/tests/docker/docker.py", line 235, in run
dkr = Docker()
File ".../qemu/tests/docker/docker.py", line 102, in __init__
self._command = _guess_docker_command()
File ".../qemu/tests/docker/docker.py", line 49, in _guess_docker_command
commands_txt)
Exception: Cannot find working docker command. Tried:
docker
sudo -n docker
.../qemu/tests/docker/Makefile.include:47: recipe for target
'docker-image-centos6' failed
make: *** [docker-image-centos6] Error 1
Signed-off-by: Eduardo Habkost <address@hidden>
Message-Id: <address@hidden>
[exceptions.OSError -> OSError and drop the import. - Fam]
Signed-off-by: Fam Zheng <address@hidden>
Commit: cea25275a3590cdee774a1230f4b99f6c5c0eaa8
https://github.com/qemu/qemu/commit/cea25275a3590cdee774a1230f4b99f6c5c0eaa8
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M arch_init.c
M block/iscsi.c
M hw/smbios/smbios.c
A include/qemu/uuid.h
M include/sysemu/sysemu.h
M qmp.c
M stubs/uuid.c
M util/Makefile.objs
A util/uuid.c
M vl.c
Log Message:
-----------
util: Add UUID API
A number of different places across the code base use CONFIG_UUID. Some
of them are soft dependency, some are not built if libuuid is not
available, some come with dummy fallback, some throws runtime error.
It is hard to maintain, and hard to reason for users.
Since UUID is a simple standard with only a small number of operations,
it is cleaner to have a central support in libqemuutil. This patch adds
qemu_uuid_* functions that all uuid users in the code base can
rely on. Except for qemu_uuid_generate which is new code, all other
functions are just copy from existing fallbacks from other files.
Note that qemu_uuid_parse is moved without updating the function
signature to use QemuUUID, to keep this patch simple.
Signed-off-by: Fam Zheng <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: Jeff Cody <address@hidden>
Message-Id: <address@hidden>
Commit: 3630be75d8eda7811f5783d1dc50f4d8682fdaec
https://github.com/qemu/qemu/commit/3630be75d8eda7811f5783d1dc50f4d8682fdaec
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M util/uuid.c
Log Message:
-----------
uuid: Make null_uuid static
So that it doesn't have to be zeroed at each call.
Suggested-by: Eric Blake <address@hidden>
Signed-off-by: Fam Zheng <address@hidden>
Reviewed-by: Jeff Cody <address@hidden>
Message-Id: <address@hidden>
Commit: cb6414dfec8a308e68529b0fd2a454403c05bbb3
https://github.com/qemu/qemu/commit/cb6414dfec8a308e68529b0fd2a454403c05bbb3
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M block/Makefile.objs
M block/vhdx-endian.c
M block/vhdx.c
M configure
Log Message:
-----------
vhdx: Use QEMU UUID API
This removes our dependency to libuuid, so that the driver can always be
built.
Similar to how we handled data plane configure options, --enable-vhdx
and --disable-vhdx are also changed to a nop with a message saying it's
obsolete.
Signed-off-by: Fam Zheng <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: Jeff Cody <address@hidden>
Message-Id: <address@hidden>
Commit: 7c6f55b69714a0cb9fdf5a80f0c23e87127e01a8
https://github.com/qemu/qemu/commit/7c6f55b69714a0cb9fdf5a80f0c23e87127e01a8
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M block/vdi.c
Log Message:
-----------
vdi: Use QEMU UUID API
The UUID operations we need from libuuid are fully supported by QEMU UUID
implementation. Use it, and remove the unused code.
Signed-off-by: Fam Zheng <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: Jeff Cody <address@hidden>
Message-Id: <address@hidden>
Commit: 38440a21fa662767e58db0d5f8b71a0e1f00dc46
https://github.com/qemu/qemu/commit/38440a21fa662767e58db0d5f8b71a0e1f00dc46
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M block/vpc.c
Log Message:
-----------
vpc: Use QEMU UUID API
Previously we conditionally generated footer->uuid, when libuuid was
available. Now that we have a built-in implementation, we can switch to
it.
Signed-off-by: Fam Zheng <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: Jeff Cody <address@hidden>
Message-Id: <address@hidden>
Commit: 2ef950f91d1c439da0aad6629521825523578dce
https://github.com/qemu/qemu/commit/2ef950f91d1c439da0aad6629521825523578dce
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M crypto/block-luks.c
Log Message:
-----------
crypto: Switch to QEMU UUID API
The uuid generation doesn't return error, so update the function
signature and calling code accordingly.
Signed-off-by: Fam Zheng <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: Jeff Cody <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Daniel P. Berrange <address@hidden>
Commit: 586d15ff873585ec9c229217eaec76f858f8f45a
https://github.com/qemu/qemu/commit/586d15ff873585ec9c229217eaec76f858f8f45a
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M tests/test-crypto-block.c
Log Message:
-----------
tests: No longer dependent on CONFIG_UUID
crypto now uses built-in uuid implementation, so this check is not
needed.
Signed-off-by: Fam Zheng <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: Jeff Cody <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Daniel P. Berrange <address@hidden>
Commit: 315d3184525c90865bf5e1ec4db5e633f1d8c7e8
https://github.com/qemu/qemu/commit/315d3184525c90865bf5e1ec4db5e633f1d8c7e8
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M configure
Log Message:
-----------
configure: Remove detection code for UUID
All code now uses built-in UUID implementation. Remove the code of
libuuid and make --enable-uuid and --disable-uuid only print a message.
Signed-off-by: Fam Zheng <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: Jeff Cody <address@hidden>
Message-Id: <address@hidden>
Commit: 9c5ce8db2e5c2769ed2fd3d91928dd1853b5ce7c
https://github.com/qemu/qemu/commit/9c5ce8db2e5c2769ed2fd3d91928dd1853b5ce7c
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M hw/ipmi/ipmi_bmc_sim.c
M hw/nvram/fw_cfg.c
M hw/ppc/spapr.c
M hw/ppc/spapr_rtas.c
M hw/smbios/smbios.c
M hw/xenpv/xen_domainbuild.c
M include/qemu/uuid.h
M include/sysemu/sysemu.h
M qmp.c
M ui/spice-core.c
M util/uuid.c
M vl.c
Log Message:
-----------
vl: Switch qemu_uuid to QemuUUID
Update all qemu_uuid users as well, especially get rid of the duplicated
low level g_strdup_printf, sscanf and snprintf calls with QEMU UUID API.
Since qemu_uuid_parse is quite tangled with qemu_uuid, its switching to
QemuUUID is done here too to keep everything in sync and avoid code
churn.
Signed-off-by: Fam Zheng <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: Jeff Cody <address@hidden>
Message-Id: <address@hidden>
Commit: 0d6ae94783b35a5c42d88872d1adb523f5fcc6f3
https://github.com/qemu/qemu/commit/0d6ae94783b35a5c42d88872d1adb523f5fcc6f3
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M util/uuid.c
Log Message:
-----------
uuid: Tighten uuid parse
sscanf is relatively loose (tolerate) on some invalid formats that we
should fail instead of generating a wrong uuid structure, like with
whitespaces and short strings.
Add and use a helper function to first check the format.
Signed-off-by: Fam Zheng <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: Jeff Cody <address@hidden>
Message-Id: <address@hidden>
Commit: c739cdddeb61d57470b3a7ecf6cea45064828269
https://github.com/qemu/qemu/commit/c739cdddeb61d57470b3a7ecf6cea45064828269
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M tests/Makefile.include
A tests/test-uuid.c
Log Message:
-----------
tests: Add uuid tests
Signed-off-by: Fam Zheng <address@hidden>
Reviewed-by: Jeff Cody <address@hidden>
Message-Id: <address@hidden>
Commit: 080d7aac31006092c8b85a784cfc4e3b525d9d33
https://github.com/qemu/qemu/commit/080d7aac31006092c8b85a784cfc4e3b525d9d33
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M MAINTAINERS
Log Message:
-----------
Add UUID files to MAINTAINERS
I understand that we've been keeping eyes on the uncovered files. Since
I'm adding some more files I volunteer to look after them in the futuer.
Signed-off-by: Fam Zheng <address@hidden>
Reviewed-by: Jeff Cody <address@hidden>
Message-Id: <address@hidden>
Commit: 65a03dd6c6b89223154e48193044577387e05dc2
https://github.com/qemu/qemu/commit/65a03dd6c6b89223154e48193044577387e05dc2
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M tests/.gitignore
Log Message:
-----------
tests: Ignore test-uuid
Signed-off-by: Fam Zheng <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Jeff Cody <address@hidden>
Reviewed-by: Daniel P. Berrange <address@hidden>
Commit: a34ac8d472a36582e8aaf93688cee62b4cac4201
https://github.com/qemu/qemu/commit/a34ac8d472a36582e8aaf93688cee62b4cac4201
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M tests/docker/dockerfiles/centos6.docker
Log Message:
-----------
docker: Generate /packages.txt in centos6 image
Put the list of package names in an environment, and output their
package names to the target file in the end.
Signed-off-by: Fam Zheng <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Daniel P. Berrange <address@hidden>
Commit: 28a0cccd544983273c0178e4b198e781cb01e074
https://github.com/qemu/qemu/commit/28a0cccd544983273c0178e4b198e781cb01e074
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M tests/docker/dockerfiles/fedora.docker
Log Message:
-----------
docker: Generate /packages.txt in fedora image
Put the list of package names in an environment, and output their
package names to the target file in the end.
Signed-off-by: Fam Zheng <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Daniel P. Berrange <address@hidden>
Commit: 5008fc787b9d923f937c71d3dbe0d8ef88875c91
https://github.com/qemu/qemu/commit/5008fc787b9d923f937c71d3dbe0d8ef88875c91
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M tests/docker/dockerfiles/ubuntu.docker
Log Message:
-----------
docker: Generate /packages.txt in ubuntu image
Put the list of package names in an environment, and output their
package names to the target file in the end.
Signed-off-by: Fam Zheng <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Daniel. P. Berrange <address@hidden>
Commit: a2bd7252fe8b43367d2f7d054154ffc56d6dd377
https://github.com/qemu/qemu/commit/a2bd7252fe8b43367d2f7d054154ffc56d6dd377
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M tests/docker/dockerfiles/fedora.docker
Log Message:
-----------
docker: Update fedora image to latest
Now that 23 is becoming an "old" release with 24 available. Fedora has a
quick release cycle, so use latest to follow more closely.
Signed-off-by: Fam Zheng <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Daniel P. Berrange <address@hidden>
Commit: 3d3a6eb60d259a503ed771c878f777e2715d83db
https://github.com/qemu/qemu/commit/3d3a6eb60d259a503ed771c878f777e2715d83db
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M tests/docker/test-quick
Log Message:
-----------
docker: Flatten default target list in test-quick
Previously it is expanded to a whitespace separated list which is not
the most appropriate format. Since it's only two items, flatten it.
Signed-off-by: Fam Zheng <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Daniel P. Berrange <address@hidden>
Commit: 9445c28ec3753470554790debc6ac12609c3b733
https://github.com/qemu/qemu/commit/9445c28ec3753470554790debc6ac12609c3b733
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M tests/docker/common.rc
Log Message:
-----------
docker: Print used options before doing configure
This makes the configure command more obvious which usually has useful
information.
Signed-off-by: Fam Zheng <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Daniel P. Berrange <address@hidden>
Commit: ec960b9a73f48b8b0bc7d5d31a173e90bd38a290
https://github.com/qemu/qemu/commit/ec960b9a73f48b8b0bc7d5d31a173e90bd38a290
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M tests/docker/Makefile.include
M tests/docker/run
Log Message:
-----------
docker: Support showing environment information
Add a make variable SHOW_ENV. When it's set to non empty, print the
package information and environment variables.
Signed-off-by: Fam Zheng <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Daniel P. Berrange <address@hidden>
Commit: 97cba1a1d1e62ea3e2718ad22188d10f2aa5478d
https://github.com/qemu/qemu/commit/97cba1a1d1e62ea3e2718ad22188d10f2aa5478d
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M tests/docker/docker.py
Log Message:
-----------
docker: Terminate instances at SIGTERM and SIGHUP
Signed-off-by: Fam Zheng <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Daniel P. Berrange <address@hidden>
Commit: 9b77336d83b73f7585cc2dbc565d377940905191
https://github.com/qemu/qemu/commit/9b77336d83b73f7585cc2dbc565d377940905191
Author: Fam Zheng <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M tests/docker/run
Log Message:
-----------
docker: exec $CMD
This is the last command to run (unless DEBUG), make it 'exec' to
simplify the process tree.
Signed-off-by: Fam Zheng <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Daniel P. Berrange <address@hidden>
Commit: 4c892756fd133b77a5aca4745a15528a6bf5bc94
https://github.com/qemu/qemu/commit/4c892756fd133b77a5aca4745a15528a6bf5bc94
Author: Peter Maydell <address@hidden>
Date: 2016-09-23 (Fri, 23 Sep 2016)
Changed paths:
M MAINTAINERS
M arch_init.c
M block/Makefile.objs
M block/iscsi.c
M block/vdi.c
M block/vhdx-endian.c
M block/vhdx.c
M block/vpc.c
M configure
M crypto/block-luks.c
M hw/ipmi/ipmi_bmc_sim.c
M hw/nvram/fw_cfg.c
M hw/ppc/spapr.c
M hw/ppc/spapr_rtas.c
M hw/smbios/smbios.c
M hw/xenpv/xen_domainbuild.c
A include/qemu/uuid.h
M include/sysemu/sysemu.h
M qmp.c
M stubs/uuid.c
M tests/.gitignore
M tests/Makefile.include
M tests/docker/Makefile.include
M tests/docker/common.rc
M tests/docker/docker.py
M tests/docker/dockerfiles/centos6.docker
M tests/docker/dockerfiles/fedora.docker
M tests/docker/dockerfiles/ubuntu.docker
M tests/docker/run
M tests/docker/test-quick
M tests/test-crypto-block.c
A tests/test-uuid.c
M ui/spice-core.c
M util/Makefile.objs
A util/uuid.c
M vl.c
Log Message:
-----------
Merge remote-tracking branch 'remotes/famz/tags/various-pull-request' into
staging
# gpg: Signature made Fri 23 Sep 2016 05:58:28 BST
# gpg: using RSA key 0xCA35624C6A9171C6
# gpg: Good signature from "Fam Zheng <address@hidden>"
# gpg: WARNING: This key is not certified with a trusted signature!
# gpg: There is no indication that the signature belongs to the owner.
# Primary key fingerprint: 5003 7CB7 9706 0F76 F021 AD56 CA35 624C 6A91 71C6
* remotes/famz/tags/various-pull-request: (23 commits)
docker: exec $CMD
docker: Terminate instances at SIGTERM and SIGHUP
docker: Support showing environment information
docker: Print used options before doing configure
docker: Flatten default target list in test-quick
docker: Update fedora image to latest
docker: Generate /packages.txt in ubuntu image
docker: Generate /packages.txt in fedora image
docker: Generate /packages.txt in centos6 image
tests: Ignore test-uuid
Add UUID files to MAINTAINERS
tests: Add uuid tests
uuid: Tighten uuid parse
vl: Switch qemu_uuid to QemuUUID
configure: Remove detection code for UUID
tests: No longer dependent on CONFIG_UUID
crypto: Switch to QEMU UUID API
vpc: Use QEMU UUID API
vdi: Use QEMU UUID API
vhdx: Use QEMU UUID API
...
Signed-off-by: Peter Maydell <address@hidden>
# Conflicts:
# tests/Makefile.include
Compare: https://github.com/qemu/qemu/compare/6de68ffd7cfd...4c892756fd13
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Qemu-commits] [qemu/qemu] 0679f9: docker: Handle exceptions when looking for docker ...,
GitHub <=