Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug: execution_order_group does not work with a folder without *.hcl files in the file structure #325

Open
SimonG-Alza opened this issue Apr 5, 2024 · 0 comments

Comments

@SimonG-Alza
Copy link

SimonG-Alza commented Apr 5, 2024

Bug report

Using terragrunt-atlantis-config generate --output atlantis.yaml --create-workspace --create-project-name --execution-order-groups true in my terragrunt project, which contains folders without *.hcl files in the file structure.

To Reproduce

  1. Download test_examples/terragrunt_dependency from https://github.com/transcend-io/terragrunt-atlantis-config/tree/master/test_examples/terragrunt_dependency.
  2. Create file structure as:
    image
  3. Run terragrunt-atlantis-config generate --output atlantis.yaml --create-workspace --create-project-name --execution-order-groups true in test_examples

Doesn't work if you run terragrunt-atlantis-config generate --output atlantis.yaml --create-workspace --create-project-name --execution-order-groups true in test_examples/terragrunt_dependency and you nested the depender as in
image

Expected behavior

automerge: false
parallel_apply: true
parallel_plan: true
projects:
- autoplan:
    enabled: false
    when_modified:
    - '*.hcl'
    - '*.tf*'
  dir: dependency
  name: dependency
  workspace: dependency
- autoplan:
    enabled: false
    when_modified:
    - '*.hcl'
    - '*.tf*'
    - ../dependency/terragrunt.hcl
  dir: depender
  execution_order_group: 1 <-------- 
  name: depender
  workspace: depender
version: 3

Actual behavior

automerge: false
parallel_apply: true
parallel_plan: true
projects:
- autoplan:
    enabled: false
    when_modified:
    - '*.hcl'
    - '*.tf*'
  dir: terragrunt_dependency/dependency
  name: terragrunt_dependency_dependency
  workspace: terragrunt_dependency_dependency
- autoplan:
    enabled: false
    when_modified:
    - '*.hcl'
    - '*.tf*'
    - ../dependency/terragrunt.hcl
  dir: terragrunt_dependency/depender
  name: terragrunt_dependency_depender
  workspace: terragrunt_dependency_depender
version: 3

Relevant Terragrunt files
Using https://github.com/transcend-io/terragrunt-atlantis-config/tree/master/test_examples/terragrunt_dependency

Conclusion

terragrunt-atlantis-config generate --output atlantis.yaml --create-workspace --create-project-name --execution-order-groups true iterates through 2 levels of subdirectories (if all of them contains *.hcl) from the current path, but not whole project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant