| author | |
| committer | |
| log | 881042bdfc7394daeb49e3f63b23f386b5e541ce |
| tree | d23b378cc77d7bbb8c2c2516a0d7fd8f376bc4e6 |
| parent | e2c13208274007fa2abc59668649e28c3c57c36b |
| signature | Commit is signed but in an unrecognized format. |
4 files changed, 9 insertions(+), 6 deletions(-)
framework/backend/entry-node.ts+1-1| ... | ... | @@ -6,7 +6,7 @@ const app = require(globalThis.CLOVER_SERVER_ENTRY ?? process.argv[2]); |
| 6 | 6 | const protocol = "http"; |
| 7 | 7 | |
| 8 | 8 | const server = serve({ |
| 9 | fetch: app.fetch, | |
| 9 | fetch: app.default.fetch, | |
| 10 | 10 | port: Number(process.env.PORT ?? 3000), |
| 11 | 11 | }, ({ address, port }) => { |
| 12 | 12 | if (address === "::") address = "::1"; |
readme.md+3| ... | ... | @@ -104,6 +104,9 @@ Deployment of the source of truth can be done with Docker Compose: |
| 104 | 104 | - /mnt/storage1/clover/Documents/Config/paperclover:/data |
| 105 | 105 | - /mnt/storage1/clover/Published:/published |
| 106 | 106 | |
| 107 | Due to caching, one may need to manually purge images via | |
| 108 | `docker image rm ix-paperclover-backend -f` when an update is desired | |
| 109 | ||
| 107 | 110 | TODO: deployment instructions for a web node |
| 108 | 111 | |
| 109 | 112 | ## Contributions |
src/source-of-truth.dockerfile+4-4| ... | ... | @@ -1,6 +1,6 @@ |
| 1 | from node:24-alpine as builder | |
| 1 | from node:24 as builder | |
| 2 | 2 | |
| 3 | run apk add --no-cache git | |
| 3 | run apt install -y git | |
| 4 | 4 | |
| 5 | 5 | workdir /paperclover.net |
| 6 | 6 | copy package*.json ./ |
| ... | ... | @@ -17,12 +17,12 @@ run npx esbuild --bundle \ |
| 17 | 17 | --outdir=/app \ |
| 18 | 18 | && cp framework/lib/mime.txt /app/ |
| 19 | 19 | |
| 20 | from node:24-alpine as runtime | |
| 20 | from node:24 as runtime | |
| 21 | 21 | |
| 22 | 22 | workdir /app |
| 23 | 23 | copy --from=builder /app/ ./ |
| 24 | 24 | |
| 25 | env PORT=3001 | |
| 25 | env PORT=43200 | |
| 26 | 26 | # must be configured |
| 27 | 27 | env CLOVER_DB=/dev/null |
| 28 | 28 | env CLOVER_FILE_RAW=/dev/null |
src/source-of-truth.ts+1-1| ... | ... | @@ -31,7 +31,7 @@ const nasRoot = process.platform === "win32" |
| 31 | 31 | const rawFileRoot = process.env.CLOVER_FILE_RAW ?? |
| 32 | 32 | path.join(nasRoot, "Published"); |
| 33 | 33 | const derivedFileRoot = process.env.CLOVER_FILE_DERIVED ?? |
| 34 | path.join(nasRoot, "Documents/Config/clover_file/derived"); | |
| 34 | path.join(nasRoot, "Documents/Config/paperclover/derived"); | |
| 35 | 35 | |
| 36 | 36 | if (!fs.existsSync(rawFileRoot)) throw new Error(`${rawFileRoot} does not exist`); |
| 37 | 37 | if (!fs.existsSync(derivedFileRoot)) throw new Error(`${derivedFileRoot} does not exist`); |