Pastebin 在线剪贴板部署

Pastebin 在线剪贴板部署

https://github.com/Nugine/pastebin 加Star,赞

设置nginx代理

修改默认nginx配置文件default为

server {
listen 80;

server_name "pastebin";

gzip on;
gzip_comp_level 4;
gzip_types application/javascript text/css application/json;
gzip_vary on;
gzip_static on;

location / {
proxy_pass http://localhost:3000;
}

location /api/ {
proxy_pass http://localhost:8000;
}
}

启动后端

进入pastebin-server目录后

nohup cargo +nightly run &

需要 Nightly 工具链

启动前端

进入pastebin-front目录后

screen -dmS pastebin npm run dev