run nix fmt

This commit is contained in:
Johannes Jöns 2024-07-10 23:02:54 +02:00
parent eab8e4b1d8
commit d5cbe31c02
61 changed files with 1299 additions and 830 deletions

View file

@ -43,7 +43,6 @@
inputs.nixpkgs.follows = "nixpkgs";
};
# Packages
tela-icon-theme = {
url = "github:vinceliuice/Tela-icon-theme";
@ -67,18 +66,21 @@
};
};
outputs = inputs@{ self, nixpkgs, ... }: {
nixosModules.default = import ./modules;
homeManagerModules.default = import ./home-modules;
nixosConfigurations = import ./systems {
inherit self inputs nixpkgs;
outputs =
inputs@{ self, nixpkgs, ... }:
{
nixosModules.default = import ./modules;
homeManagerModules.default = import ./home-modules;
nixosConfigurations = import ./systems { inherit self inputs nixpkgs; };
packages = nixpkgs.lib.attrsets.genAttrs nixpkgs.lib.systems.flakeExposed (
system:
import ./packages {
inherit system inputs;
pkgs = nixpkgs.legacyPackages.${system};
}
);
formatter = nixpkgs.lib.attrsets.genAttrs nixpkgs.lib.systems.flakeExposed (
system: nixpkgs.legacyPackages.${system}.nixfmt-rfc-style
);
};
packages = nixpkgs.lib.attrsets.genAttrs nixpkgs.lib.systems.flakeExposed (system: import ./packages {
inherit system inputs;
pkgs = nixpkgs.legacyPackages.${system};
});
formatter = nixpkgs.lib.attrsets.genAttrs nixpkgs.lib.systems.flakeExposed (system:
nixpkgs.legacyPackages.${system}.nixfmt-rfc-style
);
};
}

View file

