Skip to content

Commit

Permalink
Enable jetty on production deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
jeisses committed Nov 22, 2023
1 parent d737abb commit a964bf4
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
7 changes: 5 additions & 2 deletions src/nosana_node/cli.clj
Original file line number Diff line number Diff line change
Expand Up @@ -154,8 +154,11 @@
(defn use-cli
"Parse CLI arguments using `tools.cli` and add to system map.
The `:id` and value of each attribute is merged into the `:nos/vault`
map in the system."
The `:id` and value of each config attribute is merged into the `:nos/vault`
map in the system.
`:nos/action` is added to the global system which is the command
used."
[{:keys [cli-args nos/vault] :as sys}]
(let [{:keys [errors options arguments summary] :as res}
(cli/parse-opts cli-args (get-in cli-options [nil :options]) :in-order true)
Expand Down
5 changes: 4 additions & 1 deletion src/nosana_node/main.clj
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
[nosana-node.nosana :as nosana :refer [use-nosana work-loop]]
[nos.core :as flow]
[clojure.core.async :refer [<!!]]
[nosana-node.system :refer [start-system use-when] :as nos-sys]
[nosana-node.system :refer [start-system use-when use-jetty] :as nos-sys]
[nosana-node.pipeline :as pipeline]
[nosana-node.cli :as cli]
nosana-node.gitlab
Expand Down Expand Up @@ -51,6 +51,8 @@
cli/use-cli
store/use-fs-store
;; use-nrepl
(use-when :run-server?
use-jetty)
use-nostromo
use-nosana
nos-sys/use-wrap-ctx]
Expand All @@ -61,6 +63,7 @@
:nos/store-path "/tmp/store"
:nos/start-job-loop true
:nos/vault-path (io/resource "config.edn")})]
;; :nos/action is the CLI action invoked, as parsed by `use-cli`
(case (:nos/action sys)
"start" (<!! (work-loop sys))
"join-test-grid" (<!! (join-test-grid sys))))
Expand Down

0 comments on commit a964bf4

Please sign in to comment.