diff -Nru python-novaclient-2.17.0/debian/changelog python-novaclient-2.17.0/debian/changelog --- python-novaclient-2.17.0/debian/changelog 2014-03-17 20:16:40.000000000 -0400 +++ python-novaclient-2.17.0/debian/changelog 2015-04-08 14:52:20.000000000 -0400 @@ -1,3 +1,10 @@ +python-novaclient (1:2.17.0-0ubuntu2) precise; urgency=low + + * FIX: Make sure binary files can be uploaded when booting a + vm. (LP: #1408088) + + -- Wed, 08 Apr 2015 14:51:27 -0400 + python-novaclient (1:2.17.0-0ubuntu1) trusty; urgency=medium * New upstream release. diff -Nru python-novaclient-2.17.0/debian/patches/0001-Directly-using-base64-encoding-for-injected-files.patch python-novaclient-2.17.0/debian/patches/0001-Directly-using-base64-encoding-for-injected-files.patch --- python-novaclient-2.17.0/debian/patches/0001-Directly-using-base64-encoding-for-injected-files.patch 1969-12-31 19:00:00.000000000 -0500 +++ python-novaclient-2.17.0/debian/patches/0001-Directly-using-base64-encoding-for-injected-files.patch 2015-04-08 14:50:16.000000000 -0400 @@ -0,0 +1,35 @@ +From f75ea86a2a4ee0bed076ee9e4ea5021eb0643e16 Mon Sep 17 00:00:00 2001 +From: Liang Chen +Date: Wed, 7 Jan 2015 13:23:10 -0500 +Subject: [PATCH] Directly using base64 encoding for injected files + +Binary files cannot be treated as utf-8 byte streams and converted +to plain. Change this back to just using base64 encoding as it was +before commit 8b264fc61d21fe4d0c7405914fb084f898956888. + +Change-Id: I4ef6142676022b2e2f3178e7bfa24ed985fcae2c +Closes-Bug: #1408088 +--- + novaclient/v1_1/servers.py | 4 +++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +diff --git a/v1_1/servers.py b/v1_1/servers.py +index cf284d9..42652ab 100644 +--- a/novaclient/v1_1/servers.py ++++ b/novaclient/v1_1/servers.py +@@ -490,9 +490,13 @@ class ServerManager(base.BootingManagerWithFind): + data = file_or_string.read() + else: + data = file_or_string ++ if six.PY3 and isinstance(data, str): ++ data = data.encode('utf-8') ++ cont = base64.b64encode(data).decode('utf-8') ++ + personality.append({ + 'path': filepath, +- 'contents': base64.b64encode(data.encode('utf-8')), ++ 'contents': cont, + }) + + if availability_zone: + diff -Nru python-novaclient-2.17.0/debian/patches/series python-novaclient-2.17.0/debian/patches/series --- python-novaclient-2.17.0/debian/patches/series 1969-12-31 19:00:00.000000000 -0500 +++ python-novaclient-2.17.0/debian/patches/series 2015-04-08 14:50:22.000000000 -0400 @@ -0,0 +1 @@ +0001-Directly-using-base64-encoding-for-injected-files.patch