|
1 | 1 | ## Notion proxy
|
2 | 2 |
|
3 |
| -Notion proxy for public page |
| 3 | +Deliver notion pages via your domain. |
| 4 | +Reference [fruitionsite](https://github.com/stephenou/fruitionsite) for rewrite html processing. |
| 5 | +This proxy does not depend on Cloudflare and launches on express server. |
4 | 6 |
|
5 | 7 | ### Node Version
|
6 | 8 |
|
7 | 9 | 18
|
8 | 10 |
|
9 | 11 | ### Environment variable
|
10 | 12 |
|
11 |
| -| Env | Description | Default | |
12 |
| -|-------------------|-----------------------------------------------------------------|----------------------------------| |
13 |
| -| PAGE_TITLE | Page title | "" | |
14 |
| -| PAGE_DESC | Page desc | "" | |
15 |
| -| GOOGLE_FONT | See: `https://developers.google.com/fonts/docs/getting_started` | "" | |
16 |
| -| PROXY_PORT | Proxy port number | 3456 | |
17 |
| -| DOMAIN | Proxy domain for rewrite | localhost:3456 | |
18 |
| -| IS_TLS | Proxy tls | false | |
19 |
| -| NOTION_PAGE_ID | Notion public page id | f1db0cfbe246475784c67f279289abea | |
20 |
| -| CUSTOM_SCRIPT | Custom script | "" | |
21 |
| -| CONTENT_CACHE_SEC | Cache time for loaded content (sec) | 300 | |
22 |
| - |
23 |
| -### Reference for rewrite html processing |
24 |
| - |
25 |
| -Reference: https://github.com/stephenou/fruitionsite |
| 13 | +| Env | Description | Default | |
| 14 | +|-------------------|--------------------------------------------|----------------------------------| |
| 15 | +| PAGE_TITLE | Page title on meta tag | "" | |
| 16 | +| PAGE_DESC | Page desc on meta tag | "" | |
| 17 | +| GOOGLE_FONT | See: `https://developers.google.com/fonts` | "" | |
| 18 | +| PROXY_PORT | Proxy port number | 3456 | |
| 19 | +| DOMAIN | Proxy domain for rewrite | localhost:3456 | |
| 20 | +| IS_TLS | Proxy tls(http/https) for rewrite | false | |
| 21 | +| NOTION_PAGE_ID | Notion public page id | f1db0cfbe246475784c67f279289abea | |
| 22 | +| CUSTOM_SCRIPT | Custom script | "" | |
| 23 | +| CONTENT_CACHE_SEC | Cache time for loaded content (sec) | 300 | |
26 | 24 |
|
27 | 25 | ### Getting started
|
28 | 26 |
|
29 | 27 | Start proxy for debug on local.
|
30 | 28 |
|
31 | 29 | ```bash
|
32 | 30 | $ npm ci
|
| 31 | +$ npm test |
33 | 32 | $ npm start_proxy
|
34 | 33 |
|
35 | 34 | > node src/index.js
|
|
0 commit comments