mirror of
https://gitlab.com/TECHNOFAB/coder-templates.git
synced 2025-12-12 02:00:11 +01:00
78 lines
1.7 KiB
Nix
78 lines
1.7 KiB
Nix
|
|
{
|
||
|
|
description = "Coder Templates";
|
||
|
|
|
||
|
|
outputs = {
|
||
|
|
self,
|
||
|
|
nixpkgs,
|
||
|
|
flake-parts,
|
||
|
|
systems,
|
||
|
|
...
|
||
|
|
} @ inputs:
|
||
|
|
flake-parts.lib.mkFlake {inherit inputs;} {
|
||
|
|
imports = [
|
||
|
|
inputs.devenv.flakeModule
|
||
|
|
inputs.nix-gitlab-ci.flakeModule
|
||
|
|
];
|
||
|
|
systems = import systems;
|
||
|
|
flake = {
|
||
|
|
};
|
||
|
|
perSystem = {
|
||
|
|
config,
|
||
|
|
self',
|
||
|
|
inputs',
|
||
|
|
pkgs,
|
||
|
|
system,
|
||
|
|
...
|
||
|
|
}: {
|
||
|
|
_module.args.pkgs = import nixpkgs {
|
||
|
|
inherit system;
|
||
|
|
config.allowUnfree = true;
|
||
|
|
};
|
||
|
|
|
||
|
|
formatter = pkgs.alejandra;
|
||
|
|
devenv.shells.default = {
|
||
|
|
imports = [
|
||
|
|
inputs.nix-devtools.devenvModule
|
||
|
|
];
|
||
|
|
packages = [
|
||
|
|
pkgs.opentofu
|
||
|
|
pkgs.coder
|
||
|
|
];
|
||
|
|
|
||
|
|
pre-commit.hooks = {
|
||
|
|
alejandra.enable = true;
|
||
|
|
};
|
||
|
|
task = {
|
||
|
|
enable = true;
|
||
|
|
alias = ",";
|
||
|
|
tasks = {};
|
||
|
|
};
|
||
|
|
};
|
||
|
|
|
||
|
|
packages = {
|
||
|
|
nix-coder-image = pkgs.callPackage ./image.nix {};
|
||
|
|
};
|
||
|
|
};
|
||
|
|
};
|
||
|
|
|
||
|
|
inputs = {
|
||
|
|
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
|
||
|
|
|
||
|
|
flake-parts.url = "github:hercules-ci/flake-parts";
|
||
|
|
systems.url = "github:nix-systems/default";
|
||
|
|
devenv.url = "github:cachix/devenv";
|
||
|
|
nix-gitlab-ci = {
|
||
|
|
url = "gitlab:TECHNOFAB/nix-gitlab-ci";
|
||
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
||
|
|
inputs.devenv.follows = "devenv";
|
||
|
|
inputs.systems.follows = "systems";
|
||
|
|
};
|
||
|
|
nix-devtools = {
|
||
|
|
url = "gitlab:TECHNOFAB/nix-devtools";
|
||
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
||
|
|
inputs.devenv.follows = "devenv";
|
||
|
|
inputs.systems.follows = "systems";
|
||
|
|
};
|
||
|
|
};
|
||
|
|
}
|