summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJake Zerrer <him@jakezerrer.com>2025-11-30 12:31:01 -0500
committerJake Zerrer <him@jakezerrer.com>2025-11-30 17:27:46 -0500
commit119cf7f780375187dbe3d064263a9de3a17f538d (patch)
tree376d48fc42d19ed49ca3f740e7c0e4c15596d11d
parent034e30d70aeac7ce18f34be6a1c211730e9fd7fb (diff)
Move from github pages to server
-rw-r--r--.github/workflows/deploy.yml66
-rwxr-xr-xbin/publish15
-rw-r--r--home/.gitignore3
-rw-r--r--home/404.html (renamed from 404.html)2
-rw-r--r--home/deps.edn (renamed from deps.edn)0
-rw-r--r--home/dev/repl.clj (renamed from dev/repl.clj)0
-rw-r--r--home/src/components.clj (renamed from src/components.clj)2
-rw-r--r--home/src/core.clj (renamed from src/core.clj)0
-rw-r--r--home/src/highlight.clj (renamed from src/highlight.clj)0
-rw-r--r--home/src/pages.clj (renamed from src/pages.clj)0
-rw-r--r--home/src/pages/missionary.clj (renamed from src/pages/missionary.clj)0
-rw-r--r--home/src/pages/second_sex.clj (renamed from src/pages/second_sex.clj)0
-rw-r--r--server/server.nix16
13 files changed, 36 insertions, 68 deletions
diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml
deleted file mode 100644
index 1431b13..0000000
--- a/.github/workflows/deploy.yml
+++ /dev/null
@@ -1,66 +0,0 @@
-name: Build and Deploy to GitHub Pages
-
-on:
- push:
- branches: [ main ]
- workflow_dispatch:
-
-permissions:
- contents: read
- pages: write
- id-token: write
-
-concurrency:
- group: "pages"
- cancel-in-progress: false
-
-jobs:
- build:
- runs-on: ubuntu-latest
- steps:
- - name: Checkout
- uses: actions/checkout@v5
-
- - name: Setup Java
- uses: actions/setup-java@v4
- with:
- distribution: 'temurin'
- java-version: '17'
-
- - name: Cache Clojure dependencies
- uses: actions/cache@v4
- with:
- path: |
- ~/.m2/repository
- ~/.gitlibs
- ~/.deps.clj
- key: ${{ runner.os }}-clojure-${{ hashFiles('**/deps.edn') }}
- restore-keys: |
- ${{ runner.os }}-clojure-
-
- - name: Install Clojure CLI tools
- uses: DeLaGuardo/setup-clojure@13.4
- with:
- cli: 1.12.1.1550
-
- - name: Build site
- run: clojure -M -m core
-
- - name: Setup Pages
- uses: actions/configure-pages@v5
-
- - name: Upload artifact
- uses: actions/upload-pages-artifact@v3
- with:
- path: 'target/html'
-
- deploy:
- environment:
- name: github-pages
- url: ${{ steps.deployment.outputs.page_url }}
- runs-on: ubuntu-latest
- needs: build
- steps:
- - name: Deploy to GitHub Pages
- id: deployment
- uses: actions/deploy-pages@v4
diff --git a/bin/publish b/bin/publish
new file mode 100755
index 0000000..0ca651d
--- /dev/null
+++ b/bin/publish
@@ -0,0 +1,15 @@
+#!/usr/bin/env bash
+
+set -e
+
+# Change to the project root directory
+cd "$(dirname "$0")/.."
+
+echo "Building site..."
+cd home
+clojure -M -e "(require 'core) (core/-main) (shutdown-agents)"
+
+echo "Publishing to server..."
+scp -r target/html/* git@jakezerrer.com:/var/www/html/
+
+echo "Site published successfully!"
diff --git a/home/.gitignore b/home/.gitignore
new file mode 100644
index 0000000..34f5ad2
--- /dev/null
+++ b/home/.gitignore
@@ -0,0 +1,3 @@
+.cpcache
+.nrepl-port
+target
diff --git a/404.html b/home/404.html
index 6eb0dd5..51e5fa7 100644
--- a/404.html
+++ b/home/404.html
@@ -148,4 +148,4 @@ span.linenos.special { color: #000000; background-color: #ffffc0; padding-left:
.output .vi { color: #19177C } /* Name.Variable.Instance */
.output .vm { color: #19177C } /* Name.Variable.Magic */
.output .il { color: #666666 } /* Literal.Number.Integer.Long */
-li { line-height: 1.6; }p { line-height: 1.6; font-family: Palatino; }.page-body p { max-width: 44em; }.page-body blockquote { max-width: 44em; margin-left: 2em; }hr { border: none; height: 1px; background-color: #ccc; margin: 2em 0; }.highlight { padding: 1px; padding-left: 6px; }</style><meta charset="UTF-8"></head><body><p><a href="/">&lt; home</a></p><div class="page-body"><h1>404 Oh, be some other path!</h1><p>What&apos;s in a path? That which we call a page<br>by any other path would fail to load</p></div><footer><br><br><p>---</p><span><a href="https://github.com/telekid/jakezerrer">page src</a> | <a href="mailto:contact@jakezerrer.com?subject=Blog post">contact me</a></span></footer></body></html> \ No newline at end of file
+li { line-height: 1.6; }p { line-height: 1.6; font-family: Palatino; }.page-body p { max-width: 44em; }.page-body blockquote { max-width: 44em; }.highlight { padding: 1px; padding-left: 6px; }</style><meta charset="UTF-8"></head><body><p><a href="/">&lt; home</a></p><div class="page-body"><h1>404 Oh, be some other path!</h1><p>What&apos;s in a path? That which we call a page<br>by any other path would fail to load</p></div><footer><br><br><p>---</p><span><a href="https://git.jakezerrer.com/jakezerrer.git/">page src</a> | <a href="mailto:contact@jakezerrer.com?subject=Blog post">contact me</a></span></footer></body></html> \ No newline at end of file
diff --git a/deps.edn b/home/deps.edn
index 5a4bbd0..5a4bbd0 100644
--- a/deps.edn
+++ b/home/deps.edn
diff --git a/dev/repl.clj b/home/dev/repl.clj
index ced6fae..ced6fae 100644
--- a/dev/repl.clj
+++ b/home/dev/repl.clj
diff --git a/src/components.clj b/home/src/components.clj
index ed0444d..d4d30a0 100644
--- a/src/components.clj
+++ b/home/src/components.clj
@@ -25,7 +25,7 @@
[:br]
[:p "---"]
[:span
- [:a {:href "https://github.com/telekid/jakezerrer"} "page src"]
+ [:a {:href "https://git.jakezerrer.com/jakezerrer.git/"} "page src"]
" | "
[:a {:href "mailto:contact@jakezerrer.com?subject=Blog post"} "contact me"]]]]]))
diff --git a/src/core.clj b/home/src/core.clj
index b8ba344..b8ba344 100644
--- a/src/core.clj
+++ b/home/src/core.clj
diff --git a/src/highlight.clj b/home/src/highlight.clj
index f229b1a..f229b1a 100644
--- a/src/highlight.clj
+++ b/home/src/highlight.clj
diff --git a/src/pages.clj b/home/src/pages.clj
index a793fd3..a793fd3 100644
--- a/src/pages.clj
+++ b/home/src/pages.clj
diff --git a/src/pages/missionary.clj b/home/src/pages/missionary.clj
index 2bb06de..2bb06de 100644
--- a/src/pages/missionary.clj
+++ b/home/src/pages/missionary.clj
diff --git a/src/pages/second_sex.clj b/home/src/pages/second_sex.clj
index 97b7602..97b7602 100644
--- a/src/pages/second_sex.clj
+++ b/home/src/pages/second_sex.clj
diff --git a/server/server.nix b/server/server.nix
index f751083..e214b51 100644
--- a/server/server.nix
+++ b/server/server.nix
@@ -32,6 +32,7 @@
systemd.tmpfiles.rules = [
"d /var/git 0750 git git -"
"Z /var/git - git git -"
+ "d /var/www/html 0755 git nginx -"
];
sops = {
@@ -74,6 +75,21 @@
enableACME = true;
forceSSL = true;
};
+
+ virtualHosts."jakezerrer.com" = {
+ enableACME = true;
+ forceSSL = true;
+ globalRedirect = "www.jakezerrer.com";
+ };
+
+ virtualHosts."www.jakezerrer.com" = {
+ enableACME = true;
+ forceSSL = true;
+ root = "/var/www/html";
+ locations."/" = {
+ index = "index.html";
+ };
+ };
};
security.acme = {