removed create_variation function, not used any longer (it was converted into sls files)
authorPaul Tonelli <paul.tonelli@logilab.fr>
Tue, 26 Mar 2013 09:29:53 +0100
changeset 101 8b47c42308c4
parent 100 7a6ea6e5474c
child 102 c7a8e6075a8a
removed create_variation function, not used any longer (it was converted into sls files)
_modules/vm_create.py
--- a/_modules/vm_create.py	Tue Mar 26 09:29:02 2013 +0100
+++ b/_modules/vm_create.py	Tue Mar 26 09:29:53 2013 +0100
@@ -45,27 +45,6 @@
     log.info(_chroot_exec(path, 'salt-call  --local state.highstate'))
     return True
 
-def create_variation(path=DEFAULT_PATH):
-    '''
-    complete function to create the new variation from a virtual machine
-
-    CLI Example::
-
-        salt '*' vm_create.create_variation
-    '''
-    image_dirname = DEFAULT_MOUNT_DIR
-    ### Exec pre state here ###
-    log.info(__salt__['state.sls']('ami_pre'))
-    update_image(path + '/' + image_dirname)
-    variate_image(path + '/' + image_dirname)
-    log.info(__salt__['state.sls']('ami_post'))
-
-    if __salt__['grains.item']('keystone.user'): #true only if len>0
-        upload_to_glance(path)
-    else:
-        log.info('Image Not uploaded to glance !')
-    return True
-
 def upload_to_glance(path):
     log.info('will now try to upload to glance server')
     ami_name = __salt__['grains.item']('ami.name')