File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change 311311      if  $running  == false  {
312312        exec  { "stop ${title} with docker" :
313313          command      => " ${docker_command}  stop --time=${stop_wait_time}  ${sanitised_title} "  ,
314-           unless       => " ${docker_command}  inspect ${sanitised_title}  -f \" {{ .State.Running }}\"  | grep true "  ,
314+           unless       => " ${docker_command}  inspect ${sanitised_title}  -f \" {{ if ( .State.Running)  }} {{ nil }}{{ end }} \" "  ,
315315          environment  => $exec_environment ,
316316          path         => $exec_path ,
317317          provider     => $exec_provider ,
320320      } else  {
321321        exec  { "start ${title} with docker" :
322322          command      => " ${docker_command}  start ${sanitised_title} "  ,
323-           onlyif       => " ${docker_command}  inspect ${sanitised_title}  -f \" {{ .State.Running }}\"  | grep false "  ,
323+           onlyif       => " ${docker_command}  inspect ${sanitised_title}  -f \" {{ if ( .State.Running)  }} {{ nil }}{{ end }} \" "  ,
324324          environment  => $exec_environment ,
325325          path         => $exec_path ,
326326          provider     => $exec_provider ,
    
 
   
 
     
   
   
          
     
  
    
     
 
    
      
     
 
     
    You can’t perform that action at this time.
  
 
    
  
     
    
      
        
     
 
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments