diff --git a/.atomic.metadata b/.atomic.metadata index 757ade9..b0b7409 100644 --- a/.atomic.metadata +++ b/.atomic.metadata @@ -1 +1 @@ -1637965eeec076e8e40eb4af5a675f4c27515b39 SOURCES/241adc115aa6e7975e180c3d97e2e6be4bf38325.tar.gz +1458906736f85b87b65cf410d286afd7a565e4c3 SOURCES/2760e30296884e9160ff0b8e58c2e5d47791f01d.tar.gz diff --git a/.gitignore b/.gitignore index 731efdb..0cd7448 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1 @@ -SOURCES/241adc115aa6e7975e180c3d97e2e6be4bf38325.tar.gz +SOURCES/2760e30296884e9160ff0b8e58c2e5d47791f01d.tar.gz diff --git a/SOURCES/0001.patch b/SOURCES/0001.patch new file mode 100644 index 0000000..cde5b88 --- /dev/null +++ b/SOURCES/0001.patch @@ -0,0 +1,68 @@ +From f5e4b38043ce566da472853d48382c5c1f7871f2 Mon Sep 17 00:00:00 2001 +From: Brent Baude +Date: Mon, 22 May 2017 13:41:55 -0500 +Subject: [PATCH] Atomic/util.py: Add logic to install lookup for shortnames + +If a shortname is used to run an image, we need to transform the short +name into the fq-name when doing the lookup in the installed images +data. + +Reported in BZ #1454292 +--- + Atomic/backends/_docker.py | 9 +++++++-- + Atomic/util.py | 13 +++++++++++-- + 2 files changed, 18 insertions(+), 4 deletions(-) + +diff --git a/Atomic/backends/_docker.py b/Atomic/backends/_docker.py +index 53a67adc..04659eed 100644 +--- a/Atomic/backends/_docker.py ++++ b/Atomic/backends/_docker.py +@@ -467,10 +467,15 @@ def uninstall(self, iobject, name=None, **kwargs): + atomic.display(cmd) + if args.display: + return 0 +- if cmd: +- return util.check_call(cmd, env=atomic.cmd_env()) + + install_data = util.InstallData.get_install_data_by_id(iobject.id) ++ ++ if cmd: ++ result = util.check_call(cmd, env=atomic.cmd_env()) ++ if result == 0: ++ util.InstallData.delete_by_id(iobject.id, ignore=ignore) ++ return result ++ + system_package_nvra = install_data.get("system_package_nvra", None) + if system_package_nvra: + RPMHostInstall.uninstall_rpm(system_package_nvra) +diff --git a/Atomic/util.py b/Atomic/util.py +index f6116bb8..5f6590f8 100644 +--- a/Atomic/util.py ++++ b/Atomic/util.py +@@ -857,8 +857,11 @@ def read_install_data(cls): + def write_install_data(cls, new_data): + install_data = cls.read_install_data() + with file_lock(ATOMIC_INSTALL_JSON): +- for x in new_data: +- install_data[x] = new_data[x] ++ if len(new_data) < 1: ++ install_data = {} ++ else: ++ for x in new_data: ++ install_data[x] = new_data[x] + temp_file = tempfile.NamedTemporaryFile(mode='w', delete=False) + json.dump(install_data, temp_file) + temp_file.close() +@@ -908,6 +911,12 @@ def image_installed(cls, img_object): + return True + if install_data.get("{}:{}".format(img_object.input_name, img_object.tag), None): + return True ++ try: ++ from Atomic.discovery import RegistryInspectError ++ if install_data.get(img_object.fq_name, None): ++ return True ++ except RegistryInspectError: ++ pass + return False + + class Decompose(object): diff --git a/SPECS/atomic.spec b/SPECS/atomic.spec index 7444734..7ff500c 100644 --- a/SPECS/atomic.spec +++ b/SPECS/atomic.spec @@ -13,17 +13,18 @@ %global pylint python3-pylint %endif -%global commit0 241adc115aa6e7975e180c3d97e2e6be4bf38325 +%global commit0 2760e30296884e9160ff0b8e58c2e5d47791f01d %global shortcommit0 %(c=%{commit0}; echo ${c:0:7}) Name: atomic Epoch: 1 -Version: 1.16.5 -Release: 1%{?dist} +Version: 1.17.2 +Release: 4.git%{shortcommit0}%{?dist} Summary: Tool for managing ProjectAtomic systems and containers License: LGPLv2+ URL: https://github.com/projectatomic/%{name} Source0: https://github.com/projectatomic/%{name}/archive/%{commit0}.tar.gz +Patch0001: 0001.patch BuildRequires: %{pypkg}-dateutil BuildRequires: %{pypkg}-devel @@ -60,6 +61,7 @@ Requires: skopeo-containers >= 1:0.1.17-1 Requires: PyYAML Requires: gomtree Requires: ostree +Requires: runc %description The goal of Atomic is to provide a high level, coherent entrypoint to the @@ -76,6 +78,7 @@ if [ %{pypkg} == 'python3' ]; then sed -i 's/input = raw_input/pass/' Atomic/util.py fi + %build make PYTHON=%{__python} python-build docs dockertar-sha256-helper gotar @@ -130,6 +133,34 @@ rm -rf %{buildroot}%{_sysconfdir}/containers %dir %{_sysconfdir}/%{name}.d %changelog +* Mon May 22 2017 bbaude - 1:1.17.2-4.git2760e30 +- Add patch to resolve BZ # 1454292 + +* Wed May 17 2017 bbaude - 1:1.17.2-3.git77ef28f +- requires: runc + +* Tue May 16 2017 bbaude - 1:1.17.2-2.git77ef28f +- Fixes BZ# 1450307 +- Fixes BZ# 1451375 +- Fixes BZ# 1450307 + +* Fri May 12 2017 bbaude - 1:1.17.1-2.gitf304570 +- Add integration test for uninstall +- Bugzilla #1430708 +- Bugzilla #1447848 +- Issue #995 +- Issue #993 +- Issue #990 + + +* Thu Apr 20 2017 Brent Baude - 1.17.1-1 +- bump to 1.17.1 +- Use proxy from environment variable or config file +- Allow anonymous push +- Allow for profiling data to be generated +- BZ: 1432543 +- Various bug fixes + * Tue Mar 21 2017 Dan Walsh - 1.16.5-1 - bump to v1.16.5 - Fix outdated container image message (BZ 1434430)