                          ["/add/" :env] #'add-app-env
                          ["/delete/" :env] #'remove-app-env}
                 "/logs" #'load-app-logs
-                "/kill" #'kill-app-instance}}])
+                "/kill" #'kill-app-instances}}])
 
 (defn controller-app [{:keys [params uri] :as req}]
   (if-let [{:keys [handler route-params] :as all} (match-route routes uri)]


(defn kill-app-instances [app]
  (doseq [instance (load-app-instances app)]
    (let [[host port] instance]
      kill-app-instance app host port)))

(defn describe []
  (into {} (for [app (load-apps)]

  (rand-nth (vec (clojure.set/difference port-range (load-ports-in-use host)))))

(defn load-container-by-host-and-port [host port]
  (first (filter #(= port (str (:PublicPort (first (:Ports %))))) (get-containers host))))

(defn stop-container [host id]
  (docker! :post host (str "containers/" id "/stop")))
