From 73420fe65439605138bf4cfa0b2e2ba3306888d4 Mon Sep 17 00:00:00 2001 From: Suraj B M Date: Mon, 28 Sep 2026 16:45:19 +0530 Subject: [PATCH] feat: add base caddyfile content to mappings.ts --- caddie.ts | 8 ++------ mappings.example.ts | 6 ++++++ 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/caddie.ts b/caddie.ts index 920099c..114baa6 100755 --- a/caddie.ts +++ b/caddie.ts @@ -1,12 +1,8 @@ import { writeFileSync } from "fs" -import mappings from "./mappings" +import mappings, { baseCaddyfile } from "./mappings" let caddyfile = `# Caddyfile -hy-pr.link { - redir /silicoflare https://silicoflare.dev - redir /flare https://silicoflare.dev -} - +${baseCaddyfile} ` Object.entries(mappings).map(([key, value]) => { diff --git a/mappings.example.ts b/mappings.example.ts index 729d6a9..7336959 100644 --- a/mappings.example.ts +++ b/mappings.example.ts @@ -12,4 +12,10 @@ const mappings = { "ssh.example.com": "key:ssh-ed25519 qwerty1234567890 example.com", } +export const baseCaddyfile = ` +example.com { + reverse_proxy http://localhost:8080; +} +`; + export default mappings; \ No newline at end of file