Skip to content
This repository
Browse code

Skip dummy earlier to really not sync anything to it

  • Loading branch information...
commit 37f0e42940470561a2c2eb1f4ba33814e116feb7 1 parent 2a4d975
Miquel Torres authored June 14, 2012

Showing 1 changed file with 3 additions and 3 deletions. Show diff stats Hide diff stats

  1. 6  littlechef/chef.py
6  littlechef/chef.py
@@ -69,6 +69,9 @@ def sync_node(node):
69 69
     It also injects the ipaddress to the node's config file if not already
70 70
     existent.
71 71
     """
  72
+    if node.get('dummy'):
  73
+        lib.print_header("Skipping dummy: {0}".format(env.host))
  74
+        return
72 75
     # Get merged attributes
73 76
     current_node = _build_node_data_bag()
74 77
     with lib.credentials():
@@ -98,9 +101,6 @@ def _synchronize_node(configfile, node):
98 101
     Returns the node object of the node which is about to be configured,
99 102
     or None if this node object cannot be found.
100 103
     """
101  
-    if node.get('dummy'):
102  
-        lib.print_header("Skipping dummy: {0}".format(env.host))
103  
-        return
104 104
     print "Synchronizing node, cookbooks, roles and data bags..."
105 105
     # First upload node.json
106 106
     remote_file = '/etc/chef/node.json'

0 notes on commit 37f0e42

Please sign in to comment.
Something went wrong with that request. Please try again.