anchor.diff:  }
   
   stop() {
  -    if ! [ -f $cidfile ]; then
  -        failure
  -        echo
  -        printf "$cidfile does not exist.\n"
  -        exit 7
  -    else
  -        cid="$(cat $cidfile)"
  -        if [ -n $cid ]; then
  -            echo -n $"Stopping $prog: "
  -            $docker stop $(cat $cidfile)
  -            retval=$?
  -            [ $retval -eq 0 ] && rm -f $lockfile
  -            return $retval
  -        fi
  -    fi
  +    echo -n "Stopping $prog: "
  +    $docker stop <%= @sanitised_title %>
  +    $docker rm <%= @sanitised_title %>
  +    return $?
   }
   
   case "$1" in
  
positive.code: start() {
      [ -x $docker ] || exit 5
  
      if [ -f $cidfile ]; then
          cid="$(cat $cidfile)"
          if [ -n "$cid" ]; then
              $docker ps --no-trunc=true|grep $cid
              retval=$?
              if [ $retval -eq 0 ]; then
                  failure
                  echo
                  printf "Container $cid is still running.\n"
                  exit 7
              else
                  rm -f $lockfile
              fi
          fi
      fi
  
      printf "Starting $prog:\t"
      <% if @pull_on_start -%>
          $docker pull <%= @image %>
      <% end -%>
      if [ -f $cidfile ]; then
      <% if @use_name -%>
          $docker start <%= @name %>
      <% else -%>
          $docker start $(cat $cidfile)
      <% end -%>
      else
          $docker run --cidfile=$cidfile \
          <%= @docker_run_flags %> \
          <% if @use_name %>--name <%= @name %><% end %> \
          <% if @extra_parameters %><% @extra_parameters_array.each do |param| %>  \
              <%= param %> <% end %> \
          <% end -%> \
          <%= @image %> \
         <% if @command %> <%= @command %><% end %>
  
      fi
      retval=$?
      echo
      if [ $retval -eq 0 ]; then
  	[ -n "$lockfile" ] && touch $lockfile
          success
      else
          failure
  
negative.code: HOME=/root/
  docker="/usr/bin/<%= @docker_command %>"
  prog="docker-<%= @sanitised_title %>"
  if [ -d /var/lock/subsys ]; then
      lockfile="/var/lock/subsys/$prog"
  else
  