flake: allow unfree terraform, treefmt: switch to terraform

This commit is contained in:
zowoq 2024-06-01 19:33:53 +10:00
parent ebf93eeb4f
commit 2f354ad448
3 changed files with 9 additions and 5 deletions

View file

@ -6,12 +6,12 @@
programs = {
deadnix.enable = true;
hclfmt.enable = true;
nixpkgs-fmt.enable = true;
prettier.enable = true;
ruff.check = true;
ruff.format = true;
statix.enable = true;
terraform.enable = true;
};
programs.mypy = {

View file

@ -71,6 +71,13 @@
imports = [ ./dev/treefmt.nix ];
};
_module.args.pkgs = import inputs.nixpkgs {
inherit system;
config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [
"terraform"
];
};
checks =
let
darwinConfigurations = lib.mapAttrs' (name: config: lib.nameValuePair name config.config.system.build.toplevel) ((lib.filterAttrs (_: config: config.pkgs.system == system)) self.darwinConfigurations);

View file

@ -1,12 +1,9 @@
{ pkgs, ... }:
let
terraform' = pkgs.terraform.overrideAttrs (_: { meta = { }; });
in
{
devShells = {
terraform = with pkgs; mkShellNoCC {
packages = [
(terraform'.withPlugins (p: [
(terraform.withPlugins (p: [
p.cloudflare
p.external
p.hydra