Add config for forgejo machine, justfile for quality of life.

This commit is contained in:
DS 2025-02-23 18:57:51 -08:00
parent 98c77311fd
commit 9f66f0b37b
7 changed files with 403 additions and 31 deletions

View file

@ -1,8 +1,14 @@
{
description = "Epesooj webring.";
description = "Epesooj webring and machine.";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
flake-parts.url = "github:hercules-ci/flake-parts";
disko = {
url = "github:nix-community/disko";
inputs.nixpkgs.follows = "nixpkgs";
};
nil = {
url = "github:oxalica/nil";
@ -10,23 +16,61 @@
};
};
outputs = { self, nixpkgs, nil, ... }:
let
pkgs = import nixpkgs {
system = "x86_64-linux";
};
in
{
devShells.x86_64-linux = {
default = pkgs.mkShell {
packages = with pkgs; [
nodePackages_latest.nodejs
outputs = inputs@{ flake-parts, nil, ... }:
flake-parts.lib.mkFlake { inherit inputs; } ({ config, getSystem, ... }: {
systems = [ "x86_64-linux" ];
# Both of these used with VSCode.
nixpkgs-fmt
nil.packages.${system}.default
imports = [
./code_server.nix
];
flake =
let
codeServerModules = [
config.flake.nixosModules.code-server
{
networking.hostName = "epesooj-code-0001";
}
];
in
{
nixosConfigurations = {
code = inputs.nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = codeServerModules;
};
};
colmena = {
meta.nixpkgs = import inputs.nixpkgs {
system = "x86_64-linux";
};
code = {
deployment = {
targetHost = "epesooj-code-0001"; # Requires an SSH config with information for this host.
};
imports = codeServerModules;
};
};
};
perSystem = { system, pkgs, ... }: {
devShells = {
default = pkgs.mkShell {
packages = with pkgs; [
just
nodePackages_latest.nodejs
colmena
# Both of these used with VSCode.
nixpkgs-fmt
nil.packages.${system}.default
];
};
};
};
};
});
}