Use latest version of Gitea

This commit is contained in:
coolneng 2023-03-23 06:56:25 +01:00
parent d0a3ad118f
commit 231a4b663e
Signed by: coolneng
GPG Key ID: 9893DA236405AF57
3 changed files with 29 additions and 5 deletions

View File

@ -142,12 +142,28 @@
"type": "indirect" "type": "indirect"
} }
}, },
"nixpkgs-unstable": {
"locked": {
"lastModified": 1679437018,
"narHash": "sha256-vOuiDPLHSEo/7NkiWtxpHpHgoXoNmrm+wkXZ6a072Fc=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "19cf008bb18e47b6e3b4e16e32a9a4bdd4b45f7e",
"type": "github"
},
"original": {
"id": "nixpkgs",
"ref": "nixos-unstable",
"type": "indirect"
}
},
"root": { "root": {
"inputs": { "inputs": {
"agenix": "agenix", "agenix": "agenix",
"nix-matrix-appservices": "nix-matrix-appservices", "nix-matrix-appservices": "nix-matrix-appservices",
"nixos-hardware": "nixos-hardware", "nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs" "nixpkgs": "nixpkgs",
"nixpkgs-unstable": "nixpkgs-unstable"
} }
} }
}, },

View File

@ -3,6 +3,7 @@
inputs = { inputs = {
nixpkgs.url = "nixpkgs/nixos-22.11"; nixpkgs.url = "nixpkgs/nixos-22.11";
nixpkgs-unstable.url = "nixpkgs/nixos-unstable";
agenix = { agenix = {
url = "github:ryantm/agenix"; url = "github:ryantm/agenix";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
@ -14,13 +15,15 @@
}; };
}; };
outputs = { self, nixpkgs, agenix, nixos-hardware, nix-matrix-appservices, ... outputs = { self, nixpkgs, nixpkgs-unstable, agenix, nixos-hardware
}@inputs: , nix-matrix-appservices, ... }@inputs:
let let
system = "aarch64-linux"; system = "aarch64-linux";
pkgs = import pkgs { inherit system; }; pkgs = import pkgs { inherit system; };
pkgs-unstable = import inputs.nixpkgs-unstable { inherit system; };
lib = nixpkgs.lib; lib = nixpkgs.lib;
in { in {
@ -32,7 +35,10 @@
nixos-hardware.nixosModules.raspberry-pi-4 nixos-hardware.nixosModules.raspberry-pi-4
nix-matrix-appservices.nixosModule nix-matrix-appservices.nixosModule
]; ];
specialArgs = { inherit inputs; }; specialArgs = {
inherit inputs;
inherit pkgs-unstable;
};
}; };
}; };

View File

@ -1,9 +1,10 @@
{ config, pkgs, lib, ... }: { { config, pkgs, pkgs-unstable, lib, ... }: {
# Set up Gitea with LFS support # Set up Gitea with LFS support
services.gitea = { services.gitea = {
enable = true; enable = true;
domain = "git.coolneng.duckdns.org"; domain = "git.coolneng.duckdns.org";
rootUrl = "https://git.coolneng.duckdns.org"; rootUrl = "https://git.coolneng.duckdns.org";
package = pkgs-unstable.gitea;
database = { database = {
type = "postgres"; type = "postgres";
passwordFile = config.age.secrets.gitea.path; passwordFile = config.age.secrets.gitea.path;
@ -18,6 +19,7 @@
ui.DEFAULT_THEME = "arc-green"; ui.DEFAULT_THEME = "arc-green";
session.COOKIE_SECURE = true; session.COOKIE_SECURE = true;
server.DISABLE_SSH = true; server.DISABLE_SSH = true;
actions.ENABLED = true;
}; };
}; };
} }