tangled
alpha
login
or
join now
aottr.dev
/
wisp.place-monorepo
forked from
nekomimi.pet/wisp.place-monorepo
0
fork
atom
Monorepo for wisp.place. A static site hosting service built on top of the AT Protocol.
0
fork
atom
overview
issues
pulls
pipelines
add cache dir env
nekomimi.pet
4 months ago
7a0ff72d
dacf0818
+2
-2
2 changed files
expand all
collapse all
unified
split
hosting-service
src
index.ts
lib
utils.ts
+1
-1
hosting-service/src/index.ts
···
5
5
import { mkdirSync, existsSync } from 'fs';
6
6
7
7
const PORT = process.env.PORT ? parseInt(process.env.PORT) : 3001;
8
8
-
const CACHE_DIR = './cache/sites';
8
8
+
const CACHE_DIR = process.env.CACHE_DIR || './cache/sites';
9
9
10
10
// Ensure cache directory exists
11
11
if (!existsSync(CACHE_DIR)) {
+1
-1
hosting-service/src/lib/utils.ts
···
5
5
import { safeFetchJson, safeFetchBlob } from './safe-fetch';
6
6
import { CID } from 'multiformats';
7
7
8
8
-
const CACHE_DIR = './cache/sites';
8
8
+
const CACHE_DIR = process.env.CACHE_DIR || './cache/sites';
9
9
const CACHE_TTL = 14 * 24 * 60 * 60 * 1000; // 14 days cache TTL
10
10
11
11
interface CacheMetadata {