23.05@nox

This commit is contained in:
Peder Bergebakken Sundt 2023-06-11 11:14:01 +02:00
parent db3c09ee30
commit 5ab4633778
10 changed files with 28 additions and 62 deletions

2
.envrc
View File

@ -10,8 +10,8 @@ if ! test -s .direnv/pull-date || test "$now" != "$(cat .direnv/pull-date)"; the
--update-input nixpkgs \ --update-input nixpkgs \
--update-input unstable \ --update-input unstable \
--update-input home-manager \ --update-input home-manager \
--update-input nixos-hardware \
--update-input pbsds-papers --update-input pbsds-papers
#--update-input nixos-hardware
echo "$now" > .direnv/pull-date echo "$now" > .direnv/pull-date
fi fi

View File

@ -4,20 +4,19 @@
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
"nixpkgs" "nixpkgs"
], ]
"utils": "utils"
}, },
"locked": { "locked": {
"lastModified": 1681092193, "lastModified": 1685599623,
"narHash": "sha256-JerCqqOqbT2tBnXQW4EqwFl0hHnuZp21rIQ6lu/N4rI=", "narHash": "sha256-Tob4CMOVHue0D3RzguDBCtUmX5ji2PsdbQDbIOIKvsc=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "f9edbedaf015013eb35f8caacbe0c9666bbc16af", "rev": "93db05480c0c0f30382d3e80779e8386dcb4f9dd",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "nix-community", "owner": "nix-community",
"ref": "release-22.11", "ref": "release-23.05",
"repo": "home-manager", "repo": "home-manager",
"type": "github" "type": "github"
} }
@ -39,16 +38,16 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1686392259, "lastModified": 1686331006,
"narHash": "sha256-hqSS9hKhWldIZr1bBp9xKhIznnGPICGKzuehd2LH0UA=", "narHash": "sha256-hElRDWUNG655aqF0awu+h5cmDN+I/dQcChRt2tGuGGU=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "ef24b2fa0c5f290a35064b847bc211f25cb85c88", "rev": "85bcb95aa83be667e562e781e9d186c57a07d757",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "NixOS", "owner": "NixOS",
"ref": "nixos-22.11", "ref": "nixos-23.05",
"repo": "nixpkgs", "repo": "nixpkgs",
"type": "github" "type": "github"
} }
@ -145,21 +144,6 @@
"unstable": "unstable" "unstable": "unstable"
} }
}, },
"systems": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"unstable": { "unstable": {
"locked": { "locked": {
"lastModified": 1686412476, "lastModified": 1686412476,
@ -175,24 +159,6 @@
"repo": "nixpkgs", "repo": "nixpkgs",
"type": "github" "type": "github"
} }
},
"utils": {
"inputs": {
"systems": "systems"
},
"locked": {
"lastModified": 1685518550,
"narHash": "sha256-o2d0KcvaXzTrPRIo0kOLV0/QXHhDQ5DTi+OxcjO8xqY=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "a1720a10a6cfe8234c0e93907ffe81be440f4cef",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
} }
}, },
"root": "root", "root": "root",

View File

