From faaa152dcc89f960fbfff492a077396026926d9a Mon Sep 17 00:00:00 2001 From: Bloxx12 Date: Wed, 9 Apr 2025 15:31:18 +0200 Subject: [PATCH 1/7] website: init --- website/index.html | 11 +++++++++++ website/style.css | 3 +++ 2 files changed, 14 insertions(+) create mode 100644 website/index.html create mode 100644 website/style.css diff --git a/website/index.html b/website/index.html new file mode 100644 index 0000000..6f1ec77 --- /dev/null +++ b/website/index.html @@ -0,0 +1,11 @@ + + + + + +

My Website

+ + + + + \ No newline at end of file diff --git a/website/style.css b/website/style.css new file mode 100644 index 0000000..00f89aa --- /dev/null +++ b/website/style.css @@ -0,0 +1,3 @@ +h1 { + text-align: center; +} \ No newline at end of file From e43afac1c8fe998e7a0d3c36bf79fbff0d109ed0 Mon Sep 17 00:00:00 2001 From: Bloxx12 Date: Wed, 9 Apr 2025 15:31:18 +0200 Subject: [PATCH 2/7] hyprland/settings.nix: enable compose:102, disable update news --- modules/wms/wayland/hyprland/settings.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/modules/wms/wayland/hyprland/settings.nix b/modules/wms/wayland/hyprland/settings.nix index 03314fd..bab7083 100644 --- a/modules/wms/wayland/hyprland/settings.nix +++ b/modules/wms/wayland/hyprland/settings.nix @@ -35,7 +35,7 @@ in { input = { kb_layout = "us,ru"; kb_variant = ",phonetic_winkeys"; - kb_options = "grp:rctrl_rshift_toggle,"; + kb_options = "grp:rctrl_rshift_toggle, compose:102"; follow_mouse = true; @@ -57,6 +57,8 @@ in { no_border_on_floating = true; }; + ecosystem.no_update_news = true; + plugin = { hyprsplit = { num_workspaces = 10; From dd356b21d403ab6458d9da382a8148fe785390f1 Mon Sep 17 00:00:00 2001 From: Bloxx12 Date: Wed, 9 Apr 2025 15:31:18 +0200 Subject: [PATCH 3/7] hermit/programs.nix: remove nextcloud-client --- hosts/hermit/programs.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/hosts/hermit/programs.nix b/hosts/hermit/programs.nix index 00de886..355b98f 100644 --- a/hosts/hermit/programs.nix +++ b/hosts/hermit/programs.nix @@ -53,7 +53,6 @@ ncmpcpp neofetch networkmanagerapplet - nextcloud-client nicotine-plus nil nitch From 6fbbc2715b2d4a2ce1d9798478ae365a94a33661 Mon Sep 17 00:00:00 2001 From: Bloxx12 Date: Wed, 9 Apr 2025 15:31:18 +0200 Subject: [PATCH 4/7] shell/packages.nix: add watchman --- packages/shell/packages.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/shell/packages.nix b/packages/shell/packages.nix index 7d31b6b..b5c7abf 100644 --- a/packages/shell/packages.nix +++ b/packages/shell/packages.nix @@ -51,6 +51,7 @@ builtins.attrValues { onefetch wget cpufetch + watchman yt-dlp tealdeer hyperfine From 19d5664be574ba39ea518920864114108edbe43d Mon Sep 17 00:00:00 2001 From: Bloxx12 Date: Wed, 9 Apr 2025 15:31:18 +0200 Subject: [PATCH 5/7] helix.nix: format, add taplo taplo is a toml language server --- packages/helix.nix | 49 ++++++++++++++++++++-------------------------- 1 file changed, 21 insertions(+), 28 deletions(-) diff --git a/packages/helix.nix b/packages/helix.nix index eb91eb6..763c8b0 100644 --- a/packages/helix.nix +++ b/packages/helix.nix @@ -1,7 +1,6 @@ { symlinkJoin, makeWrapper, - helix, alejandra, basedpyright, bash-language-server, @@ -16,6 +15,7 @@ gdb, golangci-lint-langserver, gopls, + helix, lazygit, lib, lldb_19, @@ -30,6 +30,7 @@ solargraph, stdenv, superhtml, + taplo, tinymist, typescript-language-server, vscode-langservers-extracted, @@ -276,38 +277,30 @@ wrapped-helix = symlinkJoin { name = "helix-wrapped"; paths = [ - helix - - rust-analyzer - rustfmt - clippy - # typst lsp - tinymist - - # C/C++ - clang-tools - - # Markdown - marksman - - # Nix - nil - lldb_19 # Bash bash-language-server - + # C/C++ + clang-tools + clippy + golangci-lint-langserver + gopls + helix + lldb_19 + # Markdown + marksman + # Nix + nil + rust-analyzer + rustfmt # Shell shellcheck - - # ruby - solargraph - - gopls - golangci-lint-langserver - - vscode-langservers-extracted - superhtml + # toml + taplo + # typst + tinymist + # typst lsp + vscode-langservers-extracted ]; buildInputs = [makeWrapper]; postBuild = '' From afafd02d9a8268bad4d6f037b7f7ccb71f0e9f31 Mon Sep 17 00:00:00 2001 From: Bloxx12 Date: Wed, 9 Apr 2025 15:31:18 +0200 Subject: [PATCH 6/7] nginx: simplify ssl settings --- modules/services/forgejo/module.nix | 14 ++------------ modules/services/nginx/module.nix | 4 ++++ 2 files changed, 6 insertions(+), 12 deletions(-) diff --git a/modules/services/forgejo/module.nix b/modules/services/forgejo/module.nix index a09f987..079441c 100644 --- a/modules/services/forgejo/module.nix +++ b/modules/services/forgejo/module.nix @@ -33,19 +33,9 @@ in { services.nginx = { enable = true; virtualHosts.${domain} = { - forceSSL = true; - # enableACME = true; - useACMEHost = domain; - inherit acmeRoot; - extraConfig = '' - # nginx defaults to a 1MB size limit for uploads, which - # *definitely* isn't enough for Git LFS. - # 'client_max_body_size 300m;' would set a limit of 300MB - # setting it to 0 means "no limit" - client_max_body_size 512M; - ''; + addSSL = true; + enableACME = true; locations."/" = { - recommendedProxySettings = true; proxyPass = "http://localhost:${toString port}"; }; }; diff --git a/modules/services/nginx/module.nix b/modules/services/nginx/module.nix index 63fcef0..67e958a 100644 --- a/modules/services/nginx/module.nix +++ b/modules/services/nginx/module.nix @@ -27,6 +27,10 @@ in { recommendedProxySettings = true; recommendedZstdSettings = true; + # nginx defaults to a 1MB size limit for uploads, which + # *definitely* isn't enough for Git LFS. + # 'client_max_body_size 300m;' would set a limit of 300MB + # setting it to 0 means "no limit" clientMaxBodySize = mkDefault "512m"; }; }; From e4ef026a0c3fafa2a778c664c52b071d40b8449d Mon Sep 17 00:00:00 2001 From: Bloxx12 Date: Wed, 9 Apr 2025 15:31:18 +0200 Subject: [PATCH 7/7] website: init --- hosts/hermit/programs.nix | 1 - website/blog/01-BGP.txt | 66 +++++++++++++++++++++++++++ website/blog/posts/01.html | 91 ++++++++++++++++++++++++++++++++++++++ website/blog/posts/02.html | 1 + website/index.html | 22 +++++++++ website/style.css | 58 ++++++++++++++++++++++++ website/template.html | 19 ++++++++ 7 files changed, 257 insertions(+), 1 deletion(-) create mode 100644 website/blog/01-BGP.txt create mode 100644 website/blog/posts/01.html create mode 100644 website/blog/posts/02.html create mode 100644 website/index.html create mode 100644 website/style.css create mode 100644 website/template.html diff --git a/hosts/hermit/programs.nix b/hosts/hermit/programs.nix index 355b98f..b5b498f 100644 --- a/hosts/hermit/programs.nix +++ b/hosts/hermit/programs.nix @@ -9,7 +9,6 @@ alsa-utils anki asciinema - brave cachix calc # calibre diff --git a/website/blog/01-BGP.txt b/website/blog/01-BGP.txt new file mode 100644 index 0000000..72b0dea --- /dev/null +++ b/website/blog/01-BGP.txt @@ -0,0 +1,66 @@ + +TODO: +eBGP/iBGP session +Graphs + +/**********************************************/ +/* A no-bullshit guide to a bullshit protocol */ +/**********************************************/ + We can think of the Internet as a network of networks which are all connected in some way. We will refer to these networks as Autonomous Systems(AS) in this article. + +Now, how do we connect these AS's in a sane way? This is where BGP comes in. BGP, which stands for `Border Gateway Protocol`, enables different AS's to exchange information with each other, e.g. communicating with each other. + +There are three main challenges BGP has to solve: + - Scalability: The Internet is BIG. BGP needs to scale well to be feasible in a large scale. + - Privacy: Networks don't want to divulge internal topologies (topology = how a network is structured) + - Policy enforcement: The Networks themselves need to have control over where to send and recieve traffic. + +Other protocols, like Link-Sate routing, do not solve these challenges. + +BGP's key concept, which it revolves about, is called *path-vector routing*, where it adertises the entire AS-level path. +Now, what is an AS-level path? We'll get to that in a minute. + +Before that, why do we need even BGP? The problem is that sending data over the internet costs money. If we want to minimize the costs of sending data, we need to find routes which cost as little as possible. This is also why BGP is a "follow the money" protocol. Different ASes only connect with each other if they can save money that way. + +There are two policies we can use to define this routing: + - Selection: Which path to use (only relevant for outbound traffic) + - Export: Which path to advertise (only relevant for inbount traffic) + +TODO: add graphs here + +=============================================== + eBGP and iBGP +=============================================== + +BGP comes in two flavors: eBGP and iBGP. +The e/i stands for external/internal + +External BGP sessions connect border routers in different ASes. These are therefore use to learn routes to external destinatons + +TODO: add graph + +Internal BGP sessions connect the routers in the same AS. These are used to split up externally-learned routes internally. These are tehn announces exernally(to other ASes) again, using eBGP sessions. + +BGP itself is a pretty simple protocol composed of four basic messages: + - open: establish a BGP session (using TCP) + - notification: report unusual conditions + - update: inform neighbor of a new best route + - can be a change or a removal of a best route + - keepalive: inform neighbor that connection is alive + +update messages carry an IP prefix together with a set of attributes: +/*********************/ +/* IP prefix */ +/*********************/ +/* Attributes */ +/* */ +/* */ +/* */ +/* */ +/*********************/ + +There are four types of different attributes: + - NEXT-HOP + - AS-PATH + - LOCAL-PREF + - MED diff --git a/website/blog/posts/01.html b/website/blog/posts/01.html new file mode 100644 index 0000000..c3d56ad --- /dev/null +++ b/website/blog/posts/01.html @@ -0,0 +1,91 @@ + + + + + +
+
+
+
+
+        TODO:
+        eBGP/iBGP session
+        Graphs
+
+        /**********************************************/
+        /* A no-bullshit guide to a bullshit protocol */
+        /**********************************************/
+        We can think of the Internet as a network of networks which are all connected in some way. We will refer to
+        these networks as Autonomous Systems(AS) in this article.
+
+        Now, how do we connect these AS's in a sane way? This is where BGP comes in. BGP, which stands for `Border
+        Gateway Protocol`, enables different AS's to exchange information with each other, e.g. communicating with each
+        other.
+
+        There are three main challenges BGP has to solve:
+        - Scalability: The Internet is BIG. BGP needs to scale well to be feasible in a large scale.
+        - Privacy: Networks don't want to divulge internal topologies (topology = how a network is structured)
+        - Policy enforcement: The Networks themselves need to have control over where to send and recieve traffic.
+
+        Other protocols, like Link-Sate routing, do not solve these challenges.
+
+        BGP's key concept, which it revolves about, is called *path-vector routing*, where it adertises the entire
+        AS-level path.
+        Now, what is an AS-level path? We'll get to that in a minute.
+
+        Before that, why do we need even BGP? The problem is that sending data over the internet costs money. If we want
+        to minimize the costs of sending data, we need to find routes which cost as little as possible. This is also why
+        BGP is a "follow the money" protocol. Different ASes only connect with each other if they can save money that
+        way.
+
+        There are two policies we can use to define this routing:
+        - Selection: Which path to use (only relevant for outbound traffic)
+        - Export: Which path to advertise (only relevant for inbount traffic)
+
+        TODO: add graphs here
+
+        ===============================================
+        eBGP and iBGP
+        ===============================================
+
+        BGP comes in two flavors: eBGP and iBGP.
+        The e/i stands for external/internal
+
+        External BGP sessions connect border routers in different ASes. These are therefore use to learn routes to
+        external destinatons
+
+        TODO: add graph
+
+        Internal BGP sessions connect the routers in the same AS. These are used to split up externally-learned routes
+        internally. These are tehn announces exernally(to other ASes) again, using eBGP sessions.
+
+        BGP itself is a pretty simple protocol composed of four basic messages:
+        - open: establish a BGP session (using TCP)
+        - notification: report unusual conditions
+        - update: inform neighbor of a new best route
+        - can be a change or a removal of a best route
+        - keepalive: inform neighbor that connection is alive
+
+        update messages carry an IP prefix together with a set of attributes:
+        /*********************/
+        /* IP prefix */
+        /*********************/
+        /* Attributes */
+        /* */
+        /* */
+        /* */
+        /* */
+        /*********************/
+
+        There are four types of different attributes:
+        - NEXT-HOP
+        - AS-PATH
+        - LOCAL-PREF
+        - MED
+      
+
+
+ + + + \ No newline at end of file diff --git a/website/blog/posts/02.html b/website/blog/posts/02.html new file mode 100644 index 0000000..499aefa --- /dev/null +++ b/website/blog/posts/02.html @@ -0,0 +1 @@ +JJ is is a new version control system, made to be compatible with git and _much_ less painful than it. \ No newline at end of file diff --git a/website/index.html b/website/index.html new file mode 100644 index 0000000..ff6e4f0 --- /dev/null +++ b/website/index.html @@ -0,0 +1,22 @@ + + + + + + +
+

My Website

+

+ Welcome to my website. Here I share some heartfelt ramblings about different things.
+

+
+ +
+

Brain farts

+

2025

+ I love JJ +
+
+ + + \ No newline at end of file diff --git a/website/style.css b/website/style.css new file mode 100644 index 0000000..13dc9b8 --- /dev/null +++ b/website/style.css @@ -0,0 +1,58 @@ +* { + margin: 0px; + padding: 0px; + line-height: 1.4; +} + +h1 { + text-align: center; +} + +body { + color: #FFFFFF; + background-color: #000000; + font-family: sans-serif; + font-size: 12; +} + +.content { + margin: auto; + padding: 5px; + max-width: 45em; + padding: 1em; + /* width: 100%; */ + border: 3px solid darkred; + overflow: auto; +} + +/* .around { */ +/* border: 1px solid grey; */ +/* margin: auto; */ +/* max-width: 685px; */ +/* padding: 1px; */ +/* width: 100%; */ +/* text-align: center; */ +/* } */ + +.post { + width: 76ch; + word-break: break-all; + font: mo; +} + +.years { + padding: 4px; + border-bottom: solid gray; +} + +pre { + text-align: left; + color: black; + padding: 20px; + padding-top: 5px; + margin: 0px; + font-size: 12px; + text-decoration: none; + overflow: hidden; + background-color: white; +} \ No newline at end of file diff --git a/website/template.html b/website/template.html new file mode 100644 index 0000000..5b618f9 --- /dev/null +++ b/website/template.html @@ -0,0 +1,19 @@ + + + + + +
+
+ Year + : [ + + ] +
+
+
+
+ + + + \ No newline at end of file