1
0
mirror of https://git.oat.zone/dark-firepit/dotfiles synced 2024-11-26 06:08:48 +01:00

some changes?? idfk

This commit is contained in:
Jill "oatmealine" Monoids 2023-03-19 16:30:26 +01:00
parent a5450f1aaa
commit 8f7b533c01
4 changed files with 85 additions and 4 deletions

@ -80,6 +80,12 @@ in {
domain = "nitter.oat.zone"; domain = "nitter.oat.zone";
}; };
libreddit = {
enable = true;
domain = "libreddit.oat.zone";
port = 1950;
};
#watch-party = { #watch-party = {
# enable = true; # enable = true;
# port = 1984; # port = 1984;
@ -116,6 +122,10 @@ in {
locations."/f/".extraConfig = '' locations."/f/".extraConfig = ''
add_header Access-Control-Allow-Origin "*"; add_header Access-Control-Allow-Origin "*";
''; '';
extraConfig = ''
error_page 404 /404.html;
error_page 403 /403.html;
'';
}; };
# todo: move to flake # todo: move to flake
"gdpstest.oat.zone" = { "gdpstest.oat.zone" = {
@ -156,6 +166,14 @@ in {
} }
''; '';
}; };
"libreddit.oat.zone" = {
locations."/".extraConfig = ''
if ($http_user_agent = 'Mozilla/5.0 (compatible; Discordbot/2.0; +https://discordapp.com)') {
return 302 $scheme://proxy.knotty.dev$request_uri;
}
'';
};
#"git.oat.zone" = { #"git.oat.zone" = {
# forceSSL = true; # forceSSL = true;

17
modules/editors/helix.nix Normal file

@ -0,0 +1,17 @@
{ pkgs, lib, config, options, ... }:
with lib;
let
cfg = config.modules.editors.helix;
in {
options = {
enable = mkOption {
type = types.bool;
default = false;
};
};
#config = mkIf cfg.enable {
#
#};
}

@ -1,9 +1,13 @@
{ config, pkgs, options, lib, ... }: { config, pkgs, options, lib, inputs, ... }:
with lib; with lib;
let let
cfg = config.modules.hyprland; cfg = config.modules.hyprland;
in { in {
imports = [
inputs.hyprland.nixosModules.default
];
options.modules.hyprland = { options.modules.hyprland = {
enable = mkOption { enable = mkOption {
type = types.bool; type = types.bool;
@ -12,15 +16,17 @@ in {
}; };
config = mkIf cfg.enable { config = mkIf cfg.enable {
#programs.hyprland = { programs.hyprland = {
# enable = true; enable = true;
#}; };
# this was failing to build so i removed it. sorry!!!!!! # this was failing to build so i removed it. sorry!!!!!!
# -oat # -oat
# look outside your window!!! # look outside your window!!!
# -aether # -aether
# ok done (i removed it again) # ok done (i removed it again)
# -oat # -oat
# Do not trust the [Flower].
# -aether
user.packages = with pkgs; [ user.packages = with pkgs; [
grim grim

@ -0,0 +1,40 @@
{ config, lib, pkgs, options, ... }:
with lib;
let
cfg = config.modules.services.libreddit;
in {
options.modules.services.libreddit = {
enable = mkOption {
type = types.bool;
default = false;
};
domain = mkOption {
type = types.str;
default = "libreddit.oat.zone";
};
port = mkOption {
type = types.port;
default = 1590;
};
};
config = mkIf cfg.enable {
services = {
libreddit = {
enable = true;
package = pkgs.libreddit;
port = cfg.port;
};
nginx.enable = true;
nginx.virtualHosts."${cfg.domain}" = {
forceSSL = true;
enableACME = true;
locations."/" = {
proxyPass = "http://localhost:${toString cfg.port}";
};
};
};
};
}