@ -2,10 +2,10 @@
description = "pbsds' system/home flake"; description = "pbsds' system/home flake";
inputs = { inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-22.11"; nixpkgs.url = "github:NixOS/nixpkgs/nixos-23.05";
unstable.url = "github:NixOS/nixpkgs/nixos-unstable"; unstable.url = "github:NixOS/nixpkgs/nixos-unstable";
#nur.url = "github:nix-community/NUR"; #nur.url = "github:nix-community/NUR";
home-manager.url = "github:nix-community/home-manager/release-22.11"; home-manager.url = "github:nix-community/home-manager/release-23.05";
#home-manager.url = "github:nix-community/home-manager"; #home-manager.url = "github:nix-community/home-manager";
home-manager.inputs.nixpkgs.follows = "nixpkgs"; home-manager.inputs.nixpkgs.follows = "nixpkgs";
nixos-hardware.url = "github:NixOS/nixos-hardware"; nixos-hardware.url = "github:NixOS/nixos-hardware";

View File

@ -68,7 +68,7 @@
# OpenSSH # OpenSSH
services.openssh.enable = true; services.openssh.enable = true;
services.openssh.forwardX11 = true; services.openssh.settings.X11Forwarding = true;
# System fonts # System fonts
# Nice to have when X-forwading on headless machines # Nice to have when X-forwading on headless machines

View File

@ -86,7 +86,7 @@
# OpenSSH # OpenSSH
services.openssh.enable = true; services.openssh.enable = true;
services.openssh.forwardX11 = true; services.openssh.settings.X11Forwarding = true;
# System fonts # System fonts
# Nice to have when X-forwading on headless machines # Nice to have when X-forwading on headless machines

View File

@ -141,7 +141,7 @@
# OpenSSH # OpenSSH
services.openssh.enable = true; services.openssh.enable = true;
services.openssh.forwardX11 = true; services.openssh.settings.X11Forwarding = true;
# System fonts # System fonts
# Nice to have when X-forwading on headless machines # Nice to have when X-forwading on headless machines

View File

@ -25,14 +25,14 @@
#}; #};
#appName = "gitea: spis meg"; #appName = "gitea: spis meg";
appName = "gitea: private instance"; appName = "gitea: private instance";
domain = mkDomain "gitea"; settings.server.DOMAIN = mkDomain "gitea";
#ssh.enable # default is true #ssh.enable # default is true
rootUrl = "https://${domain}/"; settings.server.ROOT_URL = "https://${settings.server.DOMAIN}/";
#ssh.clonePort # default is 22 #ssh.clonePort # default is 22
#log.level = "Debug"; # default is "Info" #log.level = "Debug"; # default is "Info"
#lfs.enable = true; # default is false #lfs.enable = true; # default is false
httpPort = 9675; # default is 3000 settings.server.HTTP_PORT = 9675; # default is 3000
httpAddress = "127.0.0.1"; # default is "0.0.0.0" settings.server.HTTP_ADDR = "127.0.0.1"; # default is "0.0.0.0"
#extraConfig #extraConfig
#database.type # default is "sqlite3" #database.type # default is "sqlite3"
settings.session.COOKIE_SECURE = true; # default is false, only send cookies over https settings.session.COOKIE_SECURE = true; # default is false, only send cookies over https
@ -42,7 +42,7 @@
#log.rootPath # TODO: move? #log.rootPath # TODO: move?
#lfs.contentDir #lfs.contentDir
#dump.enable # default is false #dump.enable # default is false
staticRootPath = pkgs.symlinkJoin { settings.server.STATIC_ROOT_PATH = pkgs.symlinkJoin {
name = "gitea-static-root-data"; name = "gitea-static-root-data";
paths = let paths = let
giteaModern = pkgs.fetchFromGitea { # https://codeberg.org/Freeplay/Gitea-Modern giteaModern = pkgs.fetchFromGitea { # https://codeberg.org/Freeplay/Gitea-Modern
@ -66,17 +66,15 @@
]) ])
]; ];
}; };
settings = {
# https://docs.gitea.io/en-us/config-cheat-sheet/ # https://docs.gitea.io/en-us/config-cheat-sheet/
ui.THEMES = "gitea,arc-green,earl-grey,gitea-modern"; settings.ui.THEMES = "gitea,arc-green,earl-grey,gitea-modern";
ui.DEFAULT_THEME = "earl-grey"; settings.ui.DEFAULT_THEME = "earl-grey";
};
}; };
services.nginx.virtualHosts.${mkDomain "gitea"} = lib.mkIf config.services.gitea.enable { services.nginx.virtualHosts.${mkDomain "gitea"} = lib.mkIf config.services.gitea.enable {
forceSSL = true; # addSSL = true; forceSSL = true; # addSSL = true;
enableACME = true; #useACMEHost = acmeDomain; enableACME = true; #useACMEHost = acmeDomain;
locations."/" = { locations."/" = {
proxyPass = "http://127.0.0.1:${toString config.services.gitea.httpPort}"; proxyPass = "http://127.0.0.1:${toString config.services.gitea.settings.server.HTTP_PORT}";
proxyWebsockets = true; proxyWebsockets = true;
}; };
}; };

View File

@ -24,7 +24,7 @@
#preferences.mp4Playback = ; # Enable MP4 video playback. default is true #preferences.mp4Playback = ; # Enable MP4 video playback. default is true
#preferences.muteVideos = ; # Mute videos by default. default is false #preferences.muteVideos = ; # Mute videos by default. default is false
#preferences.proxyVideos = ; # Proxy video streaming through the server (might be slow). default is true #preferences.proxyVideos = ; # Proxy video streaming through the server (might be slow). default is true
preferences.replaceInstagram = "bibliogram.art"; # Replace Instagram links with links to this instance (blank to disable). default is "" #preferences.replaceInstagram = "bibliogram.art"; # Replace Instagram links with links to this instance (blank to disable). default is ""
preferences.replaceTwitter = mkDomain "nitter"; # Replace Twitter links with links to this instance (blank to disable). default is "" preferences.replaceTwitter = mkDomain "nitter"; # Replace Twitter links with links to this instance (blank to disable). default is ""
preferences.replaceYouTube = lib.mkIf config.services.invidious.enable (mkDomain "invidious"); # Replace YouTube links with links to this instance (blank to disable). default is "" preferences.replaceYouTube = lib.mkIf config.services.invidious.enable (mkDomain "invidious"); # Replace YouTube links with links to this instance (blank to disable). default is ""
settings = lib.mkIf config.services.libreddit.enable { settings = lib.mkIf config.services.libreddit.enable {

View File

@ -1,5 +1,7 @@
{ config, pkgs, lib, ... }: { config, pkgs, lib, ... }:
{ {
programs.zsh.enable = true;
users.users.jornane = { users.users.jornane = {
isNormalUser = true; isNormalUser = true;
uid = 1002; uid = 1002;

View File

@ -81,12 +81,12 @@
#nim #nim
#nimble #nimble
poetry
(python3.withPackages (python-packages: with python-packages; [ (python3.withPackages (python-packages: with python-packages; [
matplotlib matplotlib
more-itertools more-itertools
numpy numpy
#objexplore # TODO: package this, used in python interactive shell #objexplore # TODO: package this, used in python interactive shell
poetry
ptpython ptpython
python-lsp-server python-lsp-server
pyyaml pyyaml