Hi, I ran infracost using github actions and got t...
# general
f
Hi, I ran infracost using github actions and got this error on github, my repo is really huge but is there a way to avoid this?
message has been deleted
l
Hi @fancy-scientist-81076. I’ve not seen this before. Can you try the example that doesn’t use the cache? https://github.com/infracost/actions/tree/master/examples/terraform-project
f
Hi Alistair, thanks for responding. I tried running the example without the cache and ran into the same problem
l
Hmm… are there any more logs or information if you run it in debug mode? Also, is this the only job that runs in the workflow?
f
When I run it in debug mode I see normal logs and no error message
Other jobs do run but this latest run was just ran alone
l
How big is your repo? The action works by checking out the base branch and then the PR branch, so maybe there’s something we could do to clean up between those check outs.
f
The repo is huge, ~60 environments, maybe more
l
do you know how many GB?
f
Not sure about that but the debug log file that I got is over 500mb and the action ran for ~50 mins before erroring out
l
and the action ran for ~50 mins before erroring out
was this the same error as above?
f
Yea same
Also it fails while establishing the baseline doesn't even get to checkout the PR branch
l
On this step? “Generate Infracost cost estimate baseline”
f
Yes
l
Okay, do you use a lot of remote modules?
f
Yes we do
l
Okay, it might be when we download them then it runs out of space. Looks like GitHub Actions gives you 14 GB of space, so I’m surprised that’s running out. One idea for a workaround is to use a matrix build to run it for different subdirectories, and then combine the results and post a single comment. I can have a look at working out an example for that.
f
Ah ok I see what you mean, thank you so much for the help, really appreciate it!
Hi @little-author-61621, I ran the matrix build with just 2 envs but just a single environment ran for 30 minutes before failing. What is the best way to handle large mono repos?
l
Hi @fancy-scientist-81076 my best guess is it’s taking the time downloading external modules, but 30 mins sounds like a long time. I’d be happy to pair with you on Zoom to help debug. You can schedule something with me here to suit you if that helps: https://calendly.com/aiscott.