category
tags
type
status
slug
date
summary
icon
password
NotionNext支持部署在去中心化的Web3.0平台,可以尝试体验一下
准备
访问4everland官网,并使用github登录
![notion image](https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F9b06e9d3-17f4-4388-8df8-79e8b4287176%2FUntitled.png?table=block&id=c035c7f4-139f-47b4-bbdf-63e831d87395)
导入项目
点击
New Project
![notion image](https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F47fd2288-ee02-4c38-b5e5-ad817efed94b%2FUntitled.png?table=block&id=c9dd2d68-5eb5-467f-86a1-83ccf8ef9688)
找到您的NotionNext项目,请确保您的NotionNext项目是最新的,并且项目中有包含deploy/4everland分支。
点击右侧的Import导入
![notion image](https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Fd90a1f0a-cf20-43a6-a566-445c54121219%2FUntitled.png?table=block&id=542ea08a-6560-4039-9da5-248a99b2b615)
修改配置
有4处必须修改:
- Branch,分支改为
deploy/4everland
,如无此分支,请从我的代码仓库拉取次分支。
- Build Command 编译命令, 改为
yarn export
- Node.js Version 环境版本改为
18.x
- 环境变量添加一项
VERCEL_ENV
=production
, 记的点击右侧的Add
,然后别忘了添加一个环境变量NOTION_PAGE_ID
, 这里的环境变量配置方式和Vercel无异。
![notion image](https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Fd0b78d6e-c3ca-495c-aa1f-de81c9a52291%2FUntitled.png?table=block&id=1ebd6303-0d1b-48e7-a5f9-9609590e9b4a)
完成
点击底部的Deploy即可部署。 静候几分钟即可。
![notion image](https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F4614d76f-4cb4-455c-8f69-8f9870bd8d76%2FUntitled.png?table=block&id=6721271e-9e41-4b82-bd5a-9888dafb34e6)
特别说明
cloudflarePage 和 4everland 这两种部署方案,实际上是将Next项目导出为静态html。
这样做的缺陷是不支持根据notion内容动态更新。
修改或发布文章后,请到4everland 后台点击重新部署。
- 作者:NotionNext
- 链接:https://tangly1024.com/notionnext-4everland
- 声明:本文采用 CC BY-NC-SA 4.0 许可协议,转载请注明出处。
相关文章