Dependabot + .tofu files = no mans land? #4001
|
I wanted to confirm the scenario I am experiencing is the expected outcome right now. I'm aware support for dependabot is ongoing in multiple avenues. Prior to the move to tofu, we had/have a private terraform registry with tfc for in-house modules. registries:
terraform-org:
type: terraform-registry
url: https://app.terraform.io
token: ${{ secrets.TFC_REGISTRY_READ_TOKEN }}Being the busy body I am, when we moved to OpenTofu we:
Now what I experience is that when the ecosystem is set to
But if I revert to We have already updated our CI to automatically build OCI packages for each of our modules, but I am under the impression that dependabot support for opentofu OCI modules is also not shipped. My current take away is that don't move to .tofu files yet if you use dependabot? |
Replies: 2 comments 14 replies
|
Hi @hoivikaj, The "opentofu" handling in Dependabot was forked from the "terraform" handling and so I'd expect it to be mostly the same, but from reading the registry client's token handling it seems like the OpenTofu implementation wants So I think the OpenTofu implementation is completely ignoring your |
|
Thanks for the follow up @apparentlymart . I checked that same repo for the terraform config, and noticed that the line for terraform type is "terraform_registry" but the argument used in the dependabot config must be "terraform-registry" (note the underscore) - so I dont think that string is 1:1 with the argument label. Nevertheless I did try your theory, and github throws this error: It doesn't appear opentofu-registry is an option at the moment. |
Ahh yes, I didn't notice the dash vs. underscore! Good catch.
What you've shared here is presumably a private registries configuration, and so when running inside GitHub I guess it's probably being handled first by the credentials proxy service.
If I'm understanding correctly,
terraform-registryin your configuration there corresponds toTerraformRegistryHandlerin the proxy codebase1. There isn't a corresponding handler foropentofu_registry.Now that I understand better what we're dealing with here I realize that private registries are not yet supported for OpenTofu, so I think you're unfortunately correct that you won't be able to use dependabot for OpenTofu modules that depend on upst…