Save changes
This commit is contained in:
parent
abd6a606d0
commit
3935998865
|
@ -1,6 +1,5 @@
|
||||||
{ pkgs, config, lib, ... }:
|
{ pkgs, config, lib, ... }:
|
||||||
let inherit (config.m-0.private) me meWork;
|
{
|
||||||
in {
|
|
||||||
|
|
||||||
imports = [
|
imports = [
|
||||||
./zsh
|
./zsh
|
||||||
|
@ -65,8 +64,8 @@ in {
|
||||||
".hledger-web_client_session_key.aes"
|
".hledger-web_client_session_key.aes"
|
||||||
".nix-gc-roots"
|
".nix-gc-roots"
|
||||||
];
|
];
|
||||||
userEmail = me.mail;
|
userEmail = "malte.brandy@maralorn.de";
|
||||||
userName = me.name;
|
userName = "Malte Brandy";
|
||||||
};
|
};
|
||||||
htop = {
|
htop = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -97,28 +96,24 @@ in {
|
||||||
};
|
};
|
||||||
hera = {
|
hera = {
|
||||||
hostname = "hera.m-0.eu";
|
hostname = "hera.m-0.eu";
|
||||||
user = me.user;
|
user = "maralorn";
|
||||||
};
|
};
|
||||||
ag-forward = {
|
ag-forward = {
|
||||||
hostname = agHost;
|
hostname = agHost;
|
||||||
proxyCommand = matheGwProxy;
|
proxyCommand = matheGwProxy;
|
||||||
user = meWork.user;
|
user = "brandy";
|
||||||
};
|
};
|
||||||
ag = {
|
ag = {
|
||||||
hostname = agHost;
|
hostname = agHost;
|
||||||
user = meWork.user;
|
user = "brandy";
|
||||||
};
|
};
|
||||||
gw = {
|
gw = {
|
||||||
hostname = "gwres4.mathematik.tu-darmstadt.de";
|
hostname = "gwres4.mathematik.tu-darmstadt.de";
|
||||||
user = meWork.user;
|
user = "brandy";
|
||||||
};
|
};
|
||||||
shells = {
|
shells = {
|
||||||
hostname = "shells.darmstadt.ccc.de";
|
hostname = "shells.darmstadt.ccc.de";
|
||||||
user = me.user;
|
user = "maralorn";
|
||||||
};
|
|
||||||
vorstand = {
|
|
||||||
hostname = "vorstand.darmstadt.ccc.de";
|
|
||||||
user = me.user;
|
|
||||||
};
|
};
|
||||||
whisky = {
|
whisky = {
|
||||||
hostname = "whisky.w17.io";
|
hostname = "whisky.w17.io";
|
||||||
|
@ -138,7 +133,7 @@ in {
|
||||||
sessionVariables = {
|
sessionVariables = {
|
||||||
PATH = "$HOME/.nix-profile/bin:$PATH";
|
PATH = "$HOME/.nix-profile/bin:$PATH";
|
||||||
BROWSER = "${pkgs.firefox}/bin/firefox";
|
BROWSER = "${pkgs.firefox}/bin/firefox";
|
||||||
EMAIL = me.mail;
|
EMAIL = "malte.brandy@maralorn.de";
|
||||||
SUDO_ASKPASS = let
|
SUDO_ASKPASS = let
|
||||||
print-pw = pkgs.writeShellScriptBin "print-pw"
|
print-pw = pkgs.writeShellScriptBin "print-pw"
|
||||||
"pass show eu/m-0/${config.m-0.hostName}.m-0.eu/${config.home.username}";
|
"pass show eu/m-0/${config.m-0.hostName}.m-0.eu/${config.home.username}";
|
||||||
|
|
|
@ -24,12 +24,18 @@ in {
|
||||||
'';
|
'';
|
||||||
updateModes = pkgs.writeHaskellScript {
|
updateModes = pkgs.writeHaskellScript {
|
||||||
name = "update-modes";
|
name = "update-modes";
|
||||||
bins = [ activateMode ];
|
bins = [ activateMode pkgs.git ];
|
||||||
} ''
|
} ''
|
||||||
|
params = ["${configPath}/home-manager/target.nix", "-A", "apollo", "-o", "/home/maralorn/.modes"]
|
||||||
|
|
||||||
main = do
|
main = do
|
||||||
say "Building ~/.modes for apollo"
|
say "Building ~/.modes for apollo"
|
||||||
nixPath <- myNixPath "${configPath}"
|
nixPath <- myNixPath "${configPath}"
|
||||||
nix_build nixPath "${configPath}/home-manager/target.nix" "-A" "apollo" "-o" "/home/maralorn/.modes"
|
privateDeinit :: Either SomeException () <- try $ git "submodule" "deinit" "${configPath}"
|
||||||
|
when (isRight privateDeinit) $ do
|
||||||
|
nix_build nixPath (params ++ remoteBuildParams)
|
||||||
|
git "submodule" "update" "--init" "${configPath}"
|
||||||
|
nix_build nixPath params
|
||||||
activate_mode
|
activate_mode
|
||||||
'';
|
'';
|
||||||
selectMode = pkgs.writeHaskellScript {
|
selectMode = pkgs.writeHaskellScript {
|
||||||
|
|
|
@ -24,9 +24,9 @@ let
|
||||||
simpleSortList = listName:
|
simpleSortList = listName:
|
||||||
simple "List:${listName}" "list/${toFolder listName}";
|
simple "List:${listName}" "list/${toFolder listName}";
|
||||||
};
|
};
|
||||||
myFilters = builtins.map filter.simpleSortList sortLists
|
myFilters = builtins.map filter.simpleSortList lists.sortLists
|
||||||
++ builtins.map filter.stupidList stupidLists
|
++ builtins.map filter.stupidList lists.stupidLists
|
||||||
++ builtins.map filter.notifications notifications;
|
++ builtins.map filter.notifications lists.notifications;
|
||||||
sortMail = pkgs.writeHaskellScript {
|
sortMail = pkgs.writeHaskellScript {
|
||||||
name = "sort-mail-archive";
|
name = "sort-mail-archive";
|
||||||
bins = [ pkgs.notmuch pkgs.coreutils pkgs.mblaze pkgs.findutils ];
|
bins = [ pkgs.notmuch pkgs.coreutils pkgs.mblaze pkgs.findutils ];
|
||||||
|
@ -117,7 +117,7 @@ in {
|
||||||
};
|
};
|
||||||
systemd.user.timers.mbsync.Timer.RandomizedDelaySec = "10m";
|
systemd.user.timers.mbsync.Timer.RandomizedDelaySec = "10m";
|
||||||
|
|
||||||
accounts.email.accounts = pkgs.privateValue {} "mail/accounts";
|
accounts.email.accounts = pkgs.privateValue { } "mail/accounts";
|
||||||
systemd.user.services = let
|
systemd.user.services = let
|
||||||
mkService = name: account:
|
mkService = name: account:
|
||||||
let
|
let
|
||||||
|
|
|
@ -3,11 +3,15 @@ let configPath = "/etc/nixos";
|
||||||
in {
|
in {
|
||||||
update-system = pkgs.writeHaskellScript {
|
update-system = pkgs.writeHaskellScript {
|
||||||
name = "update-system";
|
name = "update-system";
|
||||||
bins = [ nixos-rebuild ];
|
bins = [ nixos-rebuild pkgs.git ];
|
||||||
} ''
|
} ''
|
||||||
main = do
|
main = do
|
||||||
paths <- myNixPath "${configPath}"
|
paths <- myNixPath "${configPath}"
|
||||||
args <- getArgs
|
args <- getArgs
|
||||||
|
privateDeinit :: Either SomeException () <- try $ git "-C" "${configPath}" "submodule" "deinit" "private"
|
||||||
|
when (isRight privateDeinit) $ do
|
||||||
|
nixos_rebuild (paths ++ ["build"] ++ remoteBuildParams ++ fmap toString args)
|
||||||
|
git "-C" "${configPath}" "submodule" "update" "--init" "private"
|
||||||
nixos_rebuild (paths ++ ["switch"] ++ fmap toString args)
|
nixos_rebuild (paths ++ ["switch"] ++ fmap toString args)
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
|
|
|
@ -81,6 +81,7 @@ in {
|
||||||
// {
|
// {
|
||||||
cert = pkgs.privatePath "syncthing/apollo/cert.pem";
|
cert = pkgs.privatePath "syncthing/apollo/cert.pem";
|
||||||
key = pkgs.privatePath "syncthing/apollo/key.pem";
|
key = pkgs.privatePath "syncthing/apollo/key.pem";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
gnome3.chrome-gnome-shell.enable = true;
|
gnome3.chrome-gnome-shell.enable = true;
|
||||||
xserver = {
|
xserver = {
|
||||||
|
@ -91,15 +92,5 @@ in {
|
||||||
};
|
};
|
||||||
boot.kernel.sysctl = { "fs.inotify.max_user_watches" = 204800; };
|
boot.kernel.sysctl = { "fs.inotify.max_user_watches" = 204800; };
|
||||||
|
|
||||||
#cdark_net = {
|
|
||||||
#enable = true;
|
|
||||||
#hostName = "${me.user}_${config.networking.hostName}";
|
|
||||||
#ed25519PrivateKeyFile = /etc/nixos/nixos/machines
|
|
||||||
#+ "/${config.networking.hostName}" + /secret/tinc/ed25519_key.priv;
|
|
||||||
#hostsDirectory =
|
|
||||||
#pkgs.fetchgit { url = "ssh://git@git.darmstadt.ccc.de/cdark.net/hosts"; };
|
|
||||||
#ip6address = "fd23:42:cda:4342::2";
|
|
||||||
#ip4address = "172.20.71.2";
|
|
||||||
#};
|
|
||||||
system.stateVersion = "19.09";
|
system.stateVersion = "19.09";
|
||||||
}
|
}
|
||||||
|
|
|
@ -61,8 +61,8 @@ in {
|
||||||
git "-C" repoDir "config" "user.name" "maralorn (nix-auto-updater)"
|
git "-C" repoDir "config" "user.name" "maralorn (nix-auto-updater)"
|
||||||
git "-C" repoDir "commit" "-am" "Update dependencies with niv"
|
git "-C" repoDir "commit" "-am" "Update dependencies with niv"
|
||||||
concurrently_
|
concurrently_
|
||||||
(mapConcurrently_ (\x -> test_system_config repoDir x "--builders" "@/etc/nix/machines" "--max-jobs" "0") ${self.haskellList systems})
|
(mapConcurrently_ (\x -> test_system_config repoDir x remoteBuildParams) ${self.haskellList systems})
|
||||||
(mapConcurrently_ (\x -> test_home_config repoDir x "--builders" "@/etc/nix/machines" "--max-jobs" "0") ${self.haskellList homes})
|
(mapConcurrently_ (\x -> test_home_config repoDir x remoteBuildParams) ${self.haskellList homes})
|
||||||
git "-C" repoDir "submodule" "update" "--init"
|
git "-C" repoDir "submodule" "update" "--init"
|
||||||
concurrently_
|
concurrently_
|
||||||
(mapConcurrently_ (test_system_config repoDir) ${self.haskellList systems})
|
(mapConcurrently_ (test_system_config repoDir) ${self.haskellList systems})
|
||||||
|
|
|
@ -55,6 +55,9 @@ self: super: {
|
||||||
tag name str = ["-I", [i|#{name :: Text}=#{str :: Text}|]] :: [String]
|
tag name str = ["-I", [i|#{name :: Text}=#{str :: Text}|]] :: [String]
|
||||||
getNivAssign name = tag name <$> getNivPath path name
|
getNivAssign name = tag name <$> getNivPath path name
|
||||||
|
|
||||||
|
remoteBuildParams :: [String]
|
||||||
|
remoteBuildParams = ["--builders", "@/etc/nix/machines", "--max-jobs", "0"]
|
||||||
|
|
||||||
main :: IO ()
|
main :: IO ()
|
||||||
${code}
|
${code}
|
||||||
'';
|
'';
|
||||||
|
|
2
private
2
private
|
@ -1 +1 @@
|
||||||
Subproject commit 7250f095fbed52e5dc3b10aa3af2f0874031efe2
|
Subproject commit 5c213f10c5db7e8f11a36d660902ac7183ce177f
|
Loading…
Reference in a new issue