Skip to contentSkip to conversation

add the py2 version for python-docker and python-docker-pycreds packages

PATCH In review Ting Yu 2 participants 2 messages Dec 13, 2018 – Dec 21, 2018

lore
Share & tools
lore

Ting Yu

author
#0 lore raw

PATCH 1/1 add the py2 version for python-docker and python-docker-pycreds packages

add the py2 version for python-docker and python-docker-pycreds packages. add python-six and python-backport_ssl (for ph2 only) as python-docker dependencies.

verify the connection to docker engine at run time -

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

import docker
client = docker.from_env()
client.images.list()

[<Image: 'hello-world:latest'>]

---
 recipes-devtools/python/python-docker-pycreds.inc       |  7 +++++++
 recipes-devtools/python/python-docker-pycreds_0.3.0.bb  |  3 +++
 recipes-devtools/python/python-docker.inc               | 14 ++++++++++++++
 recipes-devtools/python/python-docker_3.4.0.bb          |  6 ++++++
 recipes-devtools/python/python3-docker-pycreds_0.3.0.bb |  8 +-------
 recipes-devtools/python/python3-docker_3.4.0.bb         | 16 +---------------
 6 files changed, 32 insertions(+), 22 deletions(-)
 create mode 100644 recipes-devtools/python/python-docker-pycreds.inc
 create mode 100644 recipes-devtools/python/python-docker-pycreds_0.3.0.bb
 create mode 100644 recipes-devtools/python/python-docker.inc
 create mode 100644 recipes-devtools/python/python-docker_3.4.0.bb
recipes-devtools/python/python-docker-pycreds.inc new file +7 -0
new file mode 100644
index 0000000..ca0995f
@@ -0,0 +1,7 @@
+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"
+
+SRC_URI[md5sum] = "2370ea3b62198b788a26231ab58844af"
+SRC_URI[sha256sum] = "8b0e956c8d206f832b06aa93a710ba2c3bcbacb5a314449c040b0b814355bbff"
recipes-devtools/python/python-docker-pycreds_0.3.0.bb new file +3 -0
new file mode 100644
index 0000000..6dc4521
@@ -0,0 +1,3 @@
+inherit pypi setuptools
+require python-docker-pycreds.inc
+
recipes-devtools/python/python-docker.inc new file +14 -0
new file mode 100644
index 0000000..eec7cda
@@ -0,0 +1,14 @@
+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"
+
+SRC_URI[md5sum] = "02491d168c048cdb99cc20d0b352ea0f"
+SRC_URI[sha256sum] = "e9cc39e24905e67ba9e2df14c94488f5cf030fb72ae1c60de505ce5ea90503f7"
+
+RDEPENDS_${PN} += " \
+	${PYTHON_PN}-six \
+	${PYTHON_PN}-docker-pycreds \
+	${PYTHON_PN}-requests \
+	${PYTHON_PN}-websocket-client \
+"
recipes-devtools/python/python-docker_3.4.0.bb new file +6 -0
new file mode 100644
index 0000000..a964254
@@ -0,0 +1,6 @@
+inherit pypi setuptools
+require python-docker.inc
+
+RDEPENDS_${PN} += " \
+                   python-backports-ssl \
+                  "
recipes-devtools/python/python3-docker-pycreds_0.3.0.bb +1 -7
index 4d39f52..75a83e0 100644
@@ -1,9 +1,3 @@
-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 setuptools3
+require python-docker-pycreds.inc
 
-SRC_URI[md5sum] = "2370ea3b62198b788a26231ab58844af"
-SRC_URI[sha256sum] = "8b0e956c8d206f832b06aa93a710ba2c3bcbacb5a314449c040b0b814355bbff"
recipes-devtools/python/python3-docker_3.4.0.bb +1 -15
index 6e81302..052cbe8 100644
@@ -1,17 +1,3 @@
-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 setuptools3
-
-SRC_URI[md5sum] = "02491d168c048cdb99cc20d0b352ea0f"
-SRC_URI[sha256sum] = "e9cc39e24905e67ba9e2df14c94488f5cf030fb72ae1c60de505ce5ea90503f7"
-
 DEPENDS += "${PYTHON_PN}-pip-native"
-
-RDEPENDS_${PN} += " \
-	python3-docker-pycreds \
-	python3-requests \
-	python3-websocket-client \
-"
+require python-docker.inc
Signature · 1 line
2.7.4
#1 lore raw

