summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorseth <[email protected]>2023-05-16 05:33:15 -0400
committerseth <[email protected]>2023-05-16 05:33:15 -0400
commitf64ebd9402c03de16ec11b0986a42416a25bd2ac (patch)
treeda673680b342afcd194c18460c0fb5ae3f47044b
parent453e8e84385ca357f0fc7f50e1ec285f6625470e (diff)
p-body: start hosting my website
-rw-r--r--flake.lock24
-rw-r--r--flake.nix5
-rw-r--r--hosts/p-body/default.nix3
-rw-r--r--hosts/p-body/nginx.nix18
4 files changed, 35 insertions, 15 deletions
diff --git a/flake.lock b/flake.lock
index f257039..4633f81 100644
--- a/flake.lock
+++ b/flake.lock
@@ -219,6 +219,29 @@
"type": "github"
}
},
+ "getchoo-website": {
+ "inputs": {
+ "nixpkgs": [
+ "nixpkgsUnstable"
+ ],
+ "pre-commit-hooks": [
+ "pre-commit-hooks"
+ ]
+ },
+ "locked": {
+ "lastModified": 1684228639,
+ "narHash": "sha256-kOQIvjFSqAR7hGB5qNx7FDMpIcydFExlxQ6lEIsATI4=",
+ "owner": "getchoo",
+ "repo": "getchoo.github.io",
+ "rev": "4b2f271406f4f32dee01d0ecb7d8528e9eae1c1d",
+ "type": "github"
+ },
+ "original": {
+ "owner": "getchoo",
+ "repo": "getchoo.github.io",
+ "type": "github"
+ }
+ },
"gitignore": {
"inputs": {
"nixpkgs": [
@@ -595,6 +618,7 @@
"flake-parts": "flake-parts",
"flake-utils": "flake-utils",
"getchoo": "getchoo",
+ "getchoo-website": "getchoo-website",
"guzzle_api": "guzzle_api",
"hercules-ci-agent": "hercules-ci-agent",
"hercules-ci-effects": "hercules-ci-effects",
diff --git a/flake.nix b/flake.nix
index d9dab8e..592cac8 100644
--- a/flake.nix
+++ b/flake.nix
@@ -34,6 +34,11 @@
inputs.nixpkgs.follows = "nixpkgs";
inputs.flake-compat.follows = "flake-compat";
};
+ getchoo-website = {
+ url = "github:getchoo/getchoo.github.io";
+ inputs.nixpkgs.follows = "nixpkgsUnstable";
+ inputs.pre-commit-hooks.follows = "pre-commit-hooks";
+ };
guzzle_api = {
url = "github:getchoo/guzzle_api";
inputs.nixpkgs.follows = "nixpkgsUnstable";
diff --git a/hosts/p-body/default.nix b/hosts/p-body/default.nix
index 7005854..1a92889 100644
--- a/hosts/p-body/default.nix
+++ b/hosts/p-body/default.nix
@@ -1,5 +1,6 @@
{
config,
+ getchoo-website,
guzzle_api,
modulesPath,
pkgs,
@@ -24,6 +25,8 @@
hostName = "p-body";
};
+ nixpkgs.overlays = [getchoo-website.overlays.default];
+
services = {
guzzle-api = {
enable = true;
diff --git a/hosts/p-body/nginx.nix b/hosts/p-body/nginx.nix
index 0be0f5b..50a5b92 100644
--- a/hosts/p-body/nginx.nix
+++ b/hosts/p-body/nginx.nix
@@ -34,21 +34,9 @@ in {
enableACME = true;
serverAliases = ["www.${domain}"];
- locations = {
- "/" = {
- root =
- pkgs.writeTextDir "index.html"
- ''
- <!DOCTYPE html>
- <html lang="en">
- <body style="text-align: center;">
- <iframe width="560" height="315" src="https://www.youtube.com/embed/voXpIgb9Nbk" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe>
- </body>
- </html>
- '';
-
- index = "index.html";
- };
+ locations."/" = {
+ root = "${pkgs.getchoo-website}/libexec/getchoo-website/deps/getchoo-website/dist/";
+ index = "index.html";
};
};