mirror of
https://git.vectorsigma.ru/public/atlantis.git
synced 2026-08-09 04:58:34 +00:00
run terraform get for 0.8.8 and below (#62)
* run terraform get for 0.8.8 and below
This commit is contained in:
committed by
Luke Kysow
parent
6dfe20757e
commit
6a977cbea6
@@ -150,6 +150,16 @@ func (p *PlanExecutor) setupAndPlan(ctx *CommandContext) ExecutionResult {
|
||||
return ExecutionResult{SetupError: GeneralError{errors.New(errMsg)}}
|
||||
}
|
||||
ctx.Log.Info("terraform init and environment commands ran successfully %s", outputs)
|
||||
} else {
|
||||
// run terraform get for 0.8.8 and below
|
||||
terraformGetCmd := append([]string{"get", "-no-color"}, config.GetExtraArguments("get")...)
|
||||
_, output, err := p.terraform.RunTerraformCommand(absolutePath, terraformGetCmd, nil)
|
||||
if err != nil {
|
||||
errMsg := fmt.Sprintf("terraform get failed. %s %v", output, err)
|
||||
ctx.Log.Err(errMsg)
|
||||
return ExecutionResult{SetupError: GeneralError{errors.New(errMsg)}}
|
||||
}
|
||||
ctx.Log.Info("terraform get ran successfully %s", output)
|
||||
}
|
||||
|
||||
// if there are pre plan commands then run them
|
||||
|
||||
Reference in New Issue
Block a user