@ -1,7 +1,9 @@
{ config, lib, ... }:
let cfg = config.jopejoe1.common;
in {
let
cfg = config.jopejoe1.common;
in
{
options.jopejoe1.common = {
enable = lib.mkEnableOption "Enable Common Homanger settings";
gui = lib.mkEnableOption "Graphical programms";
@ -63,4 +65,3 @@ in {
};
};
}

View file

@ -1,7 +1,9 @@
{ config, lib, ... }:
let cfg = config.jopejoe1.direnv;
in {
let
cfg = config.jopejoe1.direnv;
in
{
options.jopejoe1.direnv = {
enable = lib.mkEnableOption "Enable direnv";
};
@ -13,5 +15,3 @@ in {
};
};
}

View file

@ -1,4 +1,10 @@
{ config, lib, pkgs, inputs, ... }:
{
config,
lib,
pkgs,
inputs,
...
}:
let
cfg = config.jopejoe1.firefox;
@ -6,7 +12,8 @@ let
Value = value;
Status = "locked";
};
in {
in
{
options.jopejoe1.firefox = {
enable = lib.mkEnableOption "Enable Firefox";
};
@ -90,68 +97,70 @@ in {
};
Preferences = {
"privacy.resistFingerprinting" = lock true;
"privacy.trackingprotection.fingerprinting.enabled" = lock true;
"privacy.trackingprotection.cryptomining.enabled" = lock true;
"dom.event.clipboardevents.enabled" = lock false;
"dom.battery.enabled" = lock false;
"browser.safebrowsing.phishing.enabled" = lock false;
"browser.safebrowsing.malware.enabled" = lock false;
"browser.zoom.siteSpecific" = lock true;
"config.trim_on_minimize" = lock true;
"pdfjs.annotationEditorMode" = lock 0;
"pdfjs.annotationMode" = lock 2;
"font.name-list.emoji" = lock (lib.strings.concatStringsSep ", " config.jopejoe1.common.fonts.emoji);
"privacy.trackingprotection.fingerprinting.enabled" = lock true;
"privacy.trackingprotection.cryptomining.enabled" = lock true;
"dom.event.clipboardevents.enabled" = lock false;
"dom.battery.enabled" = lock false;
"browser.safebrowsing.phishing.enabled" = lock false;
"browser.safebrowsing.malware.enabled" = lock false;
"browser.zoom.siteSpecific" = lock true;
"config.trim_on_minimize" = lock true;
"pdfjs.annotationEditorMode" = lock 0;
"pdfjs.annotationMode" = lock 2;
"font.name-list.emoji" = lock (
lib.strings.concatStringsSep ", " config.jopejoe1.common.fonts.emoji
);
# Theming
"widget.gtk.overlay-scrollbars.enabled" = lock false;
# Theming
"widget.gtk.overlay-scrollbars.enabled" = lock false;
## Arkenfox Stuff
"browser.aboutConfig.showWarning" = lock false;
"browser.newtabpage.activity-stream.showSponsored" = lock false;
"browser.newtabpage.activity-stream.showSponsoredTopSites" = lock false;
"extensions.getAddons.showPane" = lock false;
"extensions.htmlaboutaddons.recommendations.enabled" = lock false;
"browser.discovery.enabled" = lock false;
"browser.shopping.experience2023.enabled" = lock false;
"datareporting.policy.dataSubmissionEnabled" = lock false;
"datareporting.healthreport.uploadEnabled" = lock false;
"toolkit.telemetry.unified" = lock false;
"toolkit.telemetry.enabled" = lock false;
"toolkit.telemetry.server" = lock "data:,";
"toolkit.telemetry.archive.enabled" = lock false;
"toolkit.telemetry.newProfilePing.enabled" = lock false;
"toolkit.telemetry.shutdownPingSender.enabled" = lock false;
"toolkit.telemetry.updatePing.enabled" = lock false;
"toolkit.telemetry.bhrPing.enabled" = lock false;
"toolkit.telemetry.firstShutdownPing.enabled" = lock false;
"toolkit.telemetry.coverage.opt-out" = lock true;
"toolkit.coverage.opt-out" = lock true;
"toolkit.coverage.endpoint.base" = lock "";
"browser.ping-centre.telemetry" = lock false;
"browser.newtabpage.activity-stream.feeds.telemetry" = lock false;
"browser.newtabpage.activity-stream.telemetry" = lock false;
"app.shield.optoutstudies.enabled" = lock false;
"app.normandy.enabled" = lock false;
"app.normandy.api_url" = lock "";
"breakpad.reportURL" = lock "";
"browser.tabs.crashReporting.sendReport" = lock false;
"browser.crashReports.unsubmittedCheck.autoSubmit2" = lock false;
"captivedetect.canonicalURL" = lock "";
"network.captive-portal-service.enabled" = lock false;
"network.connectivity-service.enabled" = lock false;
"network.prefetch-next" = lock false;
"network.dns.disablePrefetch" = lock true;
"network.predictor.enabled" = lock false;
"network.predictor.enable-prefetch" = lock false;
"network.http.speculative-parallel-limit" = lock 0;
"browser.places.speculativeConnect.enabled" = lock false;
"browser.urlbar.speculativeConnect.enabled" = lock false;
"browser.urlbar.suggest.quicksuggest.nonsponsored" = lock false;
"browser.urlbar.suggest.quicksuggest.sponsored" = lock false;
"browser.formfill.enable" = lock false;
"browser.download.start_downloads_in_tmp_dir" = lock true;
"browser.uitour.enabled" = lock false;
"browser.tabs.inTitlebar" = lock 0;
## Arkenfox Stuff
"browser.aboutConfig.showWarning" = lock false;
"browser.newtabpage.activity-stream.showSponsored" = lock false;
"browser.newtabpage.activity-stream.showSponsoredTopSites" = lock false;
"extensions.getAddons.showPane" = lock false;
"extensions.htmlaboutaddons.recommendations.enabled" = lock false;
"browser.discovery.enabled" = lock false;
"browser.shopping.experience2023.enabled" = lock false;
"datareporting.policy.dataSubmissionEnabled" = lock false;
"datareporting.healthreport.uploadEnabled" = lock false;
"toolkit.telemetry.unified" = lock false;
"toolkit.telemetry.enabled" = lock false;
"toolkit.telemetry.server" = lock "data:,";
"toolkit.telemetry.archive.enabled" = lock false;
"toolkit.telemetry.newProfilePing.enabled" = lock false;
"toolkit.telemetry.shutdownPingSender.enabled" = lock false;
"toolkit.telemetry.updatePing.enabled" = lock false;
"toolkit.telemetry.bhrPing.enabled" = lock false;
"toolkit.telemetry.firstShutdownPing.enabled" = lock false;
"toolkit.telemetry.coverage.opt-out" = lock true;
"toolkit.coverage.opt-out" = lock true;
"toolkit.coverage.endpoint.base" = lock "";
"browser.ping-centre.telemetry" = lock false;
"browser.newtabpage.activity-stream.feeds.telemetry" = lock false;
"browser.newtabpage.activity-stream.telemetry" = lock false;
"app.shield.optoutstudies.enabled" = lock false;
"app.normandy.enabled" = lock false;
"app.normandy.api_url" = lock "";
"breakpad.reportURL" = lock "";
"browser.tabs.crashReporting.sendReport" = lock false;
"browser.crashReports.unsubmittedCheck.autoSubmit2" = lock false;
"captivedetect.canonicalURL" = lock "";
"network.captive-portal-service.enabled" = lock false;
"network.connectivity-service.enabled" = lock false;
"network.prefetch-next" = lock false;
"network.dns.disablePrefetch" = lock true;
"network.predictor.enabled" = lock false;
"network.predictor.enable-prefetch" = lock false;
"network.http.speculative-parallel-limit" = lock 0;
"browser.places.speculativeConnect.enabled" = lock false;
"browser.urlbar.speculativeConnect.enabled" = lock false;
"browser.urlbar.suggest.quicksuggest.nonsponsored" = lock false;
"browser.urlbar.suggest.quicksuggest.sponsored" = lock false;
"browser.formfill.enable" = lock false;
"browser.download.start_downloads_in_tmp_dir" = lock true;
"browser.uitour.enabled" = lock false;
"browser.tabs.inTitlebar" = lock 0;
};
"3rdparty" = {
Extensions = {
@ -162,43 +171,43 @@ in {
uiAccentCustom0 = "#b4befe";
cloudStorageEnabled = false;
};
selectedFilterLists = [
"adguard-generic"
"adguard-annoyance"
"adguard-cookies"
"adguard-social"
"adguard-spyware"
"adguard-spyware-url"
"adguard-popup-overlays"
"adguard-other-annoyances"
"adguard-widgets"
"block-lan"
"curben-phishing"
"dpollock-0"
"easylist"
"easylist-chat"
"easylist-newsletters"
"easylist-notifications"
"easylist-annoyances"
"easyprivacy"
"fanboy-cookiemonster"
"fanboy-social"
"fanboy-thirdparty_social"
"FIN-0"
"plowe-0"
"ublock-abuse"
"ublock-badware"
"ublock-cookies-adguard"
"ublock-cookies-easylist"
"ublock-filters"
"ublock-privacy"
"ublock-quick-fixes"
"ublock-unbreak"
"ublock-annoyances"
"urlhaus-1"
];
};
filters = [''stackoverflow.com##.sm\:fd-column.flex__allitems6.d-flex.mx-auto.wmx9''];
selectedFilterLists = [
"adguard-generic"
"adguard-annoyance"
"adguard-cookies"
"adguard-social"
"adguard-spyware"
"adguard-spyware-url"
"adguard-popup-overlays"
"adguard-other-annoyances"
"adguard-widgets"
"block-lan"
"curben-phishing"
"dpollock-0"
"easylist"
"easylist-chat"
"easylist-newsletters"
"easylist-notifications"
"easylist-annoyances"
"easyprivacy"
"fanboy-cookiemonster"
"fanboy-social"
"fanboy-thirdparty_social"
"FIN-0"
"plowe-0"
"ublock-abuse"
"ublock-badware"
"ublock-cookies-adguard"
"ublock-cookies-easylist"
"ublock-filters"
"ublock-privacy"
"ublock-quick-fixes"
"ublock-unbreak"
"ublock-annoyances"
"urlhaus-1"
];
};
filters = [ ''stackoverflow.com##.sm\:fd-column.flex__allitems6.d-flex.mx-auto.wmx9'' ];
};
};
};
@ -239,138 +248,162 @@ in {
force = true;
engines = {
"Nix Packages" = {
urls = [{
template = "https://search.nixos.org/packages";
params = [
{
name = "type";
value = "packages";
}
{
name = "channel";
value = "unstable";
}
{
name = "query";
value = "{searchTerms}";
}
];
}];
urls = [
{
template = "https://search.nixos.org/packages";
params = [
{
name = "type";
value = "packages";
}
{
name = "channel";
value = "unstable";
}
{
name = "query";
value = "{searchTerms}";
}
];
}
];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = [ "@np" ];
};
"NixOS Modules" = {
urls = [{
template = "https://search.nixos.org/options";
params = [
{
name = "type";
value = "packages";
}
{
name = "channel";
value = "unstable";
}
{
name = "query";
value = "{searchTerms}";
}
];
}];
urls = [
{
template = "https://search.nixos.org/options";
params = [
{
name = "type";
value = "packages";
}
{
name = "channel";
value = "unstable";
}
{
name = "query";
value = "{searchTerms}";
}
];
}
];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = [ "@nm" ];
};
"Home Manager Modules" = {
urls = [{
template = "https://home-manager-options.extranix.com/";
params = [
{
name = "query";
value = "{searchTerms}";
}
{
name = "release";
value = "master";
}
];
}];
urls = [
{
template = "https://home-manager-options.extranix.com/";
params = [
{
name = "query";
value = "{searchTerms}";
}
{
name = "release";
value = "master";
}
];
}
];
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
definedAliases = [ "@hm" ];
};
"Repology" = {
urls = [{
template = "https://repology.org/projects";
params = [
{
name = "search";
value = "{searchTerms}";
}
];
}];
urls = [
{
template = "https://repology.org/projects";
params = [
{
name = "search";
value = "{searchTerms}";
}
];
}
];
iconUpdateURL = "https://raw.githubusercontent.com/repology/repology-webapp/master/repologyapp/static/repology40x40.v1.png";
updateInterval = 24 * 60 * 60 * 1000;
definedAliases = [ "@repo" ];
};
"NixOS Wiki" = {
urls = [{
template = "https://wiki.nixos.org/w/index.php";
params = [{
name = "search";
value = "{searchTerms}";
}];
}];
urls = [
{
template = "https://wiki.nixos.org/w/index.php";
params = [
{
name = "search";
value = "{searchTerms}";
}
];
}
];
icon = "${config.programs.firefox.profiles.default.search.engines."Nix Packages".icon}";
definedAliases = [ "@nw" ];
};
"Arch Wiki" = {
urls = [{
template = "https://wiki.archlinux.org/index.php";
params = [{
name = "search";
value = "{searchTerms}";
}];
}];
urls = [
{
template = "https://wiki.archlinux.org/index.php";
params = [
{
name = "search";
value = "{searchTerms}";
}
];
}
];
iconUpdateURL = "https://upload.wikimedia.org/wikipedia/commons/1/13/Arch_Linux_%22Crystal%22_icon.svg";
updateInterval = 24 * 60 * 60 * 1000;
definedAliases = [ "@arch" ];
};
"Minecraft Wiki" = {
urls = [{
template = "https://minecraft.wiki/";
params = [{
name = "search";
value = "{searchTerms}";
}];
}];
urls = [
{
template = "https://minecraft.wiki/";
params = [
{
name = "search";
value = "{searchTerms}";
}
];
}
];
iconUpdateURL = "https://minecraft.wiki/images/Wiki.png";
updateInterval = 24 * 60 * 60 * 1000;
definedAliases = [ "@mc" ];
};
"Warframe Wiki" = {
urls = [{
template =
"https://warframe.fandom.com/wiki/Special:Search";
params = [{
name = "query";
value = "{searchTerms}";
}];
}];
iconUpdateURL =
"https://static.wikia.nocookie.net/warframe/images/e/e6/Site-logo.png";
urls = [
{
template = "https://warframe.fandom.com/wiki/Special:Search";
params = [
{
name = "query";
value = "{searchTerms}";
}
];
}
];
iconUpdateURL = "https://static.wikia.nocookie.net/warframe/images/e/e6/Site-logo.png";
updateInterval = 24 * 60 * 60 * 1000;
definedAliases = [ "@wf" ];
};
"DuckDuckGo" = {
urls = [{
template =
"https://duckduckgo.com";
params = [{
name = "q";
value = "{searchTerms}";
}];
}];
iconUpdateURL =
"https://duckduckgo.com/assets/logo_header.v109.svg";
urls = [
{
template = "https://duckduckgo.com";
params = [
{
name = "q";
value = "{searchTerms}";
}
];
}
];
iconUpdateURL = "https://duckduckgo.com/assets/logo_header.v109.svg";
updateInterval = 24 * 60 * 60 * 1000;
definedAliases = [ "ddg" ];
};
@ -395,4 +428,3 @@ in {
};
};
}

View file

@ -1,7 +1,14 @@
{ config, lib, pkgs, ... }:
{
config,
lib,
pkgs,
...
}:
let cfg = config.jopejoe1.git;
in {
let
cfg = config.jopejoe1.git;
in
{
options.jopejoe1.git = {
enable = lib.mkEnableOption "Enable Git";
};
@ -15,11 +22,13 @@ in {
userName = "jopejoe1";
extraConfig = {
core = {
whitespace = [ "blank-at-eol" "blank-at-eof" "space-before-tab" ];
whitespace = [
"blank-at-eol"
"blank-at-eof"
"space-before-tab"
];
};
};
};
};
}

View file

@ -1,7 +1,14 @@
{ config, lib, pkgs, ... }:
{
config,
lib,
pkgs,
...
}:
let cfg = config.jopejoe1.gpg;
in {
let
cfg = config.jopejoe1.gpg;
in
{
options.jopejoe1.gpg = {
enable = lib.mkEnableOption "Enable Nushell";
};
@ -15,5 +22,3 @@ in {
};
};
}

View file

@ -1,7 +1,14 @@
{ config, lib, pkgs, ... }:
{
config,
lib,
pkgs,
...
}:
let cfg = config.jopejoe1.nushell;
in {
let
cfg = config.jopejoe1.nushell;
in
{
options.jopejoe1.nushell = {
enable = lib.mkEnableOption "Enable Nushell";
};
@ -28,5 +35,3 @@ in {
};
};
}

View file

@ -1,8 +1,12 @@
{ config, lib, ... }:
let cfg = config.jopejoe1.asf;
in {
options.jopejoe1.asf = { enable = lib.mkEnableOption "Enable ASF"; };
let
cfg = config.jopejoe1.asf;
in
{
options.jopejoe1.asf = {
enable = lib.mkEnableOption "Enable ASF";
};
config = lib.mkIf cfg.enable {
services.archisteamfarm = {
@ -27,4 +31,3 @@ in {
};
};
}

View file

@ -1,7 +1,14 @@
{ config, lib, pkgs, ... }:
{
config,
lib,
pkgs,
...
}:
let cfg = config.jopejoe1.audio;
in {
let
cfg = config.jopejoe1.audio;
in
{
options.jopejoe1.audio = {
enable = lib.mkEnableOption "Enable Audio";
sennheiser-hd-660s = lib.mkEnableOption "Equalizer for Sennheiser HD 660S";
@ -23,37 +30,40 @@ in {
wireplumber.enable = true;
extraConfig.pipewire."30-noise-filter" = {
"context.modules" = [{
name = "libpipewire-module-filter-chain";
args = {
"node.description" = "Noise Canceling source";
"media.name" = "Noise Canceling source";
"filter.graph" = {
nodes = [{
type = "ladspa";
name = "rnnoise";
plugin =
"${pkgs.rnnoise-plugin}/lib/ladspa/librnnoise_ladspa.so";
label = "noise_suppressor_mono";
control = {
"VAD Threshold (%)" = 50.0;
#"VAD Grace Period (ms)" = 0;
"Retroactive VAD Grace (ms)" = 50;
};
}];
"context.modules" = [
{
name = "libpipewire-module-filter-chain";
args = {
"node.description" = "Noise Canceling source";
"media.name" = "Noise Canceling source";
"filter.graph" = {
nodes = [
{
type = "ladspa";
name = "rnnoise";
plugin = "${pkgs.rnnoise-plugin}/lib/ladspa/librnnoise_ladspa.so";
label = "noise_suppressor_mono";
control = {
"VAD Threshold (%)" = 50.0;
#"VAD Grace Period (ms)" = 0;
"Retroactive VAD Grace (ms)" = 50;
};
}
];
};
"capture.props" = {
"node.name" = "capture.rnnoise_source";
"node.passive" = true;
"audio.rate" = 48000;
};
"playback.props" = {
"node.name" = "rnnoise_source";
"media.class" = "Audio/Source";
"audio.rate" = 48000;
};
};
"capture.props" = {
"node.name" = "capture.rnnoise_source";
"node.passive" = true;
"audio.rate" = 48000;
};
"playback.props" = {
"node.name" = "rnnoise_source";
"media.class" = "Audio/Source";
"audio.rate" = 48000;
};
};
}];
}
];
};
};
};

View file

@ -1,185 +1,191 @@
{ config, lib, ... }:
let cfg = config.jopejoe1.audio;
in {
let
cfg = config.jopejoe1.audio;
in
{
config = lib.mkIf cfg.sennheiser-hd-660s {
services.pipewire = {
extraConfig.pipewire."20-Senheiser-HD660S" = {
"context.modules" = [{
name = "libpipewire-module-filter-chain";
args = {
"node.description" = "Senheiser HD 660 S Equaliser";
"media.name" = "Senheiser HD 660 S Equaliser";
"filter.graph" = {
nodes = [
{
type = "builtin";
name = "eq_band_1";
label = "bq_highshelf";
control = {
"Freq" = 0.0;
"Q" = 1.0;
"Gain" = -6.4;
};
}
{
type = "builtin";
name = "eq_band_2";
label = "bq_lowshelf";
control = {
"Freq" = 105.0;
"Q" = 0.7;
"Gain" = 6.5;
};
}
{
type = "builtin";
name = "eq_band_3";
label = "bq_peaking";
control = {
"Freq" = 178.0;
"Q" = 0.49;
"Gain" = -3.2;
};
}
{
type = "builtin";
name = "eq_band_4";
label = "bq_peaking";
control = {
"Freq" = 1222.0;
"Q" = 2.34;
"Gain" = -2.3;
};
}
{
type = "builtin";
name = "eq_band_5";
label = "bq_peaking";
control = {
"Freq" = 5470.0;
"Q" = 4.4;
"Gain" = -7.3;
};
}
{
type = "builtin";
name = "eq_band_6";
label = "bq_peaking";
control = {
"Freq" = 7899.0;
"Q" = 0.68;
"Gain" = 6.5;
};
}
{
type = "builtin";
name = "eq_band_7";
label = "bq_peaking";
control = {
"Freq" = 784.0;
"Q" = 3.52;
"Gain" = -0.4;
};
}
{
type = "builtin";
name = "eq_band_8";
label = "bq_peaking";
control = {
"Freq" = 2250.0;
"Q" = 3.58;
"Gain" = 1.3;
};
}
{
type = "builtin";
name = "eq_band_9";
label = "bq_peaking";
control = {
"Freq" = 3380.0;
"Q" = 2.84;
"Gain" = -0.9;
};
}
{
type = "builtin";
name = "eq_band_10";
label = "bq_peaking";
control = {
"Freq" = 6701.0;
"Q" = 6.0;
"Gain" = 1.2;
};
}
{
type = "builtin";
name = "eq_band_11";
label = "bq_highshelf";
control = {
"Freq" = 10000.0;
"Q" = 0.7;
"Gain" = -1.1;
};
}
];
links = [
{
output = "eq_band_1:Out";
input = "eq_band_2:In";
}
{
output = "eq_band_2:Out";
input = "eq_band_3:In";
}
{
output = "eq_band_3:Out";
input = "eq_band_4:In";
}
{
output = "eq_band_4:Out";
input = "eq_band_5:In";
}
{
output = "eq_band_5:Out";
input = "eq_band_6:In";
}
{
output = "eq_band_6:Out";
input = "eq_band_7:In";
}
{
output = "eq_band_7:Out";
input = "eq_band_8:In";
}
{
output = "eq_band_8:Out";
input = "eq_band_9:In";
}
{
output = "eq_band_9:Out";
input = "eq_band_10:In";
}
{
output = "eq_band_10:Out";
input = "eq_band_11:In";
}
"context.modules" = [
{
name = "libpipewire-module-filter-chain";
args = {
"node.description" = "Senheiser HD 660 S Equaliser";
"media.name" = "Senheiser HD 660 S Equaliser";
"filter.graph" = {
nodes = [
{
type = "builtin";
name = "eq_band_1";
label = "bq_highshelf";
control = {
"Freq" = 0.0;
"Q" = 1.0;
"Gain" = -6.4;
};
}
{
type = "builtin";
name = "eq_band_2";
label = "bq_lowshelf";
control = {
"Freq" = 105.0;
"Q" = 0.7;
"Gain" = 6.5;
};
}
{
type = "builtin";
name = "eq_band_3";
label = "bq_peaking";
control = {
"Freq" = 178.0;
"Q" = 0.49;
"Gain" = -3.2;
};
}
{
type = "builtin";
name = "eq_band_4";
label = "bq_peaking";
control = {
"Freq" = 1222.0;
"Q" = 2.34;
"Gain" = -2.3;
};
}
{
type = "builtin";
name = "eq_band_5";
label = "bq_peaking";
control = {
"Freq" = 5470.0;
"Q" = 4.4;
"Gain" = -7.3;
};
}
{
type = "builtin";
name = "eq_band_6";
label = "bq_peaking";
control = {
"Freq" = 7899.0;
"Q" = 0.68;
"Gain" = 6.5;
};
}
{
type = "builtin";
name = "eq_band_7";
label = "bq_peaking";
control = {
"Freq" = 784.0;
"Q" = 3.52;
"Gain" = -0.4;
};
}
{
type = "builtin";
name = "eq_band_8";
label = "bq_peaking";
control = {
"Freq" = 2250.0;
"Q" = 3.58;
"Gain" = 1.3;
};
}
{
type = "builtin";
name = "eq_band_9";
label = "bq_peaking";
control = {
"Freq" = 3380.0;
"Q" = 2.84;
"Gain" = -0.9;
};
}
{
type = "builtin";
name = "eq_band_10";
label = "bq_peaking";
control = {
"Freq" = 6701.0;
"Q" = 6.0;
"Gain" = 1.2;
};
}
{
type = "builtin";
name = "eq_band_11";
label = "bq_highshelf";
control = {
"Freq" = 10000.0;
"Q" = 0.7;
"Gain" = -1.1;
};
}
];
links = [
{
output = "eq_band_1:Out";
input = "eq_band_2:In";
}
{
output = "eq_band_2:Out";
input = "eq_band_3:In";
}
{
output = "eq_band_3:Out";
input = "eq_band_4:In";
}
{
output = "eq_band_4:Out";
input = "eq_band_5:In";
}
{
output = "eq_band_5:Out";
input = "eq_band_6:In";
}
{
output = "eq_band_6:Out";
input = "eq_band_7:In";
}
{
output = "eq_band_7:Out";
input = "eq_band_8:In";
}
{
output = "eq_band_8:Out";
input = "eq_band_9:In";
}
{
output = "eq_band_9:Out";
input = "eq_band_10:In";
}
{
output = "eq_band_10:Out";
input = "eq_band_11:In";
}
];
};
"audio.channels" = 2;
"audio.position" = [
"FL"
"FR"
];
"capture.props" = {
"node.name" = "effect_input.eq11";
"media.class" = "Audio/Sink";
};
"playback.props" = {
"node.name" = "effect_output.eq11";
"node.passive" = true;
};
};
"audio.channels" = 2;
"audio.position" = [ "FL" "FR" ];
"capture.props" = {
"node.name" = "effect_input.eq11";
"media.class" = "Audio/Sink";
};
"playback.props" = {
"node.name" = "effect_output.eq11";
"node.passive" = true;
};
};
}];
}
];
};
};
};
}

View file

@ -1,7 +1,14 @@
{ config, lib, pkgs, ... }:
{
config,
lib,
pkgs,
...
}:
let cfg = config.jopejoe1.auto-update;
in {
let
cfg = config.jopejoe1.auto-update;
in
{
options.jopejoe1.auto-update = {
enable = lib.mkEnableOption "Enable Auto-Updates";
};
@ -12,11 +19,7 @@ in {
randomizedDelaySec = "30min";
flake =
if config.services.archisteamfarm.enable then
"$(${pkgs.coreutils}/bin/rm -rf /var/lib/update-repo && ${
lib.getExe pkgs.git
} clone git@codeberg.org:jopejoe1/nix-conf.git /var/lib/update-repo -q --depth=1 && ${
lib.getExe pkgs.git
} -C /var/lib/update-repo am /home/jopejoe1/.config/patches/0001-add-liscense.patch -q)/var/lib/update-repo"
"$(${pkgs.coreutils}/bin/rm -rf /var/lib/update-repo && ${lib.getExe pkgs.git} clone git@codeberg.org:jopejoe1/nix-conf.git /var/lib/update-repo -q --depth=1 && ${lib.getExe pkgs.git} -C /var/lib/update-repo am /home/jopejoe1/.config/patches/0001-add-liscense.patch -q)/var/lib/update-repo"
else
"github:jopejoe1/nix-conf";
dates = "hourly";

View file

@ -1,7 +1,9 @@
{ config, lib, ... }:
let cfg = config.jopejoe1.bluetooth;
in {
let
cfg = config.jopejoe1.bluetooth;
in
{
options.jopejoe1.bluetooth = {
enable = lib.mkEnableOption "Enable Bluetooth";
};

View file

@ -1,7 +1,5 @@
{ ... }:
{
imports = [
./systemd
];
imports = [ ./systemd ];
}

View file

@ -1,7 +1,9 @@
{ config, lib, ... }:
let cfg = config.jopejoe1.boot.systemd;
in {
let
cfg = config.jopejoe1.boot.systemd;
in
{
options.jopejoe1.boot.systemd = {
enable = lib.mkEnableOption "Enable Systemd boot";
};

View file

@ -1,8 +1,18 @@
{ config, lib, pkgs, self, ... }:
{
config,
lib,
pkgs,
self,
...
}:
let cfg = config.jopejoe1.doc;
in {
options.jopejoe1.doc = { enable = lib.mkEnableOption "Enable Documentation"; };
let
cfg = config.jopejoe1.doc;
in
{
options.jopejoe1.doc = {
enable = lib.mkEnableOption "Enable Documentation";
};
config = lib.mkIf cfg.enable {
documentation = {

View file

@ -1,7 +1,9 @@
{ config, lib, ... }:
let cfg = config.events."37c3";
in {
let
cfg = config.events."37c3";
in
{
options.events."37c3" = {
enable = lib.mkEnableOption "Enable settings for the 37c3 event";
};
@ -29,7 +31,9 @@ in {
password = "37C3";
phase2-auth = "mschapv2";
};
ipv4 = { method = "auto"; };
ipv4 = {
method = "auto";
};
ipv6 = {
addr-gen-mode = "default";
method = "auto";
@ -43,8 +47,7 @@ in {
ca_cert="${
builtins.fetchurl {
url = "https://letsencrypt.org/certs/isrgrootx1.pem";
sha256 =
"sha256:1la36n2f31j9s03v847ig6ny9lr875q3g7smnq33dcsmf2i5gd92";
sha256 = "sha256:1la36n2f31j9s03v847ig6ny9lr875q3g7smnq33dcsmf2i5gd92";
}
}"
altsubject_match="DNS:radius.c3noc.net"

View file

@ -1,7 +1,14 @@
{ config, lib, pkgs, ... }:
{
config,
lib,
pkgs,
...
}:
let cfg = config.jopejoe1.keyboard;
in {
let
cfg = config.jopejoe1.keyboard;
in
{
options.jopejoe1.keyboard = {
enable = lib.mkEnableOption "Enable Keyboard";
layout = lib.mkOption {
@ -23,4 +30,3 @@ in {
};
};
}

View file

@ -1,8 +1,18 @@
{ config, lib, pkgs, self, ... }:
{
config,
lib,
pkgs,
self,
...
}:
let cfg = config.jopejoe1.kodi;
in {
options.jopejoe1.kodi = { enable = lib.mkEnableOption "Enable Kodi"; };
let
cfg = config.jopejoe1.kodi;
in
{
options.jopejoe1.kodi = {
enable = lib.mkEnableOption "Enable Kodi";
};
config = lib.mkIf cfg.enable {
environment.systemPackages = [ pkgs.kodi-wayland ];

View file

@ -1,8 +1,17 @@
{ config, lib, pkgs, ... }:
{
config,
lib,
pkgs,
...
}:
let cfg = config.jopejoe1.local;
in {
options.jopejoe1.local = { enable = lib.mkEnableOption "Enable Locals"; };
let
cfg = config.jopejoe1.local;
in
{
options.jopejoe1.local = {
enable = lib.mkEnableOption "Enable Locals";
};
config = lib.mkIf cfg.enable {
xdg = {
@ -35,9 +44,10 @@ in {
};
};
environment.variables = { LOG_ICONS = "true"; };
environment.variables = {
LOG_ICONS = "true";
};
fonts.fontDir.enable = true;
};
}

View file

@ -1,7 +1,9 @@
{ config, lib, ... }:
let cfg = config.jopejoe1.minecraft-server;
in {
let
cfg = config.jopejoe1.minecraft-server;
in
{
options.jopejoe1.minecraft-server = {
enable = lib.mkEnableOption "Enable Bluetooth";
};
@ -16,8 +18,7 @@ in {
difficulty = 3;
enable-rcon = true;
"rcon.password" = "test";
motd =
"\\u00A7cWake up to reality! Nothing ever goes as planned in this accursed world.";
motd = "\\u00A7cWake up to reality! Nothing ever goes as planned in this accursed world.";
spawn-protection = 0;
level-type = "minecraft:amplified";
level-name = "amplified_world";

View file

@ -1,7 +1,14 @@
{ config, lib, pkgs, ... }:
{
config,
lib,
pkgs,
...
}:
let cfg = config.jopejoe1.moodle-dl;
in {
let
cfg = config.jopejoe1.moodle-dl;
in
{
options.jopejoe1.moodle-dl = {
enable = lib.mkEnableOption "Enable moodle-dl";
};
@ -22,7 +29,12 @@ in {
git -C /var/lib/moodle-dl add .
git -C /var/lib/moodle-dl commit -m "moodle-dl updated on `$(date)`"
'';
path = with pkgs; [ openssh moodle-dl git coreutils ];
path = with pkgs; [
openssh
moodle-dl
git
coreutils
];
serviceConfig = {
Type = "oneshot";
User = "root";
@ -30,4 +42,3 @@ in {
};
};
}

View file

@ -1,9 +1,21 @@
{ config, lib, pkgs, self, ... }:
{
config,
lib,
pkgs,
self,
...
}:
let cfg = config.jopejoe1.nix;
in {
options.jopejoe1.nix = { enable = lib.mkEnableOption "Enable Nix"; };
options.jopejoe1.gui = { enable = lib.mkEnableOption "Enable GUI"; };
let
cfg = config.jopejoe1.nix;
in
{
options.jopejoe1.nix = {
enable = lib.mkEnableOption "Enable Nix";
};
options.jopejoe1.gui = {
enable = lib.mkEnableOption "Enable GUI";
};
config = lib.mkIf cfg.enable {
nix = {
@ -31,39 +43,44 @@ in {
keep-going = true;
builders-use-substitutes = true;
};
# buildMachines = [
# (rec {
# systems = [ self.nixosConfigurations.kuraokami.config.nixpkgs.hostPlatform.system ];
# supportedFeatures = self.nixosConfigurations.kuraokami.config.nix.settings.system-features;
# maxJobs = if hostName != config.networking.hostName then 24 else 0;
# speedFactor = 20;
# sshKey = "/home/jopejoe1/.ssh/github";
# sshUser = "jopejoe1";
# hostName = "kuraokami";
# protocol = "ssh-ng";
# })
# (rec {
# systems = [ self.nixosConfigurations.zap.config.nixpkgs.hostPlatform.system ];
# supportedFeatures = self.nixosConfigurations.zap.config.nix.settings.system-features;
# maxJobs = if hostName != config.networking.hostName then 4 else 0;
# speedFactor = 10;
# sshUser = "jopejoe1";
# sshKey = "/home/jopejoe1/.ssh/github";
# hostName = "zap";
# protocol = "ssh-ng";
# })
# ];
# buildMachines = [
# (rec {
# systems = [ self.nixosConfigurations.kuraokami.config.nixpkgs.hostPlatform.system ];
# supportedFeatures = self.nixosConfigurations.kuraokami.config.nix.settings.system-features;
# maxJobs = if hostName != config.networking.hostName then 24 else 0;
# speedFactor = 20;
# sshKey = "/home/jopejoe1/.ssh/github";
# sshUser = "jopejoe1";
# hostName = "kuraokami";
# protocol = "ssh-ng";
# })
# (rec {
# systems = [ self.nixosConfigurations.zap.config.nixpkgs.hostPlatform.system ];
# supportedFeatures = self.nixosConfigurations.zap.config.nix.settings.system-features;
# maxJobs = if hostName != config.networking.hostName then 4 else 0;
# speedFactor = 10;
# sshUser = "jopejoe1";
# sshKey = "/home/jopejoe1/.ssh/github";
# hostName = "zap";
# protocol = "ssh-ng";
# })
# ];
distributedBuilds = true;
package = pkgs.lix;
registry = lib.mkForce ((lib.mapAttrs (_: flake: { inherit flake; })) ((lib.filterAttrs (_: lib.isType "flake")) self.inputs) // {
self.flake = self;
});
registry = lib.mkForce (
(lib.mapAttrs (_: flake: { inherit flake; })) (
(lib.filterAttrs (_: lib.isType "flake")) self.inputs
)
// {
self.flake = self;
}
);
nixPath = lib.mkForce [ "/etc/nix/path" ];
};
nixpkgs = {
config ={
config = {
allowUnfree = true;
nvidia.acceptLicense = true;
};
@ -75,7 +92,10 @@ in {
];
};
environment.etc = lib.mapAttrs' (name: value: { name = "nix/path/${name}"; value.source = value.flake; }) config.nix.registry;
environment.etc = lib.mapAttrs' (name: value: {
name = "nix/path/${name}";
value.source = value.flake;
}) config.nix.registry;
environment.systemPackages = with pkgs; [
deploy-rs
@ -92,9 +112,7 @@ in {
useGlobalPkgs = true;
useUserPackages = true;
backupFileExtension = "backup";
sharedModules = [
self.outputs.homeManagerModules.default
];
sharedModules = [ self.outputs.homeManagerModules.default ];
};
systemd.services.nix-daemon.serviceConfig.LimitNOFILE = lib.mkForce 1048576000;
@ -106,4 +124,3 @@ in {
};
};
}

View file

@ -1,7 +1,9 @@
{ config, lib, ... }:
let cfg = config.jopejoe1.plasma;
in {
let
cfg = config.jopejoe1.plasma;
in
{
options.jopejoe1.plasma = {
enable = lib.mkEnableOption "Enable KDE Plasma";
};
@ -24,9 +26,10 @@ in {
};
};
programs.kdeconnect = { enable = true; };
programs.kdeconnect = {
enable = true;
};
networking.networkmanager.enable = true;
};
}

View file

@ -1,7 +1,14 @@
{ config, lib, pkgs, ... }:
{
config,
lib,
pkgs,
...
}:
let cfg = config.jopejoe1.printing;
in {
let
cfg = config.jopejoe1.printing;
in
{
options.jopejoe1.printing = {
enable = lib.mkEnableOption "Enable Printing";
};
@ -27,4 +34,3 @@ in {
};
};
}

View file

@ -1,7 +1,14 @@
{ config, lib, pkgs, ... }:
{
config,
lib,
pkgs,
...
}:
let cfg = config.jopejoe1.repo-sync;
in {
let
cfg = config.jopejoe1.repo-sync;
in
{
options.jopejoe1.repo-sync = {
enable = lib.mkEnableOption "Enable Repo Sync";
};
@ -30,7 +37,12 @@ in {
git -C /var/lib/repo-sync push gitlab
rm -r /var/lib/repo-sync
'';
path = [ pkgs.openssh pkgs.git pkgs.coreutils pkgs.nix ];
path = [
pkgs.openssh
pkgs.git
pkgs.coreutils
pkgs.nix
];
serviceConfig = {
Type = "oneshot";
User = "root";
@ -38,4 +50,3 @@ in {
};
};
}

View file

@ -1,8 +1,18 @@
{ config, lib, pkgs, self, ... }:
{
config,
lib,
pkgs,
self,
...
}:
let cfg = config.jopejoe1.ssh;
in {
options.jopejoe1.ssh = { enable = lib.mkEnableOption "Enable ssh"; };
let
cfg = config.jopejoe1.ssh;
in
{
options.jopejoe1.ssh = {
enable = lib.mkEnableOption "Enable ssh";
};
config = lib.mkIf cfg.enable {
services.openssh = {
@ -15,4 +25,3 @@ in {
};
};
}

View file

@ -1,8 +1,17 @@
{ pkgs, config, lib, ... }:
{
pkgs,
config,
lib,
...
}:
let cfg = config.jopejoe1.steam;
in {
options.jopejoe1.steam = { enable = lib.mkEnableOption "Enable Steam"; };
let
cfg = config.jopejoe1.steam;
in
{
options.jopejoe1.steam = {
enable = lib.mkEnableOption "Enable Steam";
};
config = lib.mkIf cfg.enable {
hardware.steam-hardware.enable = true;
@ -14,10 +23,7 @@ in {
localNetworkGameTransfers.openFirewall = true;
gamescopeSession.enable = true;
extest.enable = true;
extraCompatPackages = with pkgs; [
proton-ge-bin
];
extraCompatPackages = with pkgs; [ proton-ge-bin ];
};
};
}

View file

@ -1,7 +1,9 @@
{ config, lib, ... }:
let cfg = config.jopejoe1.sway;
in {
let
cfg = config.jopejoe1.sway;
in
{
options.jopejoe1.sway = {
enable = lib.mkEnableOption "Enable Sway";
};
@ -12,4 +14,3 @@ in {
};
};
}

View file

@ -1,5 +1,8 @@
{ ... }:
{
imports = [ ./root ./jopejoe1 ];
imports = [
./root
./jopejoe1
];
}

View file

@ -1,7 +1,14 @@
{ config, lib, pkgs, ... }:
{
config,
lib,
pkgs,
...
}:
let cfg = config.jopejoe1.user.jopejoe1;
in {
let
cfg = config.jopejoe1.user.jopejoe1;
in
{
options.jopejoe1.user.jopejoe1 = {
enable = lib.mkEnableOption "Enable jopejoe1 user";
};
@ -12,7 +19,13 @@ in {
shell = pkgs.nushell;
description = "Johannes Jöns";
hashedPassword = "$2b$05$Uk84TY/RHlH8DIigUlFYjeorjTlCMEY9wN2pAcw5BLaPoc7dKiSsC";
extraGroups = [ "wheel" "networkmanager" "pipewire" "audio" "adbusers" ];
extraGroups = [
"wheel"
"networkmanager"
"pipewire"
"audio"
"adbusers"
];
uid = 1000;
openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIB8oyMpS2hK3gQXyHIIVS6oilgMpemLmfhKKJ6RBMwUh johannes@joens.email"
@ -21,8 +34,9 @@ in {
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIFZDUoC+1lNR2JTY1Q+vhXpuLmKMdVl2OMFLVbQ3cGkw jopejoe1@kuraokami"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKm2igbJ+Ke+dJO3r7wp5ZTreHqC39Sjctca119Bl2yc jopejoe1@zap"
];
packages = with pkgs;
[]
packages =
with pkgs;
[ ]
++ lib.optionals config.jopejoe1.gui.enable [
libsForQt5.kate
libsForQt5.ark
@ -35,10 +49,13 @@ in {
catppuccin-kde
#catppuccin-gtk
tela-icon-theme
((discord.overrideAttrs (old: {
desktopItem = old.desktopItem.override
(old: { exec = old.exec + " --disable-gpu-sandbox"; });
})).override {
(
(discord.overrideAttrs (old: {
desktopItem = old.desktopItem.override (old: {
exec = old.exec + " --disable-gpu-sandbox";
});
})).override
{
withOpenASAR = true;
withVencord = true;
withTTS = true;

View file

@ -1,8 +1,12 @@
{ config, lib, ... }:
let cfg = config.jopejoe1.user.root;
in {
options.jopejoe1.user.root = { enable = lib.mkEnableOption "Enable root user"; };
let
cfg = config.jopejoe1.user.root;
in
{
options.jopejoe1.user.root = {
enable = lib.mkEnableOption "Enable root user";
};
config = lib.mkIf cfg.enable {
users.users.root = {
@ -34,4 +38,3 @@ in {
};
};
}

View file

@ -1,16 +1,24 @@
{ config, lib, pkgs, ... }:
{
config,
lib,
pkgs,
...
}:
let cfg = config.jopejoe1.zerotierone;
in {
let
cfg = config.jopejoe1.zerotierone;
in
{
options.jopejoe1.zerotierone = {
enable = lib.mkEnableOption "Enable zerotierone";
};
config = lib.mkIf cfg.enable {
services.zerotierone.enable = true;
services.zerotierone.joinNetworks = [ "9e1948db638e9f93" ] ++ lib.optional (config.networking.hostName == "kuraokami") "7c31a21e86f9a75c";
services.zerotierone.joinNetworks = [
"9e1948db638e9f93"
] ++ lib.optional (config.networking.hostName == "kuraokami") "7c31a21e86f9a75c";
services.zerotierone.port = 9993;
environment.systemPackages = with pkgs; lib.optional config.jopejoe1.gui.enable moonlight-qt;
};
}

View file

@ -1,20 +1,22 @@
{ inputs, pkgs, system }:
{
inputs,
pkgs,
system,
}:
{
tela-icon-theme-git = pkgs.tela-icon-theme.overrideAttrs {
src = inputs.tela-icon-theme;
};
tela-icon-theme-git = pkgs.tela-icon-theme.overrideAttrs { src = inputs.tela-icon-theme; };
libadwaita-follow-theme = pkgs.libadwaita.overrideAttrs (old: {
patches = (old.patches or [ ]) ++ [ ./adwaita-theming-support.patch ];
doCheck = false;
});
prismlauncher-withExtraStuff = inputs.prismlauncher.packages.${system}.prismlauncher.overrideAttrs (old: {
patches = (old.patches or [ ]) ++ [
./prism-ftb.patch
];
});
prismlauncher-withExtraStuff =
inputs.prismlauncher.packages.${system}.prismlauncher.overrideAttrs
(old: {
patches = (old.patches or [ ]) ++ [ ./prism-ftb.patch ];
});
nixos-anywhere = inputs.nixos-anywhere.packages.${system}.nixos-anywhere;
@ -26,9 +28,7 @@
url = "https://mangabooth.com/";
hash = "sha256-JxfjZLoN6I9twAQMT60Q27CgJg22G7zEU5GDra9rROs=";
};
nativeBuildInputs = [
pkgs.unzip
];
nativeBuildInputs = [ pkgs.unzip ];
installPhase = "mkdir -p $out; cp -R * $out/";
};
madara-child = pkgs.stdenv.mkDerivation rec {
@ -39,9 +39,7 @@
url = "https://mangabooth.com/";
hash = "sha256-h9w2TmX1nXaoP27b9DQ1jf6z1hTS5+BWtlz+Fprk5dQ=";
};
nativeBuildInputs = [
pkgs.unzip
];
nativeBuildInputs = [ pkgs.unzip ];
unpackPhase = ''
mkdir -p $out
unzip $src "madara-child/*" -d $out
@ -56,9 +54,7 @@
url = "https://mangabooth.com/";
hash = "sha256-r22hGCDlVeYTOFlhfKoc3r4TtpZExJ2E2QP9ssRoJco=";
};
nativeBuildInputs = [
pkgs.unzip
];
nativeBuildInputs = [ pkgs.unzip ];
installPhase = "mkdir -p $out; cp -R * $out/";
};
madara-shortcodes = pkgs.stdenv.mkDerivation rec {
@ -69,9 +65,7 @@
url = "https://mangabooth.com/";
hash = "sha256-IW7C5DTzvt3ROFpfB21LY2wmdR45lNj9c8/THHCi6eY=";
};
nativeBuildInputs = [
pkgs.unzip
];
nativeBuildInputs = [ pkgs.unzip ];
unpackPhase = ''
mkdir -p $out
unzip $src "madara-shortcodes/*" -d $out
@ -86,9 +80,7 @@
url = "https://mangabooth.com/";
hash = "sha256-9u+MGdOarNdLtARWiJpw/hsMR9X8r0h5qugGir+amUI=";
};
nativeBuildInputs = [
pkgs.unzip
];
nativeBuildInputs = [ pkgs.unzip ];
installPhase = "mkdir -p $out; cp -R * $out/";
};
option-tree = pkgs.stdenv.mkDerivation rec {
@ -98,9 +90,7 @@
url = "https://downloads.wordpress.org/plugin/option-tree.zip";
hash = "sha256-+dPt8qJ4rkmSKrIXX5IiWO4zkFkR+Uapjlbx1g7KzKs=";
};
nativeBuildInputs = [
pkgs.unzip
];
nativeBuildInputs = [ pkgs.unzip ];
installPhase = "mkdir -p $out; cp -R * $out/";
};
widget-logic = pkgs.stdenv.mkDerivation rec {
@ -110,11 +100,9 @@
url = "https://downloads.wordpress.org/plugin/widget-logic.zip";
hash = "sha256-J2NOth3q+IaPVhFT97arsNfjUPyTZF4Vvin1Cb+xnKw=";
};
nativeBuildInputs = [
pkgs.unzip
];
nativeBuildInputs = [ pkgs.unzip ];
installPhase = "mkdir -p $out; cp -R * $out/";
};
kde-hdr-fix = pkgs.callPackage ./kde-hdr.nix {};
kde-wallpaper = pkgs.callPackage ./kde-wallpaper.nix {};
kde-hdr-fix = pkgs.callPackage ./kde-hdr.nix { };
kde-wallpaper = pkgs.callPackage ./kde-wallpaper.nix { };
}

View file

@ -2,7 +2,7 @@
lib,
stdenv,
meson,
# ninja,
# ninja,
fetchFromGitHub,
vulkan-headers,
libX11,
@ -22,10 +22,13 @@ stdenv.mkDerivation {
nativeBuildInputs = [
meson
# ninja
# ninja
];
buildInputs = [ vulkan-headers libX11 ];
buildInputs = [
vulkan-headers
libX11
];
strictDeps = true;

View file

@ -23,9 +23,7 @@ stdenv.mkDerivation {
kdePackages.wrapQtAppsHook
];
buildInputs = [
kdePackages.qtbase
];
buildInputs = [ kdePackages.qtbase ];
cmakeFlags = [
"-DECM_DIR=${kdePackages.extra-cmake-modules}/share/ECM/cmake"

View file

@ -1,4 +1,9 @@
{ pkgs, config, nixos-hardware, ... }:
{
pkgs,
config,
nixos-hardware,
...
}:
{
imports = [
@ -10,7 +15,9 @@
];
jopejoe1 = {
audio = { enable = true; };
audio = {
enable = true;
};
bluetooth.enable = true;
local.enable = true;
nix.enable = true;
@ -60,9 +67,7 @@
settings = {
server = {
systemTrayEnabled = true;
extensionRepos = [
"https://raw.githubusercontent.com/keiyoushi/extensions/repo/index.min.json"
];
extensionRepos = [ "https://raw.githubusercontent.com/keiyoushi/extensions/repo/index.min.json" ];
webUIEnabled = true;
initialOpenInBrowserEnabled = true;
webUIInterface = "browser";
@ -103,6 +108,10 @@
networking.hosts = {
"192.168.88.251" = [ "wiki.it3" ];
"192.168.88.252" = [ "pi400" ];
"127.0.0.1" = [ "local" "rss.local" "manga.local" ];
"127.0.0.1" = [
"local"
"rss.local"
"manga.local"
];
};
}

View file

@ -1,4 +1,9 @@
{ config, lib, modulesPath, ... }:
{
config,
lib,
modulesPath,
...
}:
{
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
@ -22,11 +27,9 @@
fsType = "ext4";
};
swapDevices =
[{ device = "/dev/disk/by-uuid/8569ee66-b939-4ce8-a94a-dca7df5e301b"; }];
swapDevices = [ { device = "/dev/disk/by-uuid/8569ee66-b939-4ce8-a94a-dca7df5e301b"; } ];
networking.useDHCP = lib.mkDefault true;
hardware.cpu.intel.updateMicrocode =
lib.mkDefault config.hardware.enableRedistributableFirmware;
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

View file

@ -1,22 +1,38 @@
{ self, nixpkgs, inputs }:
{
self,
nixpkgs,
inputs,
}:
let
mkSystem = systemConfig: name: nixpkgs.lib.nixosSystem rec {
system = builtins.replaceStrings [ "-unknown-" "-gnu" ] [ "-" "" ] systemConfig;
specialArgs = inputs;
modules = [
./${name}
self.outputs.nixosModules.default
{
system.stateVersion = "24.05";
nixpkgs.hostPlatform = {
system = system;
config = systemConfig;
};
networking.hostName = name;
}
];
};
mkSystem =
systemConfig: name:
nixpkgs.lib.nixosSystem rec {
system =
builtins.replaceStrings
[
"-unknown-"
"-gnu"
]
[
"-"
""
]
systemConfig;
specialArgs = inputs;
modules = [
./${name}
self.outputs.nixosModules.default
{
system.stateVersion = "24.05";
nixpkgs.hostPlatform = {
system = system;
config = systemConfig;
};
networking.hostName = name;
}
];
};
in
{
kuraokami = mkSystem "x86_64-unknown-linux-gnu" "kuraokami";

View file

@ -3,7 +3,9 @@
{
jopejoe1 = {
audio = { enable = true; };
audio = {
enable = true;
};
bluetooth.enable = true;
local.enable = true;
nix.enable = true;
@ -14,7 +16,6 @@
boot.systemd.enable = true;
};
environment.systemPackages = with pkgs; [ moonlight-qt ];
time.timeZone = "Europe/Berlin";

View file

@ -1,4 +1,9 @@
{ config, lib, modulesPath, ... }:
{
config,
lib,
modulesPath,
...
}:
{
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
@ -22,11 +27,9 @@
fsType = "ext4";
};
swapDevices =
[{ device = "/dev/disk/by-uuid/8569ee66-b939-4ce8-a94a-dca7df5e301b"; }];
swapDevices = [ { device = "/dev/disk/by-uuid/8569ee66-b939-4ce8-a94a-dca7df5e301b"; } ];
networking.useDHCP = lib.mkDefault true;
hardware.cpu.intel.updateMicrocode =
lib.mkDefault config.hardware.enableRedistributableFirmware;
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

View file

@ -28,14 +28,20 @@
};
systemd.services.dns-rfc2136-conf = {
requiredBy = [ "acme-net0loggy.net.service" "bind.service" ];
before = [ "acme-net0loggy.net.service" "bind.service" ];
requiredBy = [
"acme-net0loggy.net.service"
"bind.service"
];
before = [
"acme-net0loggy.net.service"
"bind.service"
];
unitConfig = {
ConditionPathExists = "!/var/lib/secrets/dnskeys.conf";
};
serviceConfig = {
Type = "oneshot";
UMask = 0077;
UMask = 77;
};
path = [ pkgs.bind ];
script = ''

View file

@ -1,4 +1,10 @@
{ config, pkgs, lib, self, ... }:
{
config,
pkgs,
lib,
self,
...
}:
{
@ -24,7 +30,10 @@
ssh.enable = true;
};
boot.initrd.availableKernelModules = [ "ahci" "nvme" ];
boot.initrd.availableKernelModules = [
"ahci"
"nvme"
];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = [ ];

View file

@ -1,17 +1,54 @@
{ config, pkgs, lib, ...}:
{
config,
pkgs,
lib,
...
}:
{
mailserver = {
enable = true;
fqdn = "mail.missing.ninja";
domains = [ "missing.ninja" "joens.zone" "joens.website" "joens.site" "joens.online" "joens.link" "joens.international" "joens.family" "joens.digital" "joens.blog" "net0loggy.net" "clan-war.net" "net0loggy.de" "dtg-c.de" "joens.email" ];
domains = [
"missing.ninja"
"joens.zone"
"joens.website"
"joens.site"
"joens.online"
"joens.link"
"joens.international"
"joens.family"
"joens.digital"
"joens.blog"
"net0loggy.net"
"clan-war.net"
"net0loggy.de"
"dtg-c.de"
"joens.email"
];
# A list of all login accounts. To create the password hashes, use
# nix-shell -p mkpasswd --run 'mkpasswd -sm bcrypt'
loginAccounts = {
"jopejoe1@missing.ninja" = {
hashedPassword = "$2b$05$ZZk/X.gQqjRc08ej9XTuaO0aVnWjPGWUqo/xYGxHGsMEyDL.Hr8AS";
aliases = [ "@missing.ninja" "@joens.zone" "@joens.website" "@joens.site" "@joens.online" "@joens.link" "@joens.international" "@joens.family" "@joens.digital" "@joens.blog" "@net0loggy.net" "@clan-war.net" "@net0loggy.de" "@dtg-c.de" "@joens.email" ];
aliases = [
"@missing.ninja"
"@joens.zone"
"@joens.website"
"@joens.site"
"@joens.online"
"@joens.link"
"@joens.international"
"@joens.family"
"@joens.digital"
"@joens.blog"
"@net0loggy.net"
"@clan-war.net"
"@net0loggy.de"
"@dtg-c.de"
"@joens.email"
];
};
};
@ -30,18 +67,21 @@
};
services.roundcube = {
enable = true;
# this is the url of the vhost, not necessarily the same as the fqdn of
# the mailserver
hostName = "webmail.missing.ninja";
extraConfig = ''
# starttls needed for authentication, so the fqdn required to match
# the certificate
$config['smtp_server'] = "tls://${config.mailserver.fqdn}";
$config['smtp_user'] = "%u";
$config['smtp_pass'] = "%p";
'';
enable = true;
# this is the url of the vhost, not necessarily the same as the fqdn of
# the mailserver
hostName = "webmail.missing.ninja";
extraConfig = ''
# starttls needed for authentication, so the fqdn required to match
# the certificate
$config['smtp_server'] = "tls://${config.mailserver.fqdn}";
$config['smtp_user'] = "%u";
$config['smtp_pass'] = "%p";
'';
};
networking.firewall.allowedTCPPorts = [ 80 443 ];
networking.firewall.allowedTCPPorts = [
80
443
];
}

View file

@ -1,4 +1,4 @@
{ config, pkgs, ...}:
{ config, pkgs, ... }:
let
fqdn = "matrix.missing.ninja";
@ -54,9 +54,7 @@ in
server_name = "missing.ninja";
registration_shared_secret = "";
public_baseurl = baseUrl;
app_service_config_files = [
"/var/lib/matrix-synapse/whatsapp-registration.yaml"
];
app_service_config_files = [ "/var/lib/matrix-synapse/whatsapp-registration.yaml" ];
listeners = [
{
port = 8448;
@ -66,7 +64,10 @@ in
x_forwarded = true;
resources = [
{
names = [ "client" "federation" ];
names = [
"client"
"federation"
];
compress = true;
}
];

View file

@ -1,4 +1,9 @@
{config, pkgs, self, ...}:
{
config,
pkgs,
self,
...
}:
{
services.nginx = {
@ -9,7 +14,21 @@
recommendedProxySettings = true;
virtualHosts = {
"missing.ninja" = {
serverAliases = [ "joens.zone" "joens.website" "joens.site" "joens.online" "joens.link" "joens.international" "joens.family" "joens.digital" "joens.blog" "net0loggy.net" "clan-war.net" "net0loggy.de" "dtg-c.de" ];
serverAliases = [
"joens.zone"
"joens.website"
"joens.site"
"joens.online"
"joens.link"
"joens.international"
"joens.family"
"joens.digital"
"joens.blog"
"net0loggy.net"
"clan-war.net"
"net0loggy.de"
"dtg-c.de"
];
enableACME = true;
forceSSL = true;
};
@ -23,9 +42,7 @@
locations."/socket.io/" = {
proxyPass = "http://localhost:3333";
proxyWebsockets = true;
extraConfig =
"proxy_ssl_server_name on;"
;
extraConfig = "proxy_ssl_server_name on;";
};
};
"test.missing.ninja" = {
@ -57,24 +74,25 @@
max_input_time = 300
'';
services.wordpress.sites."test.missing.ninja" = with self.packages.${config.nixpkgs.hostPlatform.system}; {
themes = [
madara
madara-child
pkgs.wordpressPackages.themes.twentytwentythree
];
plugins = [
madara-core
madara-shortcodes
option-tree
option-tree-lean
widget-logic
];
settings = {
FORCE_SSL_ADMIN = true;
services.wordpress.sites."test.missing.ninja" =
with self.packages.${config.nixpkgs.hostPlatform.system}; {
themes = [
madara
madara-child
pkgs.wordpressPackages.themes.twentytwentythree
];
plugins = [
madara-core
madara-shortcodes
option-tree
option-tree-lean
widget-logic
];
settings = {
FORCE_SSL_ADMIN = true;
};
extraConfig = ''
$_SERVER['HTTPS']='on';
'';
};
extraConfig = ''
$_SERVER['HTTPS']='on';
'';
};
}

View file

@ -1,16 +1,22 @@
{ config, pkgs, lib, ... }:
{
config,
pkgs,
lib,
...
}:
with lib;
let
mailAccounts = config.mailserver.loginAccounts;
htpasswd = pkgs.writeText "radicale.users" (concatStrings
(flip mapAttrsToList mailAccounts (mail: user:
mail + ":" + user.hashedPassword + "\n"
))
htpasswd = pkgs.writeText "radicale.users" (
concatStrings (
flip mapAttrsToList mailAccounts (mail: user: mail + ":" + user.hashedPassword + "\n")
)
);
in {
in
{
services.radicale = {
enable = true;
settings = {

View file

@ -1,4 +1,9 @@
{ config, pkgs, lib, ... }:
{
config,
pkgs,
lib,
...
}:
{
jopejoe1 = {
@ -10,11 +15,10 @@
ssh.enable = true;
};
time.timeZone = "Europe/Berlin";
services.openssh.settings.PermitRootLogin = lib.mkForce "yes";
boot.loader = {
efi = {
canTouchEfiVariables = false;

View file

@ -1,4 +1,11 @@
{ config, pkgs, lib, nixos-hardware, self, ... }:
{
config,
pkgs,
lib,
nixos-hardware,
self,
...
}:
{
imports = [
@ -105,25 +112,25 @@
environment.systemPackages = with pkgs; [
localPkgs.prismlauncher-withExtraStuff
mixxx
(picard.overrideAttrs{
dontUseSetuptoolsCheck = true;
})
(picard.overrideAttrs { dontUseSetuptoolsCheck = true; })
goverlay
(strawberry-qt6.overrideAttrs (finalAttrs: previousAttrs: {
version = "1.1.0-rc3";
src = fetchFromGitHub {
owner = "strawberrymusicplayer";
repo = "strawberry";
rev = "1.1.0-rc3";
hash = "sha256-4LhFxCi0ixMAjVaNVrQrLc0Vf1Z2dhnw6DTfTqtpiC4=";
};
buildInputs = previousAttrs.buildInputs ++ [
kdsingleapplication
gst_all_1.gst-plugins-rs
kdePackages.qtsvg
kdePackages.qtimageformats
];
}))
(strawberry-qt6.overrideAttrs (
finalAttrs: previousAttrs: {
version = "1.1.0-rc3";
src = fetchFromGitHub {
owner = "strawberrymusicplayer";
repo = "strawberry";
rev = "1.1.0-rc3";
hash = "sha256-4LhFxCi0ixMAjVaNVrQrLc0Vf1Z2dhnw6DTfTqtpiC4=";
};
buildInputs = previousAttrs.buildInputs ++ [
kdsingleapplication
gst_all_1.gst-plugins-rs
kdePackages.qtsvg
kdePackages.qtimageformats
];
}
))
libreoffice-qt
jitsi-meet-electron
thunderbird
@ -139,9 +146,7 @@
gamemode.enable = true;
appimage = {
enable = true;
package = pkgs.appimage-run.override {
extraPkgs = pkgs: [ pkgs.brotli ];
};
package = pkgs.appimage-run.override { extraPkgs = pkgs: [ pkgs.brotli ]; };
};
gnupg.agent = {
enable = true;
@ -150,13 +155,28 @@
};
};
nix.settings.system-features = [ "gccarch-alderlake" "benchmark" "big-parallel" "kvm" "nixos-test" ]
++ map (x: "gccarch-${x}") (lib.systems.architectures.inferiors.alderlake or [ ]);
nix.settings.system-features = [
"gccarch-alderlake"
"benchmark"
"big-parallel"
"kvm"
"nixos-test"
] ++ map (x: "gccarch-${x}") (lib.systems.architectures.inferiors.alderlake or [ ]);
boot.binfmt.emulatedSystems = [ "riscv64-linux" "aarch64-linux" ];
boot.binfmt.emulatedSystems = [
"riscv64-linux"
"aarch64-linux"
];
programs.nix-ld = {
enable = true;
libraries = with pkgs; [ libz xz xorg.libX11 freetype zstd dbus ];
libraries = with pkgs; [
libz
xz
xorg.libX11
freetype
zstd
dbus
];
};
}

View file

@ -1,7 +1,12 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, modulesPath, ... }:
{
config,
lib,
modulesPath,
...
}:
{
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
@ -20,9 +25,20 @@
};
};
boot.initrd.availableKernelModules = [ "vmd" "xhci_pci" "ahci" "nvme" "usbhid" "sd_mod" "sr_mod" ];
boot.initrd.availableKernelModules = [
"vmd"
"xhci_pci"
"ahci"
"nvme"
"usbhid"
"sd_mod"
"sr_mod"
];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" "nouveau" ];
boot.kernelModules = [
"kvm-intel"
"nouveau"
];
boot.extraModulePackages = [ ];
fileSystems = {
@ -38,7 +54,10 @@
"/media/gaming" = {
device = "/dev/disk/by-uuid/4038F97238F966F6";
fsType = "ntfs";
options = [ "rw" "uid=1000" ];
options = [
"rw"
"uid=1000"
];
};
};

View file

@ -1,4 +1,11 @@
{ config, pkgs, lib, nixos-hardware, self, ... }:
{
config,
pkgs,
lib,
nixos-hardware,
self,
...
}:
{
imports = [
@ -73,9 +80,17 @@
};
};
nix.settings.system-features = [ "benchmark" "big-parallel" "kvm" "nixos-test" ];
nix.settings.system-features = [
"benchmark"
"big-parallel"
"kvm"
"nixos-test"
];
boot.binfmt.emulatedSystems = [ "riscv64-linux" "aarch64-linux" ];
boot.binfmt.emulatedSystems = [
"riscv64-linux"
"aarch64-linux"
];
boot.plymouth = {
enable = true;
};

View file

@ -1,34 +1,49 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, modulesPath, ... }:
{
config,
lib,
modulesPath,
...
}:
{
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "thunderbolt" "usbhid" "usb_storage" "sd_mod" ];
boot.initrd.availableKernelModules = [
"nvme"
"xhci_pci"
"thunderbolt"
"usbhid"
"usb_storage"
"sd_mod"
];
boot.initrd.kernelModules = [ "amdgpu" ];
boot.kernelModules = [ ];
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/6842a9de-c5fd-4648-b3b8-f76e56633825";
fsType = "ext4";
};
fileSystems."/" = {
device = "/dev/disk/by-uuid/6842a9de-c5fd-4648-b3b8-f76e56633825";
fsType = "ext4";
};
boot.initrd.luks.devices."luks-eaed8652-a306-4434-a187-71e6fcb13e71".device = "/dev/disk/by-uuid/eaed8652-a306-4434-a187-71e6fcb13e71";
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/7C5A-EE45";
fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ];
};
fileSystems."/boot" = {
device = "/dev/disk/by-uuid/7C5A-EE45";
fsType = "vfat";
options = [
"fmask=0022"
"dmask=0022"
];
};
fileSystems."/home/jopejoe1/Public/games" =
{ device = "/dev/sda";
fsType = "bcachefs";
options = [ "compression=zstd" ];
};
fileSystems."/home/jopejoe1/Public/games" = {
device = "/dev/sda";
fsType = "bcachefs";
options = [ "compression=zstd" ];
};
swapDevices = [ ];

View file

@ -1,4 +1,9 @@
{ modulesPath, lib, nixos-hardware, ... }:
{
modulesPath,
lib,
nixos-hardware,
...
}:
{
imports = [
@ -7,8 +12,12 @@
];
boot = {
initrd = { availableKernelModules = [ "xhci_pci" ]; };
loader = { generic-extlinux-compatible.enable = true; };
initrd = {
availableKernelModules = [ "xhci_pci" ];
};
loader = {
generic-extlinux-compatible.enable = true;
};
};
hardware.raspberry-pi."4".fkms-3d.enable = true;

View file

@ -1,4 +1,10 @@
{ modulesPath, lib, nixos-hardware, pkgs, ... }:
{
modulesPath,
lib,
nixos-hardware,
pkgs,
...
}:
{
imports = [
@ -7,11 +13,23 @@
];
boot = {
initrd = { availableKernelModules = [ "xhci_pci" ]; };
initrd = {
availableKernelModules = [ "xhci_pci" ];
};
kernelPackages = pkgs.linuxPackages_latest;
};
boot.supportedFilesystems = lib.mkForce [ "btrfs" "cifs" "f2fs" "jfs" "ntfs" "reiserfs" "vfat" "xfs" "bchachefs" ];
boot.supportedFilesystems = lib.mkForce [
"btrfs"
"cifs"
"f2fs"
"jfs"
"ntfs"
"reiserfs"
"vfat"
"xfs"
"bchachefs"
];
#hardware.raspberry-pi."4".fkms-3d.enable = true;

View file

@ -1,4 +1,9 @@
{ modulesPath, lib, nixos-hardware, ... }:
{
modulesPath,
lib,
nixos-hardware,
...
}:
{
imports = [
@ -7,8 +12,12 @@
];
boot = {
initrd = { availableKernelModules = [ "xhci_pci" ]; };
loader = { generic-extlinux-compatible.enable = true; };
initrd = {
availableKernelModules = [ "xhci_pci" ];
};
loader = {
generic-extlinux-compatible.enable = true;
};
};
fileSystems."/" = {

View file

@ -1,4 +1,9 @@
{ config, pkgs, nixos-hardware, ... }:
{
config,
pkgs,
nixos-hardware,
...
}:
{
imports = [
@ -43,14 +48,18 @@
enable = true;
keyMap = "us";
};
services.xserver = { layout = "us"; };
services.xserver = {
layout = "us";
};
boot = {
supportedFilesystems = [ "ntfs" "btrfs" ];
supportedFilesystems = [
"ntfs"
"btrfs"
];
loader = {
grub.enable = false;
generic-extlinux-compatible.enable = true;
};
};
}

View file

@ -19,10 +19,12 @@
fsType = "vfat";
};
swapDevices = [{
device = "/var/lib/swapfile";
size = (4 * 1024) + (2 * 1024);
}];
swapDevices = [
{
device = "/var/lib/swapfile";
size = (4 * 1024) + (2 * 1024);
}
];
networking.wireless.enable = true;
@ -37,4 +39,3 @@
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
hardware.enableRedistributableFirmware = true;
}

View file

@ -1,4 +1,11 @@
{ config, pkgs, lib, modulesPath, self, ... }:
{
config,
pkgs,
lib,
modulesPath,
self,
...
}:
{
jopejoe1 = {
@ -13,16 +20,22 @@
gui.enable = false;
};
imports =
[
(modulesPath + "/profiles/qemu-guest.nix")
self.inputs.srvos.nixosModules.server
self.inputs.srvos.nixosModules.mixins-cloud-init
self.inputs.srvos.nixosModules.mixins-nginx
./wp-test.nix
];
imports = [
(modulesPath + "/profiles/qemu-guest.nix")
self.inputs.srvos.nixosModules.server
self.inputs.srvos.nixosModules.mixins-cloud-init
self.inputs.srvos.nixosModules.mixins-nginx
./wp-test.nix
];
boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ];
boot.initrd.availableKernelModules = [
"ata_piix"
"uhci_hcd"
"virtio_pci"
"virtio_scsi"
"sd_mod"
"sr_mod"
];
networking.useDHCP = false;
@ -44,10 +57,10 @@
#"db.missing.ninja" = {
# enableACME = true;
# forceSSL = true;
# locations."/" = {
# locations."/" = {
# proxyPass = "http://134.255.219.135:8000/";
# };
# };
# };
# };
};
services.nginx.enable = true;
@ -70,8 +83,16 @@
networking.firewall = {
enable = true;
allowedTCPPorts = [ 80 443 8000 ];
allowedUDPPorts = [ 80 443 8000 ];
allowedTCPPorts = [
80
443
8000
];
allowedUDPPorts = [
80
443
8000
];
};
users.users.fp = {
@ -88,7 +109,10 @@
services.openssh.settings.PermitRootLogin = lib.mkForce "yes";
services.openssh.ports = [ 8081 22 ];
services.openssh.ports = [
8081
22
];
services.surrealdb.enable = false;
services.surrealdb.host = "134.255.219.135";

View file

@ -1,4 +1,9 @@
{pkgs, config, lib, ...}:
{
pkgs,
config,
lib,
...
}:
{
services.nginx = {
@ -58,7 +63,7 @@
};
};
users.users.www-wordpress= {
users.users.www-wordpress = {
isNormalUser = true;
group = "www-wordpress";
packages = with pkgs; [
@ -96,37 +101,48 @@
# ensurePermissions = { "www-wordpress.*" = "ALL PRIVILEGES"; };
# }
#];
};
};
systemd.services =
let
secretsVars = [ "AUTH_KEY" "SECURE_AUTH_KEY" "LOGGED_IN_KEY" "NONCE_KEY" "AUTH_SALT" "SECURE_AUTH_SALT" "LOGGED_IN_SALT" "NONCE_SALT" ];
secretsScript = hostStateDir: ''
# The match in this line is not a typo, see https://github.com/NixOS/nixpkgs/pull/124839
grep -q "LOOGGED_IN_KEY" "${hostStateDir}/secret-keys.php" && rm "${hostStateDir}/secret-keys.php"
if ! test -e "${hostStateDir}/secret-keys.php"; then
umask 0177
echo "<?php" >> "${hostStateDir}/secret-keys.php"
${lib.concatMapStringsSep "\n" (var: ''
echo "define('${var}', '`tr -dc a-zA-Z0-9 </dev/urandom | head -c 64`');" >> "${hostStateDir}/secret-keys.php"
'') secretsVars}
echo "?>" >> "${hostStateDir}/secret-keys.php"
chmod 440 "${hostStateDir}/secret-keys.php"
fi
'';
in
{
"wordpress-init" = {
wantedBy = [ "multi-user.target" ];
before = [ "phpfpm-wordpress.service" ];
after = [ "mysql.service" ];
script = secretsScript "/var/www/wordpress/";
systemd.services =
let
secretsVars = [
"AUTH_KEY"
"SECURE_AUTH_KEY"
"LOGGED_IN_KEY"
"NONCE_KEY"
"AUTH_SALT"
"SECURE_AUTH_SALT"
"LOGGED_IN_SALT"
"NONCE_SALT"
];
secretsScript = hostStateDir: ''
# The match in this line is not a typo, see https://github.com/NixOS/nixpkgs/pull/124839
grep -q "LOOGGED_IN_KEY" "${hostStateDir}/secret-keys.php" && rm "${hostStateDir}/secret-keys.php"
if ! test -e "${hostStateDir}/secret-keys.php"; then
umask 0177
echo "<?php" >> "${hostStateDir}/secret-keys.php"
${
lib.concatMapStringsSep "\n" (var: ''
echo "define('${var}', '`tr -dc a-zA-Z0-9 </dev/urandom | head -c 64`');" >> "${hostStateDir}/secret-keys.php"
'') secretsVars
}
echo "?>" >> "${hostStateDir}/secret-keys.php"
chmod 440 "${hostStateDir}/secret-keys.php"
fi
'';
in
{
"wordpress-init" = {
wantedBy = [ "multi-user.target" ];
before = [ "phpfpm-wordpress.service" ];
after = [ "mysql.service" ];
script = secretsScript "/var/www/wordpress/";
serviceConfig = {
Type = "oneshot";
User = "www-wordpress";
Group = "nginx";
serviceConfig = {
Type = "oneshot";
User = "www-wordpress";
Group = "nginx";
};
};
};
};
}

View file

@ -1,7 +1,5 @@
{ self, ... }:
{
imports = [
./modules
];
imports = [ ./modules ];
}

View file

@ -1,6 +1,5 @@
{ self, ... }:
{
imports = [
];
imports = [ ];
}

View file

@ -1,6 +1,5 @@
{ self, ... }:
{
imports = [
];
imports = [ ];
}