Skip to content

Commit

Permalink
Merge pull request #442 from UnitedTraders/441-crash-after-new-role
Browse files Browse the repository at this point in the history
Fix crash when new role added to requirements
  • Loading branch information
twhiston committed Feb 27, 2018
2 parents 7a43a58 + 10ade65 commit 0e0bef5
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions api/tasks/runner.go
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,12 @@ func (t *task) prepareRun() {
return
}

if err := t.runGalaxy(); err != nil {
t.log("Running galaxy failed: " + err.Error())
t.fail()
return
}

// todo: write environment

if err := t.listPlaybookHosts(); err != nil {
Expand Down Expand Up @@ -154,12 +160,6 @@ func (t *task) run() {
t.log("Started: " + strconv.Itoa(t.task.ID))
t.log("Run task with template: " + t.template.Alias + "\n")

if err := t.runGalaxy(); err != nil {
t.log("Running galaxy failed: " + err.Error())
t.fail()
return
}

if err := t.runPlaybook(); err != nil {
t.log("Running playbook failed: " + err.Error())
t.fail()
Expand Down

0 comments on commit 0e0bef5

Please sign in to comment.