title: Checking if process is running
body: <p>I have written a small playbook that checks to see if a given process is running on the host machine. I have written this as follows:</p>
  
  <pre><code>- name: checking process running for clients and start process when not
    service:
      name: marketaccess {{ item.key|lower }} -vi
      state: started
    register: process
    with_dict: "{{ customers }}"
  </code></pre>
  
  <p>When the dictionary's item.key = BROADWAY and the process I am trying to check is as follows :</p>
  
  <p><a href="https://i.stack.imgur.com/hAxWF.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/hAxWF.png" alt="enter image description here"></a></p>
  
  <p>But when I run this playbook the error that is reported is:</p>
  
  <blockquote>
    <p>Could not find the requested service marketacces broadway -vi: host</p>
  </blockquote>
  
  <p>Please can someone see what I am doing wrong?</p>