diff options
author | Scott Moser <smoser@ubuntu.com> | 2011-01-19 05:20:26 +0000 |
---|---|---|
committer | Scott Moser <smoser@ubuntu.com> | 2011-01-19 05:20:26 +0000 |
commit | 738766778c88bcfe692f8df17f91c4d5c6c90cdd (patch) | |
tree | 2562517fdbdfa818fa4b7ad1cdc3ea1071274349 /cloudinit/util.py | |
parent | b85106a10a78e4c15303ac3b9b16d03a3f2f9cab (diff) | |
download | vyos-cloud-init-738766778c88bcfe692f8df17f91c4d5c6c90cdd.tar.gz vyos-cloud-init-738766778c88bcfe692f8df17f91c4d5c6c90cdd.zip |
support $MIRROR and $RELEASE in apt-source cloud-config lines (LP: #693292)
sources can use $MIRROR and $RELEASE and they will be replaced
with the local mirror for this cloud, and the running release
this:
- source: deb $MIRROR $RELEASE multiverse
would possibly be turned into:
- source: deb http://us-east-1.ec2.archive.ubuntu.com/ubuntu natty multiverse
LP: #693292
Diffstat (limited to 'cloudinit/util.py')
-rw-r--r-- | cloudinit/util.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/cloudinit/util.py b/cloudinit/util.py index 7c9e60d5..d5ae2bec 100644 --- a/cloudinit/util.py +++ b/cloudinit/util.py @@ -136,6 +136,10 @@ def render_to_file(template, outfile, searchList): f.write(t.respond()) f.close() +def render_string(template, searchList): + return(Template(template, searchList=[searchList]).respond()) + + # read_optional_seed # returns boolean indicating success or failure (presense of files) # if files are present, populates 'fill' dictionary with 'user-data' and |