Hi all,
I’ve been trying to work with Terraspace on a new work project, and have been running into some infuriating issues/bugs with file permissions when trying to run up
commands.
When trying to deploy my stacks, I keep getting errors similar to this:
Exception Errno::EACCES: Permission denied @ rb_sysopen - /Users/my-username/repo_path/.terraspace-cache/us-east-1/prod/stacks/network-base/.terraform/modules/sg_app/.git/objects/pack/pack-cce80361a90e47d522aef14eb0d4157b2208f1cf.idx
For context, here’s how I’ve installed everything:
- ASDF for:
- ruby 3.1.3
- terraform-docs
- terraform 1.4.6
- tflint 0.46.1
- As of right now, I’ve used the DMG installer to install Terraspace, but this was a troubleshooting exercise to see if the homebrew install was the root cause of my issues
Here’s the command I’m running (this issues comes up whether or not I use a .env
file):
TS_ENV=prod bundle exec terraspace up <stack-name>
So, here’s where things get weird:
I was completely unable to run operations that involved loading the cache until I ran the bundle
cmd. This seemed to fix my issue, but then out of nowhere, the issue seemed to just return for no reason. Now, I can run an up
command if there is no cache directory (I’m just manually deleting it), but running a subsequent command on the same exact isolated stack will fail due to file permission errors. On top of this, there’s one stack that simply refuses to work anymore at all, even when I blow out my cache.
Has anyone encountered this issue before and resolved it on an ARM Mac? I’m just about ready to request that we revert back to vanilla Terraform at this point