small fixes

This commit is contained in:
Dmitriy Kholkin 2024-01-27 18:30:31 +03:00
parent cbed702076
commit 60d0753c11
Signed by: AtaraxiaDev
GPG Key ID: FD266B810DF48DF2
4 changed files with 23 additions and 23 deletions

View File

@ -1,10 +1,9 @@
# TODO
* grafana for all services
* move some profiles to modules (like vpn.nix)
* use sops for all occurrences of hashedPassword
* auto-import gpg keys
* wait headscale start until authentik
* auto-login to tailscale for hypervisor
* config qbittorrent
* fix waybar config
* change writeShellScript and writeShellScriptBin to writeShellApplication

View File

@ -48,7 +48,7 @@ in
type = with types; nullOr str;
default = null;
description = lib.mdDoc ''
file in the format of an EnvironmentFile as described by systemd.exec(5).
File in the format of an EnvironmentFile as described by systemd.exec(5).
'';
};
adminpassFile = mkOption {

View File

@ -5,7 +5,6 @@ let
fonts = config.lib.base16.theme.fonts;
profileName = config.mainuser;
homeDir = config.home-manager.users.${profileName}.home.homeDirectory;
profilePath = ".mozilla/firefox/${profileName}";
mkUserJs = { prefs ? {}, extraPrefs ? "" }: ''
${extraPrefs}
@ -14,9 +13,7 @@ let
'') prefs)}
'';
firefox-kpoxa = pkgs.writeShellScriptBin "firefox-kpoxa" ''
${pkgs.firefox}/bin/firefox -profile ${homeDir}/.mozilla/firefox/kpoxa
'';
in {
services.dbus.packages = [ pkgs.firefox-wayland ];
@ -24,29 +21,35 @@ in {
MOZ_USE_XINPUT2 = "1";
MOZ_DBUS_REMOTE = "1";
};
# programs.browserpass.enable = true;
defaultApplications.browser = {
cmd = "${pkgs.firefox}/bin/firefox";
desktop = "firefox";
};
home-manager.users.${config.mainuser} = {
home.packages = [ firefox-kpoxa ];
# Mailvelope GnuPG integration
home.file.".mozilla/native-messaging-hosts/gpgmejson.json".text = ''
{
"name": "gpgmejson",
"description": "JavaScript binding for GnuPG",
"path": "${pkgs.gpgme.dev}/bin/gpgme-json",
"type": "stdio",
"allowed_extensions": ["jid1-AQqSMBYb0a8ADg@jetpack"]
}
home-manager.users.${config.mainuser} = let
firefoxFinal = config.home-manager.users.${config.mainuser}.programs.firefox.finalPackage;
firefox-kpoxa = pkgs.writeShellScriptBin "firefox-kpoxa" ''
${firefoxFinal}/bin/firefox -profile ${homeDir}/.mozilla/firefox/kpoxa
'';
in {
home.packages = [ firefox-kpoxa ];
programs.firefox = {
enable = true;
package = pkgs.firefox;
package = pkgs.firefox.override {
# Mailvelope GnuPG integration
nativeMessagingHosts = [
(pkgs.writeTextDir "lib/mozilla/native-messaging-hosts/gpgmejson.json" ''
{
"name": "gpgmejson",
"description": "JavaScript binding for GnuPG",
"path": "${pkgs.gpgme.dev}/bin/gpgme-json",
"type": "stdio",
"allowed_extensions": ["jid1-AQqSMBYb0a8ADg@jetpack"]
}
'')
];
};
profiles = {
${config.mainuser} = {
id = 0;
@ -99,7 +102,6 @@ in {
"network.allow-experiments" = false;
"network.protocol-handler.external.element" = false;
# "identity.sync.tokenserver.uri" = "https://fsync.ataraxiadev.com/1.0/sync/1.5";
};
extraPrefs = "${fileContents "${pkgs.arkenfox-userjs}/share/user.js/user.js"}";
};

View File

@ -31,7 +31,6 @@
users.users.atticd = {
isSystemUser = true;
group = "atticd";
hashedPassword = "$y$j9T$ZC44T3XYOPapB26cyPsA4.$8wlYEbwXFszC9nrg0vafqBZFLMPabXdhnzlT3DhUit6";
};
systemd.services.atticd = {