Fixed credentials in sync_slivers

Conflicts:
	planetstack/openstack_observer/steps/sync_slivers.yaml
diff --git a/planetstack/openstack_observer/steps/sync_slivers.py b/planetstack/openstack_observer/steps/sync_slivers.py
index de2c919..431ddf9 100644
--- a/planetstack/openstack_observer/steps/sync_slivers.py
+++ b/planetstack/openstack_observer/steps/sync_slivers.py
@@ -92,9 +92,9 @@
 	    
 	sliver_name = '@'.join([sliver.slice.name,sliver.node.name])
 	tenant_fields = {'endpoint':sliver.node.controller.auth_url,
-		     'admin_user': sliver.node.controller.admin_user,
-		     'admin_password': sliver.node.controller.admin_password,
-		     'admin_tenant': 'admin',
+		     'admin_user': sliver.creator.username,
+		     'admin_password': sliver.creator.password,
+		     'admin_tenant': sliver.slice.name,
 		     'tenant': sliver.slice.name,
 		     'tenant_description': sliver.slice.description,
 		     'name':sliver_name,
diff --git a/planetstack/openstack_observer/steps/sync_slivers.yaml b/planetstack/openstack_observer/steps/sync_slivers.yaml
index 6085434..9ec5283 100644
--- a/planetstack/openstack_observer/steps/sync_slivers.yaml
+++ b/planetstack/openstack_observer/steps/sync_slivers.yaml
@@ -2,6 +2,7 @@
 - hosts: 127.0.0.1
   connection: local
   tasks:
+  {% if not delete %}
   - nova_keypair:
       state: present
       auth_url: {{ endpoint }}
@@ -10,15 +11,18 @@
       login_tenant_name: {{ admin_tenant }}
       name: {{ key_name }}
       public_key: "{{ key.public_key}}"
-
+  {% endif %}
   - nova_compute:
-      state: present
       auth_url: {{ endpoint }}
       login_username: {{ admin_user }}
       login_password: {{ admin_password }}
       login_tenant_name: {{ admin_tenant }}
-      availability_zone: {{ availability_zone }}
       name: {{ name }}
+      {% if delete %}
+      state: absent
+      {% else %}
+      state: present
+      availability_zone: {{ availability_zone }}
       image_id: {{ image_id }}
       key_name: {{ key_name }}
       wait_for: 200
@@ -35,3 +39,22 @@
           {{ k }} : "{{ v }}"
       {% endfor %}
       {% endif %}
+      {% else %}
+      state: present
+      image_id: {{ image_id }}
+      key_name: {{ key_name }}
+      wait_for: 200
+      flavor_id: {{ flavor_id }}
+      user_data: "{{ user_data }}"
+      nics:
+      {% for net in nics %}  
+        - net-id: {{ net }}
+      {% endfor %}
+
+      {% if meta %}
+      meta:
+      {% for k,v in meta.items() %}  
+        {{ k }} : "{{ v }}"
+      {% endfor %}
+      {% endif %}
+      {% endif %}