title: how to use a 'not_if' condition on a template resource
body: <p>I'm trying to use a 'not_if' condition in a template resource as showcased by <a href="https://docs.chef.io/resource_template.html" rel="nofollow noreferrer">docs.chef.io</a></p>
  <pre><code>template &quot;/tmp/somefile&quot; do
    mode '0644'
    source &quot;somefile.erb&quot;
    not_if { node[:some_value] }
  end
  </code></pre>
  <p>I'm new to chef and I'm unsure how to proceed to create something that effectively does the following:</p>
  <pre><code>if 'instance' (in node['project']['instance']) == nil 
  do NOT do anything for this template
  </code></pre>
  <p>I would like to use the not_if condition but I don't know how to check for 'instance' == nil.</p>
  <p>I would appreciate any help.
  Thank you,</p>