Skip to content

Commit

Permalink
treewide: rename options for 23.05
Browse files Browse the repository at this point in the history
  • Loading branch information
Gerschtli committed Jun 6, 2023
1 parent da48699 commit caf4e52
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 8 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ sudo ln -snf bash /bin/sh
```nix
{
services.openssh.enable = true;
services.openssh.permitRootLogin = "yes";
services.openssh.settings.PermitRootLogin = "yes";
users.users.root.password = "nixos";
users.users.tobias = {
Expand Down
2 changes: 1 addition & 1 deletion nixos/base/general.nix
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ in

config = mkIf cfg.enable {

boot.cleanTmpDir = true;
boot.tmp.cleanOnBoot = true;

console.keyMap = "de";

Expand Down
4 changes: 2 additions & 2 deletions nixos/services/applications/gitea.nix
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,9 @@ in
gitea = {
enable = true;
database.passwordFile = config.age.secrets.gitea-dbpassword.path;
rootUrl = "https://${domain}/";

settings.service = {
ROOT_URL = "https://${domain}/";
COOKIE_SECURE = true;
DISABLE_REGISTRATION = true;
REQUIRE_SIGNIN_VIEW = true;
Expand All @@ -64,7 +64,7 @@ in
nginx.virtualHosts.${domain} = {
enableACME = true;
forceSSL = true;
locations."/".proxyPass = "http://localhost:${toString giteaCfg.httpPort}/";
locations."/".proxyPass = "http://localhost:${toString giteaCfg.settings.server.HTTP_PORT}/";
};
};

Expand Down
11 changes: 7 additions & 4 deletions nixos/services/applications/openssh.nix
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,15 @@ in
config = mkIf cfg.enable {

services.openssh = {
inherit (cfg) forwardX11;
enable = true;
openFirewall = true;
permitRootLogin = mkIf (!cfg.rootLogin) "no";
passwordAuthentication = false;
extraConfig = "MaxAuthTries 3";

settings = {
MaxAuthTries = 3;
PasswordAuthentication = false;
PermitRootLogin = mkIf (!cfg.rootLogin) "no";
X11Forwarding = cfg.forwardX11;
};
};

users.users = {
Expand Down

0 comments on commit caf4e52

Please sign in to comment.