Skip to contentSkip to conversation

python-docker: Add recipe for python2

PATCH In review David Bensoussan 2 participants 3 messages Nov 21, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 python-docker: Add recipe for python2

This has been copied from the python3 recipe

---
 recipes-devtools/python/python-docker_2.5.1.bb | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)
 create mode 100644 recipes-devtools/python/python-docker_2.5.1.bb
recipes-devtools/python/python-docker_2.5.1.bb new file +18 -0
new file mode 100644
index 0000000..c0f3c89
@@ -0,0 +1,18 @@
+SUMMARY = "A Python library for the Docker Engine API."
+HOMEPAGE = "https://github.com/docker/docker-py"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=34f3846f940453127309b920eeb89660"
+
+inherit pypi setuptools
+
+SRC_URI[md5sum] = "7d917152976df075e6e90ee853df641f"
+SRC_URI[sha256sum] = "b876e6909d8d2360e0540364c3a952a62847137f4674f2439320ede16d6db880"
+
+DEPENDS += "${PYTHON_PN}-pip-native"
+
+RDEPENDS_${PN} += " \
+	python-backports-ssl \
+	python-docker-pycreds \
+	python-requests \
+	python-websocket-client \
+"
Signature · 1 line
2.7.4
#1 lore raw

PATCH 2/2 python-docker-pycreds: Add recipe for python2

This has been copied from the python3 recipe

---
 recipes-devtools/python/python-docker-pycreds_0.2.1.bb | 9 +++++++++
 1 file changed, 9 insertions(+)
 create mode 100644 recipes-devtools/python/python-docker-pycreds_0.2.1.bb
recipes-devtools/python/python-docker-pycreds_0.2.1.bb new file +9 -0
new file mode 100644
index 0000000..69791fa
@@ -0,0 +1,9 @@
+SUMMARY = "Python bindings for the docker credentials store API"
+HOMEPAGE = "https://github.com/shin-/dockerpy-creds"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
+
+inherit pypi setuptools
+
+SRC_URI[md5sum] = "0d80d5aebab771faf7e422b759c3055b"
+SRC_URI[sha256sum] = "93833a2cf280b7d8abbe1b8121530413250c6cd4ffed2c1cf085f335262f7348"
Signature · 1 line
2.7.4
#2 lore raw
In reply to David Bensoussan
Quoted 2 lines · David Bensoussan

This has been copied from the python3 recipe

This should be done by putting the common code into a .inc file and then having py2 and py3 specific recipes. Look at python-websocket-client in meta-virtualization or any of the tens of examples in meta-openembedded/meta-python. This saves duplicate code and allows any issues to generally only be fixed in one spot and avoiding cases where general changes are accidentally only merged to either the py2 version or py3 version and not the other.

Thanks,
Mark

Quoted 37 lines
---
 recipes-devtools/python/python-docker_2.5.1.bb | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)
 create mode 100644 recipes-devtools/python/python-docker_2.5.1.bb
recipes-devtools/python/python-docker_2.5.1.bb new file +18 -1
new file mode 100644
index 0000000..c0f3c89
@@ -0,0 +1,18 @@
+SUMMARY = "A Python library for the Docker Engine API."
+HOMEPAGE = "https://github.com/docker/docker-py"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=34f3846f940453127309b920eeb89660"
+
+inherit pypi setuptools
+
+SRC_URI[md5sum] = "7d917152976df075e6e90ee853df641f"
+SRC_URI[sha256sum] = "b876e6909d8d2360e0540364c3a952a62847137f4674f2439320ede16d6db880"
+
+DEPENDS += "${PYTHON_PN}-pip-native"
+
+RDEPENDS_${PN} += " \
+       python-backports-ssl \
+       python-docker-pycreds \
+       python-requests \
+       python-websocket-client \
+"
--

2.7.4

--
_______________________________________________
meta-virtualization mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/meta-virtualization