=== added file 'debian/patches/lp-1244355-cloudarchive.patch'
--- debian/patches/lp-1244355-cloudarchive.patch	1970-01-01 00:00:00 +0000
+++ debian/patches/lp-1244355-cloudarchive.patch	2014-01-30 22:33:15 +0000
@@ -0,0 +1,95 @@
+=== modified file 'cloudinit/CloudConfig/cc_apt_update_upgrade.py'
+--- /tmp/bzr-diff-AbaRRS/old/cloudinit/CloudConfig/cc_apt_update_upgrade.py	2013-08-14 14:36:41.000000000 +0000
++++ /home/ubuntu/cloud-init-pp/cloudinit/CloudConfig/cc_apt_update_upgrade.py	2014-01-30 21:12:25.224087012 +0000
+@@ -27,6 +27,8 @@
+ import re
+ 
+ 
++ADD_APT_REPO_MATCH = r'^[\w-]+:\w'
++
+ def handle(name, cfg, cloud, log, _args):
+     update = util.get_cfg_option_bool(cfg, 'apt_update', False)
+     upgrade = util.get_cfg_option_bool(cfg, 'apt_upgrade', False)
+@@ -72,7 +74,15 @@
+         params = mirrors
+         params['RELEASE'] = release
+         params['MIRROR'] = mirror
+-        errors = add_sources(cfg['apt_sources'], params)
++
++        matchcfg = cfg.get('add_apt_repo_match', ADD_APT_REPO_MATCH)
++        if matchcfg:
++            matcher = re.compile(matchcfg).search
++        else:
++            matcher = lambda f: False
++
++        errors = add_sources(cfg['apt_sources'], params,
++                             aa_repo_match=matcher)
+         for e in errors:
+             log.warn("Source Error: %s\n" % ':'.join(e))
+ 
+@@ -157,7 +167,7 @@
+     util.render_to_file('sources.list', '/etc/apt/sources.list', params)
+ 
+ 
+-def add_sources(srclist, searchList=None):
++def add_sources(srclist, searchList=None, aa_repo_match=None):
+     """
+     add entries in /etc/apt/sources.list.d for each abbreviated
+     sources.list entry in 'srclist'.  When rendering template, also
+@@ -165,6 +175,10 @@
+     """
+     if searchList is None:
+         searchList = {}
++
++    if aa_repo_match is None:
++        aa_repo_match = lambda f: False
++
+     elst = []
+ 
+     for ent in srclist:
+@@ -173,14 +187,14 @@
+             continue
+ 
+         source = ent['source']
+-        if source.startswith("ppa:"):
++        source = util.render_string(source, searchList)
++        if aa_repo_match(source):
+             try:
+                 util.subp(["add-apt-repository", source])
+-            except:
+-                elst.append([source, "add-apt-repository failed"])
++            except util.ProcessExecutionError as e:
++                elst.append([source, "add-apt-repository failed" + str(e)])
+             continue
+ 
+-        source = util.render_string(source, searchList)
+ 
+         if 'filename' not in ent:
+             ent['filename'] = 'cloud_config_sources.list'
+=== modified file 'debian/changelog'
+--- /tmp/bzr-diff-AbaRRS/old/debian/changelog	2014-01-29 15:55:39.598000000 +0000
++++ /home/ubuntu/cloud-init-pp/debian/changelog	2014-01-30 20:57:38.884092236 +0000
+@@ -1,3 +1,9 @@
++cloud-init (0.6.3-0ubuntu1.11) precise; urgency=low
++
++  * support apt-add-archive with 'cloud-archive:' foramt.  (LP: #1244355)
++
++ -- Jay R. Wren <jrwren@xmtp.net>  Thu, 30 Jan 2014 20:57:09 +0000
++
+ cloud-init (0.6.3-0ubuntu1.10) precise-proposed; urgency=low
+ 
+   * debian/patches/lp-1272115-fix_smartos_compliance.patch: Fix compliance for
+=== modified file 'doc/examples/cloud-config.txt'
+--- /tmp/bzr-diff-AbaRRS/old/doc/examples/cloud-config.txt	2012-11-12 17:01:54.000000000 +0000
++++ /home/ubuntu/cloud-init-pp/doc/examples/cloud-config.txt	2014-01-30 21:13:20.628091732 +0000
+@@ -64,6 +64,10 @@
+ # then apt_mirror above will have no effect
+ apt_preserve_sources_list: true
+ 
++# 'source entries in apt-sources that match this python regex
++# expression will be passed to add-apt-repository
++add_apt_repo_match = "^[\w-]+:\w"
++
+ apt_sources:
+  - source: "deb http://ppa.launchpad.net/byobu/ppa/ubuntu karmic main"
+    keyid: F430BBA5 # GPG key ID published on a key server

=== modified file 'debian/patches/series'
--- debian/patches/series	2014-01-28 19:43:59 +0000
+++ debian/patches/series	2014-01-30 22:33:15 +0000
@@ -18,3 +18,4 @@
 lp-1233315-1231490-ephmeralX.Y-support.patch
 lp-1247262-fix_futils_smartos.patch
 lp-1272115-fix_smartos_compliance.patch
+lp-1244355-cloudarchive.patch

