Install cloudinit specific files that are loaded into the mime userdata

Partially fixes Issue #48

Signed-off-by: Steven Dake <sdake@redhat.com>
This commit is contained in:
Steven Dake 2012-04-12 13:33:27 -07:00
parent af451c2074
commit 797ea880d9
3 changed files with 25 additions and 0 deletions

View File

@ -16,6 +16,8 @@ include heat/jeos/F17-x86_64-cfntools-jeos.tdl
include heat/cfntools/cfn-init
include heat/cfntools/cfn-hup
include heat/cfntools/cfn-signal
include heat/cloudinit/config
include heat/cloudinit/part-handler.py
include heat/db/sqlalchemy/migrate_repo/migrate.cfg
graft etc
graft docs

9
heat/cloudinit/config Normal file
View File

@ -0,0 +1,9 @@
#cloud-config
cloud_config_modules:
- locale
- scripts_user
- set_hostname
- ssh
- timezone
- update_etc_hosts
- update_hostname

View File

@ -0,0 +1,14 @@
#part-handler
def list_types():
return(["text/x-cfninitdata"])
def handle_part(data,ctype,filename,payload):
if ctype == "__begin__":
return
if ctype == "__end__":
return
if ctype == 'text/x-cfninitdata':
f = open('/var/lib/cloud/data/%s' % filename, 'w')
f.write(payload)
f.close()