Skip to content

Commit

Permalink
Rename "github-flow" job-type to "docker" (backward compatible)
Browse files Browse the repository at this point in the history
  • Loading branch information
jeisses committed Sep 13, 2023
1 parent 7928799 commit 8867e2e
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/nosana_node/gitlab.clj
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
:refer [ipfs-hash->bytes bytes->ipfs-hash]
:as util]))

(defmethod create-flow "github-flow"
(defmethod create-flow "docker"
[job run-addr run conf]
(let [job-addr (:job run)]
(-> job
Expand All @@ -24,7 +24,7 @@
flow/build
(assoc :default-args (:nos-default-args conf)))))

(defmethod finish-flow "github-flow"
(defmethod finish-flow "docker"
[flow conf]
(let [results (:state flow)
job-result {:nos-id (:id flow)
Expand Down
9 changes: 7 additions & 2 deletions src/nosana_node/nosana.clj
Original file line number Diff line number Diff line change
Expand Up @@ -554,8 +554,13 @@ Running Nosana Node %s

(defn- create-flow-dispatch [job run-addr run conf]
(prn "Checking Type Of Job " job)
(or (get-in job [:state :nosana/job-type])
"Pipeline"))
(let [res
(or (get-in job [:state :nosana/job-type])
(get-in job [:state :nosana/type]))]
(case res
"github-flow" "docker"
nil "Pipeline"
:else res)))

(defmulti create-flow
"Create a Nostromo flow from a Nosana job.
Expand Down

0 comments on commit 8867e2e

Please sign in to comment.