     {:noreply, state}
   end
 
-  defp handle_wait_run(%{started_at: started_at, timeout: timeout } = state) do
+  defp handle_wait_run(%{started_at: started_at, timeout: timeout, ignore_down: ignore_down } = state) do
     if state.timer do # if inside timer, do not retrigger. Wait for real timer.
       running_for_seconds = case started_at do
         nil -> 0

      timer = Process.send_after(self(), {:restart}, timeout * 1000)

      # Timeout is for next run
      timeout = max(1, min((timeout - running_for_seconds) * 2, @max_timeout)) # 2h

      state = %{
        state |
        timeout: timeout,
        timer: timer,
        started_at: nil,
        task: nil
      }
      Logger.info("Restart init #{inspect state.init.id} in #{state.timeout} seconds.", state: state)
      state

      timeout: 1,
      timer: nil,
      started_at: nil,
      cmd: nil,
      ignore_down: false # ignore one down, do not dup timeout
    }

    GenServer.cast(self(),{:start})
