nixos/flake.nix
Brendan Golden 75740f9bae
Some checks failed
Build_Deploy / linter (push) Successful in 5s
Build_Deploy / build (push) Failing after 1m21s
Build_Deploy / deploy_dns (push) Has been skipped
Build_Deploy / deploy_active (active) (push) Has been skipped
Build_Deploy / deploy_active (active-core) (push) Has been skipped
Build_Deploy / deploy_active (active-ext) (push) Has been skipped
ci: more testing
2024-08-21 00:17:57 +01:00

147 lines
4.3 KiB
Nix

{
description = "Deployment for skynet";
inputs = {
# gonna start off with a fairly modern base
nixpkgs.url = "nixpkgs/nixos-unstable";
# Return to using unstable once the current master is merged in
# nixpkgs.url = "nixpkgs/nixos-unstable";
# utility stuff
flake-utils.url = "github:numtide/flake-utils";
agenix.url = "github:ryantm/agenix";
arion.url = "github:hercules-ci/arion";
alejandra = {
url = "github:kamadorueda/alejandra/3.0.0";
inputs.nixpkgs.follows = "nixpkgs";
};
colmena.url = "github:zhaofengli/colmena";
attic.url = github:zhaofengli/attic;
# we host our own
simple-nixos-mailserver = {
inputs.nixpkgs.follows = "nixpkgs";
url = "git+https://forgejo.skynet.ie/Skynet/misc_nixos-mailserver";
};
######################
### skynet backend ###
######################
skynet_ldap_backend.url = "git+https://forgejo.skynet.ie/Skynet/ldap_backend";
skynet_ldap_frontend.url = "git+https://forgejo.skynet.ie/Skynet/ldap_frontend";
skynet_website_wiki.url = "git+https://forgejo.skynet.ie/Skynet/wiki";
skynet_website_games.url = "git+https://forgejo.skynet.ie/Skynet/website_games";
skynet_discord_bot.url = "git+https://forgejo.skynet.ie/Skynet/discord-bot";
#####################
### compsoc stuff ###
#####################
compsoc_public.url = "git+https://forgejo.skynet.ie/Computer_Society/presentations_compsoc";
#################
### skynet.ie ###
#################
# this should always point to teh current website
skynet_website.url = "git+https://forgejo.skynet.ie/Skynet/website_2017";
# these are past versions of teh website
skynet_website_2023.url = "git+https://forgejo.skynet.ie/Skynet/website_2017?rev=c4d61c753292bf73ed41b47b1607cfc92a82a191";
# this is not 100% right since this is from teh archive from 2022 or so
skynet_website_2017.url = "git+https://forgejo.skynet.ie/Skynet/website_2017?rev=c4d61c753292bf73ed41b47b1607cfc92a82a191";
# this is more of 2012 than 2009 but started in 2009
skynet_website_2009.url = "git+https://forgejo.skynet.ie/Skynet/website_2009";
};
nixConfig = {
bash-prompt-suffix = "[Skynet Dev] ";
extra-substituters = "https://nix-cache.skynet.ie/skynet-cache";
extra-trusted-public-keys = "skynet-cache:zMFLzcRZPhUpjXUy8SF8Cf7KGAZwo98SKrzeXvdWABo=";
};
outputs = {
self,
nixpkgs,
agenix,
alejandra,
colmena,
...
} @ inputs: let
pkgs = nixpkgs.legacyPackages.x86_64-linux.pkgs;
in {
formatter.x86_64-linux = alejandra.defaultPackage."x86_64-linux";
devShells.x86_64-linux.default = pkgs.mkShell {
name = "Skynet build env";
nativeBuildInputs = [
pkgs.buildPackages.git
colmena.defaultPackage."x86_64-linux"
pkgs.attic-client
pkgs.buildPackages.nmap
];
buildInputs = [agenix.packages.x86_64-linux.default];
shellHook = ''export EDITOR="${pkgs.nano}/bin/nano --nonewlines"; unset LD_LIBRARY_PATH;'';
};
colmena = {
meta = {
nixpkgs = import nixpkgs {
system = "x86_64-linux";
overlays = [];
};
specialArgs = {
inherit inputs self;
};
};
# installed for each machine
defaults = import ./machines/_base.nix;
# firewall machiene
agentjones = import ./machines/agentjones.nix;
# ns1
vendetta = import ./machines/vendetta.nix;
# ns2
vigil = import ./machines/vigil.nix;
# icecast - ULFM
galatea = import ./machines/galatea.nix;
# LDAP host
kitt = import ./machines/kitt.nix;
# Gitlab
glados = import ./machines/glados.nix;
# Gitlab runners
wheatly = import ./machines/wheatly.nix;
# email
gir = import ./machines/gir.nix;
# backup 1
neuromancer = import ./machines/neuromancer.nix;
# Skynet, user ssh access
skynet = import ./machines/skynet.nix;
# Main skynet sites
earth = import ./machines/earth.nix;
# Nextcloud
cadie = import ./machines/cadie.nix;
# trainee server
marvin = import ./machines/marvin.nix;
# Public Services
calculon = import ./machines/calculon.nix;
# metrics
ariia = import ./machines/ariia.nix;
};
};
}