Skip to content

Commit

Permalink
More robust check of terraform backend configuration (gruntwork-io#1827)
Browse files Browse the repository at this point in the history
  • Loading branch information
yorinasub17 authored Sep 28, 2021
1 parent fed8039 commit a7ab8ce
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cli/cli_app.go
Original file line number Diff line number Diff line change
Expand Up @@ -462,9 +462,9 @@ func RunTerragrunt(terragruntOptions *options.TerragruntOptions) error {
if err := terragruntConfig.RemoteState.GenerateTerraformCode(updatedTerragruntOptions); err != nil {
return err
}
}

if terragruntConfig.RemoteState != nil {
} else if terragruntConfig.RemoteState != nil {
// We use else if here because we don't need to check the backend configuration is defined when the remote state
// block has a `generate` attribute configured.
if err := checkTerraformCodeDefinesBackend(updatedTerragruntOptions, terragruntConfig.RemoteState.Backend); err != nil {
return err
}
Expand Down

0 comments on commit a7ab8ce

Please sign in to comment.