Merge pull request 'Switch to Tofu' (#144) from joerg-ci into main
All checks were successful
checks / test (push) Successful in 31s

Reviewed-on: #144
This commit is contained in:
Mic92 2024-03-12 10:34:43 +00:00
commit 70f74eab20
3 changed files with 17 additions and 13 deletions

View File

@ -4,7 +4,13 @@
, pkgs
, lib
, ...
}: {
}:
let
convert2Tofu = provider: provider.override (prev: {
homepage = builtins.replaceStrings [ "registry.terraform.io/providers" ] [ "registry.opentofu.org" ] prev.homepage;
});
in
{
devShells.default = pkgs.mkShellNoCC {
packages = [
pkgs.bashInteractive
@ -12,15 +18,13 @@
inputs'.clan-core.packages.clan-cli
((pkgs.terraform.withPlugins (p: [
(pkgs.opentofu.withPlugins (p: builtins.map convert2Tofu [
p.hetznerdns
p.hcloud
p.null
p.external
p.local
])).overrideAttrs (old: {
meta = old.meta // { license = lib.licenses.free; };
}))
]))
];
inputsFrom = [
inputs'.clan-core.devShells.default

View File

@ -14,5 +14,5 @@ cleanup() {
}
trap "cleanup" EXIT
terraform init
terraform "$@"
tofu init
tofu "$@"

File diff suppressed because one or more lines are too long