Compare commits

...

1 commit

Author SHA1 Message Date
c0870ccac3
retry
Some checks failed
/ lint (push) Failing after 31s
2025-08-20 11:49:20 +02:00
12 changed files with 113 additions and 91 deletions

View file

@ -1,6 +1,11 @@
on: [push]
on:
push:
branches:
- master
jobs:
test:
runs-on: docker
build:
runs-on: nixos-latest
steps:
- run: echo All good!
- uses: actions/checkout@v4
- run: nix develop
- run: colmena build -v --on @fili

7
.github/workflows/lint.yml vendored Normal file
View file

@ -0,0 +1,7 @@
on: [push]
jobs:
lint:
runs-on: nixos-latest
steps:
- uses: actions/checkout@v4
- run: nix fmt -- --check .

View file

@ -16,7 +16,6 @@ _: {
networkmanager.enable = true;
};
nix.settings = {
# users that can interact with nix
trusted-users = [

View file

@ -1,4 +1,5 @@
{ baseUrl, clientId }: {
{ baseUrl, clientId }:
{
inherit clientId;
userAuthUrl = "${baseUrl}/ui/oauth2";

View file

@ -1,9 +1,11 @@
{pkgs, config, ...}: let
{ pkgs, config, ... }:
let
lib = pkgs.lib;
domain = "auth.donsz.nl";
port = 3013;
backupsDir = "/var/lib/kanidm/backup";
in {
in
{
services.kanidm.enableServer = true;
services.kanidm.package = pkgs.kanidm_1_6;
services.kanidm.serverSettings = {
@ -26,12 +28,11 @@ in {
mkdir -p "${backupsDir}"
'';
serviceConfig = {
SupplementaryGroups =
[ config.security.acme.certs.${domain}.group ];
SupplementaryGroups = [ config.security.acme.certs.${domain}.group ];
};
};
environment.systemPackages = [pkgs.kanidm];
environment.systemPackages = [ pkgs.kanidm ];
services.nginx.virtualHosts.${domain} = {
forceSSL = true;

View file

@ -1,12 +1,17 @@
{pkgs, config, ...}: {
{ pkgs, config, ... }:
{
sops.secrets.oauth2-proxy = {
sopsFile = ../../../secrets/oauth2-proxy.env;
};
services.oauth2-proxy =
let
auth = import ../../lib/auth.nix { baseUrl = "https://auth.donsz.nl"; clientId = "homeserver"; };
in {
auth = import ../../lib/auth.nix {
baseUrl = "https://auth.donsz.nl";
clientId = "homeserver";
};
in
{
enable = true;
provider = "oidc";
@ -34,7 +39,7 @@
};
extraConfig = {
whitelist-domain = ["*.donsz.nl"];
whitelist-domain = [ "*.donsz.nl" ];
};
nginx.domain = "oauth2.donsz.nl";

View file

@ -1,4 +1,9 @@
{ lib, pkgs, config, ... }:
{
lib,
pkgs,
config,
...
}:
let
cfg = config.services.forgejo;
srv = cfg.settings.server;
@ -6,7 +11,7 @@ in
{
sops.secrets.forgejo = {
sopsFile = ../../secrets/forgejo.yaml;
key="email_password";
key = "email_password";
format = "yaml";
};
@ -33,7 +38,7 @@ in
lfs.enable = true;
user = "forgejo";
group = "forgejo";
repositoryRoot="/storage/storage/git";
repositoryRoot = "/storage/storage/git";
database = {
type = "postgres";
@ -43,8 +48,8 @@ in
settings = {
DEFAULT = {
APP_NAME="jana's git server";
APP_SLOGAN="meow!";
APP_NAME = "jana's git server";
APP_SLOGAN = "meow!";
};
server = {
DOMAIN = "git.donsz.nl";
@ -62,7 +67,7 @@ in
DEFAULT_ACTIONS_URL = "github";
};
repository = {
DEFAULT_PRIVATE="private";
DEFAULT_PRIVATE = "private";
};
mailer = {
ENABLED = true;
@ -83,10 +88,9 @@ in
token = "SutcrCJ3ULoE5LBj9Tm8zkvTRDEJCpbvpe7FEJHC";
url = "https://git.donsz.nl/";
labels = [
"node-22:docker://node:22-bookworm"
"nixos-latest:docker://nixos/nix"
];
settings = {};
settings = { };
};
};

View file

@ -1,4 +1,5 @@
{pkgs, config, ...}: {
{ pkgs, config, ... }:
{
services.nginx = {
enable = true;
statusPage = true;

View file

@ -1,4 +1,5 @@
{flakes, pkgs, ...}: {
{ flakes, pkgs, ... }:
{
services.nginx = {
virtualHosts."donsz.nl" = {
forceSSL = true;

View file

@ -1,4 +1,5 @@
{flakes,...}: {
{ flakes, ... }:
{
# imports = [
# flakes.mapf.nixosModules.default
# ];

View file

@ -1,8 +1,6 @@
{ flakes, pkgs,... }:
{ flakes, pkgs, ... }:
let
totpal =
flakes.totpal.packages.${pkgs.system}.default
;
totpal = flakes.totpal.packages.${pkgs.system}.default;
in
{
services.nginx = {
@ -17,8 +15,7 @@ in
};
};
systemd.services.totpal =
{
systemd.services.totpal = {
description = "totpal";
serviceConfig = {
Type = "simple";