[Tools] Deploy a Monorepo to Now V2
2024-09-04 09:56:13
Now by Zeit has recently been updated and now supports multi-language monorepos. In this lesson we'll build and deploy a simple app with an API powered by Node.js and Go.
If you want to follow along with this lesson, you will need to install now-cli.
Install:
npm i -g now
Create now.json:
{
"version": ,
}
If we have a index.html, already. We can still run:
now
to deploy the site.
Let's say we have current folder structure:
src
-- index.js
index.html (it includes index.js by inline - script)
We need to include index.js file as well when deploy:
now.json:
{
"version": ,
"builds": [
{ "src": "src/index.js", "use": "@now/node" },
{ "src": "index.html", "use": "@now/static" }
]
}
If you are using npm modules which installed by yarn or npm, switch to @now/node-server
最新文章
- Linux.NET实战手记—自己动手改泥鳅(下)
- Tomcat:使用JMX监管Tomcat的几种方式
- 关于QQ使用的一些代码
- xshell连接本地虚拟机
- NodeJS用递归实现异步操作的链式调用,完成一个简易的命令行输入输出REPL交互接口
- WPF 打开文件 打开路径对话框
- PHPMailer实现PHP邮件发送
- 【windows】 配置一个本地的tomcat服务器
- C++回顾day03---<;多态>;
- 关于Eclipse导入项目jsp出现红色叉的解决办法
- 容器化 — 基于Docker技术容器云
- node模块之path——path.join和path.resolve的区别
- Hadoop 1: NCDC 数据准备
- mysql java 类型对照 int
- C#高级编程9-第6章 数组
- git及github配置入门
- 绿化和卸载 DOS 批处理
- [CTSC2008]祭祀
- 【转】JMeter试用手记
- js 把字符串当做方法执行
热门文章
- js加解密的算法
- Create Windows Server 2008 cluster from the command line
- [从hzwer神犇那翻到的模拟赛题] 合唱队形
- NEMA协议详解
- (转)python爬虫----(scrapy框架提高(1),自定义Request爬取)
- 如何防止Android反编译
- ubuntu启动脚本一览分析
- Spring整合Disruptor3
- ros结合catkin_make和qtcreator
- [BZOJ1834][ZJOI2010]network 网络扩容 最大流+费用流