forked from Fediversity/Fediversity
25 lines
550 B
Nix
25 lines
550 B
Nix
# FIXME: use overlays so this gets imported just once?
|
|
{
|
|
lib,
|
|
pkgs,
|
|
...
|
|
}:
|
|
let
|
|
tofuProvider =
|
|
provider:
|
|
provider.override (oldArgs: {
|
|
provider-source-address =
|
|
lib.replaceStrings [ "https://registry.terraform.io/providers" ] [ "registry.opentofu.org" ]
|
|
oldArgs.homepage;
|
|
});
|
|
tf = pkgs.opentofu;
|
|
tfPlugins = (
|
|
p: [
|
|
p.null
|
|
p.external
|
|
]
|
|
);
|
|
in
|
|
# tf.withPlugins tfPlugins
|
|
# https://github.com/NixOS/nixpkgs/pull/358522
|
|
tf.withPlugins (p: pkgs.lib.lists.map tofuProvider (tfPlugins p))
|