terraform: pin terraform and providers in separate flake
This commit is contained in:
parent
0d958270b6
commit
f09e14935b
4 changed files with 53 additions and 11 deletions
terraform
27
terraform/flake.lock
generated
Normal file
27
terraform/flake.lock
generated
Normal file
|
@ -0,0 +1,27 @@
|
|||
{
|
||||
"nodes": {
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1676795730,
|
||||
"narHash": "sha256-X69A9BdcPTySJJ7DqS4wc8b6eqGKi32jCSyaBsz4WB0=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "efc59894b1ba73cb745676616c56c780383d6788",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-unstable-small",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"nixpkgs": "nixpkgs"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
"version": 7
|
||||
}
|
24
terraform/flake.nix
Normal file
24
terraform/flake.nix
Normal file
|
@ -0,0 +1,24 @@
|
|||
{
|
||||
description = "terraform devshell";
|
||||
|
||||
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable-small";
|
||||
|
||||
outputs = { nixpkgs, self }: {
|
||||
devShells = nixpkgs.lib.genAttrs [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]
|
||||
(system: {
|
||||
default = with nixpkgs.legacyPackages.${system}; mkShellNoCC {
|
||||
packages = [
|
||||
(terraform.withPlugins (p: [
|
||||
p.cloudflare
|
||||
p.external
|
||||
p.gandi
|
||||
p.hydra
|
||||
p.null
|
||||
p.sops
|
||||
p.tfe
|
||||
]))
|
||||
];
|
||||
};
|
||||
});
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue