Pulumi code for my server setup
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

add relay motd

+40 -4
+1 -1
services/haring/atproto/did-web.ts
··· 11 11 } 12 12 `; 13 13 14 - export const didwebCaddyService = new ContainerService("didweb", { 14 + export const didwebCaddyService = new ContainerService("caddy-didweb", { 15 15 image: "caddy", 16 16 servicePort: 80, 17 17 hostRule: "Host(`bas.sh`) && Path(`/.well-known/did.json`)",
+2 -1
services/haring/atproto/pds/pds.ts
··· 10 10 export const pdsService = new ContainerService("pds", { 11 11 image: "ghcr.io/bluesky-social/pds", 12 12 servicePort: 3000, 13 + hostRule: "HostRegexp(`^(.+\\.)?pds.bas.sh$`)", 13 14 mounts: [confMount("pds", "/pds")], 14 15 envs: { 15 16 PDS_HOSTNAME: "pds.bas.sh", ··· 64 65 } 65 66 `; 66 67 67 - export const pdsCaddyService = new ContainerService(`pds-web`, { 68 + export const pdsCaddyService = new ContainerService("pds-web", { 68 69 image: "caddy", 69 70 servicePort: 80, 70 71 hostRule: "Host(`pds.bas.sh`) && (Path(`/`) || Path(`/xrpc/app.bsky.ageassurance.getState`))",
+1 -1
services/haring/atproto/pegasus.ts
··· 7 7 export const pegasusService = new ContainerService("pegasus", { 8 8 image: "ghcr.io/futurgh/pegasus", 9 9 servicePort: 8008, 10 - hostRule: "HostRegexp(`^(.+?\\.)?pegasus\\.bas\\.sh`)", 10 + hostRule: "HostRegexp(`^(.+?\\.)?pegasus\\.bas\\.sh$`)", 11 11 mounts: [confMount("pegasus", "/data")], 12 12 envs: { 13 13 PSD_LOG_LEVEL: "info",
+35
services/haring/atproto/relay.ts
··· 46 46 }, 47 47 ); 48 48 49 + const RELAY_MOTD = ` 50 + 「Become a magical girl today!」 51 + / 52 + /人◕ ‿‿ ◕人\ 53 + 54 + 55 + This is an atproto [https://atproto.com] relay instance, running the 'relay' codebase [https://github.com/bluesky-social/indigo] 56 + 57 + The firehose WebSocket path is at: /xrpc/com.atproto.sync.subscribeRepos 58 + `; 59 + 60 + const CADDYFILE = ` 61 + :80 { 62 + respond "${RELAY_MOTD}" 200 63 + } 64 + `; 65 + 66 + export const relayCaddyService = new ContainerService("caddy-relay", { 67 + image: "caddy", 68 + servicePort: 80, 69 + hostRule: "Host(`relay.bas.sh`) && Path(`/`)", 70 + hostRulePriority: 1000, 71 + command: ["/bin/sh", "-c", `echo '${CADDYFILE}' | caddy run --config - --adapter caddyfile`], 72 + middlewares: ["cors"], 73 + labels: { 74 + "traefik.http.middlewares.relay-favicon.redirectregex.regex": 75 + "^https://relay\\.bas\\.sh/favicon\\.ico$", 76 + "traefik.http.middlewares.relay-favicon.redirectregex.replacement": 77 + "https://tranquil.bas.sh/favicon.ico", 78 + "traefik.http.routers.relay-favicon.entrypoints": "https", 79 + "traefik.http.routers.relay-favicon.rule": "Host(`relay.bas.sh`) && Path(`/favicon.ico`)", 80 + "traefik.http.routers.relay-favicon.middlewares": "cloudflare,relay-favicon", 81 + }, 82 + }); 83 + 49 84 export const relayService = new ContainerService( 50 85 "relay", 51 86 {
+1 -1
services/haring/atproto/tranquil/tranquil.ts
··· 83 83 { 84 84 localImage: tranquilImage.digest, 85 85 servicePort: 3000, 86 - hostRule: "HostRegexp(`^(.+?\\.)?(t(ranquil)|o(n|f))\\.bas\\.sh`)", 86 + hostRule: "HostRegexp(`^(.+?\\.)?(t(ranquil)|o(n|f))\\.bas\\.sh$`)", 87 87 mounts: [ 88 88 confMount("tranquil/backups", "/var/lib/tranquil/backups"), 89 89 confMount("tranquil/blobs", "/var/lib/tranquil/blobs"),