sorry for the delay, I was waiting to see if anyone else had comments and then forgot to loop back to this!

The change looks good to me, and tested ok in my setup.

This is now merged.

Bruce

Quoted 123 lines · Ting Yu

add the py2 version for python-docker and python-docker-pycreds packages. add python-six and python-backport_ssl (for ph2 only) as python-docker dependencies.

verify the connection to docker engine at run time -

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

import docker
client = docker.from_env()
client.images.list()

[<Image: 'hello-world:latest'>]

---
 recipes-devtools/python/python-docker-pycreds.inc       |  7 +++++++
 recipes-devtools/python/python-docker-pycreds_0.3.0.bb  |  3 +++
 recipes-devtools/python/python-docker.inc               | 14 ++++++++++++++
 recipes-devtools/python/python-docker_3.4.0.bb          |  6 ++++++
 recipes-devtools/python/python3-docker-pycreds_0.3.0.bb |  8 +-------
 recipes-devtools/python/python3-docker_3.4.0.bb         | 16 +---------------
 6 files changed, 32 insertions(+), 22 deletions(-)
 create mode 100644 recipes-devtools/python/python-docker-pycreds.inc
 create mode 100644 recipes-devtools/python/python-docker-pycreds_0.3.0.bb
 create mode 100644 recipes-devtools/python/python-docker.inc
 create mode 100644 recipes-devtools/python/python-docker_3.4.0.bb
recipes-devtools/python/python-docker-pycreds.inc new file +7 -0
new file mode 100644
index 0000000..ca0995f
@@ -0,0 +1,7 @@
+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"
+
+SRC_URI[md5sum] = "2370ea3b62198b788a26231ab58844af"
+SRC_URI[sha256sum] = "8b0e956c8d206f832b06aa93a710ba2c3bcbacb5a314449c040b0b814355bbff"
recipes-devtools/python/python-docker-pycreds_0.3.0.bb new file +3 -0
new file mode 100644
index 0000000..6dc4521
@@ -0,0 +1,3 @@
+inherit pypi setuptools
+require python-docker-pycreds.inc
+
recipes-devtools/python/python-docker.inc new file +14 -0
new file mode 100644
index 0000000..eec7cda
@@ -0,0 +1,14 @@
+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"
+
+SRC_URI[md5sum] = "02491d168c048cdb99cc20d0b352ea0f"
+SRC_URI[sha256sum] = "e9cc39e24905e67ba9e2df14c94488f5cf030fb72ae1c60de505ce5ea90503f7"
+
+RDEPENDS_${PN} += " \
+       ${PYTHON_PN}-six \
+       ${PYTHON_PN}-docker-pycreds \
+       ${PYTHON_PN}-requests \
+       ${PYTHON_PN}-websocket-client \
+"
recipes-devtools/python/python-docker_3.4.0.bb new file +6 -0
new file mode 100644
index 0000000..a964254
@@ -0,0 +1,6 @@
+inherit pypi setuptools
+require python-docker.inc
+
+RDEPENDS_${PN} += " \
+                   python-backports-ssl \
+                  "
recipes-devtools/python/python3-docker-pycreds_0.3.0.bb +1 -7
index 4d39f52..75a83e0 100644
@@ -1,9 +1,3 @@
-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 setuptools3
+require python-docker-pycreds.inc
 
-SRC_URI[md5sum] = "2370ea3b62198b788a26231ab58844af"
-SRC_URI[sha256sum] = "8b0e956c8d206f832b06aa93a710ba2c3bcbacb5a314449c040b0b814355bbff"
recipes-devtools/python/python3-docker_3.4.0.bb +1 -16
index 6e81302..052cbe8 100644
@@ -1,17 +1,3 @@
-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 setuptools3
-
-SRC_URI[md5sum] = "02491d168c048cdb99cc20d0b352ea0f"
-SRC_URI[sha256sum] = "e9cc39e24905e67ba9e2df14c94488f5cf030fb72ae1c60de505ce5ea90503f7"
-
 DEPENDS += "${PYTHON_PN}-pip-native"
-
-RDEPENDS_${PN} += " \
-       python3-docker-pycreds \
-       python3-requests \
-       python3-websocket-client \
-"
+require python-docker.inc
--

2.7.4

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

Signature · 3 lines
- Thou shalt not follow the NULL pointer, for chaos and madness await
thee at its end
- "Use the force Harry" - Gandalf, Star Trek II