Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change all 3009 to 3000 #24

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@ description: 我们推荐使用Docker+Nginx的安装方式

```shell
docker run -d --restart=always \
-p 3009:3000 \
-p 3000:3000 \
--name vocechat-server \
privoce/vocechat-server:latest
```

浏览器访问: `http://localhost:3009/`
浏览器访问: `http://localhost:3000/`

## 服务器部署

Expand All @@ -35,7 +35,7 @@ docker run -d --restart=always \

```shell
docker run -d --restart=always \
-p 3009:3000 \
-p 3000:3000 \
--name vocechat-server \
-v ~/.vocechat-server/data:/home/vocechat-server/data \
privoce/vocechat-server:latest \
Expand All @@ -57,7 +57,7 @@ docker run -d --restart=always \
server{
server_name vocechat.yourdomain.com;
location / {
proxy_pass http://127.0.0.1:3009; # 此处端口号取决于docker运行的对外端口号
proxy_pass http://127.0.0.1:3000; # 此处端口号取决于docker运行的对外端口号
proxy_redirect off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
Expand All @@ -79,7 +79,7 @@ server{

#### 配置 https

基本原理:让 Nginx 监听 443 端口,证书配置在 Nginx,通过 host 转发给 `vocechat-server:3009`,此时 vocechat-server 接受的依旧是 http。
基本原理:让 Nginx 监听 443 端口,证书配置在 Nginx,通过 host 转发给 `vocechat-server:3000`,此时 vocechat-server 接受的依旧是 http。

```
┌─────────┐ ┌─────────┐ ┌─────────┐
Expand Down Expand Up @@ -111,7 +111,7 @@ sudo certbot certonly --nginx
server{
server_name vocechat.yourdomain.com;
location / {
proxy_pass http://127.0.0.1:3009; # 此处端口号取决于docker运行的对外端口号
proxy_pass http://127.0.0.1:3000; # 此处端口号取决于docker运行的对外端口号
proxy_redirect off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
Expand Down Expand Up @@ -207,7 +207,7 @@ docker pull privoce/vocechat-server:latest

# 这里改为自己之前部署执行过的docker命令行
docker run -d --restart=always \
-p 3009:3000 \
-p 3000:3000 \
--name vocechat-server \
-v ~/.vocechat-server/data:/home/vocechat-server/data \
privoce/vocechat-server:latest \
Expand Down