From ea7dfb245a8c629563b09cfbea0dd81156ddd4f3 Mon Sep 17 00:00:00 2001 From: myface-wang <240298530@qq.com> Date: Tue, 7 Nov 2023 16:20:46 +0800 Subject: [PATCH 1/4] Update gorm.md MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit qgsql修正为pgsql --- docs/guide/server/gorm.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/guide/server/gorm.md b/docs/guide/server/gorm.md index 4bd830b..6ec98cd 100644 --- a/docs/guide/server/gorm.md +++ b/docs/guide/server/gorm.md @@ -51,7 +51,7 @@ type Pgsql struct { ### server/config/config.go -### 在system选项下 选择db-type为mysql或者qgsql +### 在system选项下 选择db-type为mysql或者pgsql ```yaml system: From 9ee379d80528a98ab66a832197a791428af6f4c4 Mon Sep 17 00:00:00 2001 From: Neal Caffery Date: Sun, 3 Dec 2023 12:51:09 +0800 Subject: [PATCH 2/4] Update docker_develop.md --- docs/guide/deployment/docker_develop.md | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/docs/guide/deployment/docker_develop.md b/docs/guide/deployment/docker_develop.md index 42479de..dc30a2f 100644 --- a/docs/guide/deployment/docker_develop.md +++ b/docs/guide/deployment/docker_develop.md @@ -2,10 +2,8 @@ ## Docker & Docker-compose 环境 -1. 前往[https://hub.docker.com]([Docker Desktop for Windows by Docker | Docker Hub](https://hub.docker.com/editions/community/docker-ce-desktop-windows/))下载最新版本 Docker -2. 前往[https://github.com]([Release v2.3.3 · docker/compose (github.com)](https://github.com/docker/compose/releases/tag/v2.3.3))下载最新版本 Docker-Compose - - +1. 前往 [Docker Desktop for Windows by Docker | Docker Hub](https://hub.docker.com/editions/community/docker-ce-desktop-windows/)下载最新版本 Docker +2. 前往 [Release v2.3.3 · docker/compose (github.com)](https://github.com/docker/compose/releases/tag/v2.3.3)下载最新版本 Docker-Compose ## 一、要使用docker快速开发,需要进行两处项目文件修改 From 0e3b2a37f007a64d5dc6e61c966683804dcb546c Mon Sep 17 00:00:00 2001 From: spiritsoul <97792170+spiritysdx@users.noreply.github.com> Date: Mon, 11 Mar 2024 11:27:09 +0800 Subject: [PATCH 3/4] Update index.md --- docs/guide/deployment/index.md | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/docs/guide/deployment/index.md b/docs/guide/deployment/index.md index fae2a74..19ed981 100644 --- a/docs/guide/deployment/index.md +++ b/docs/guide/deployment/index.md @@ -5,6 +5,7 @@ 在web目录下执行 npm run build 得到 dist文件夹 将dist文件夹上传到服务器 建议使用nginx进行代理 并且设置 proxy 把请求代理到后端 ## 后端 + 在 server下 go build . 得到一个可执行文件然后将可执行文件和config.yaml 以及 resource 文件夹上传至服务器 三者最好放在同一路径下 最终服务器目录结构可能如下 ``` @@ -22,7 +23,6 @@ ``` - ## [Tips.] Nginx的配置(如果用的话) 代码参考如下 @@ -33,7 +33,9 @@ location /api { proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto $scheme; - rewrite ^/api/(.*)$ /$1 break; #重写 - proxy_pass 后端地址; # 设置代理服务器的协议和地址 + rewrite ^/api/(.*)$ /$1 break; #重写 + proxy_pass 后端地址; # 设置代理服务器的协议和地址 } ``` + +后端地址未作修改时默认为```http://127.0.0.1:8888``` From 59890ce6a0494ee1c6c914c742bab53992ade89d Mon Sep 17 00:00:00 2001 From: "Shenzhen Miaodian Technology Co., Ltd" Date: Sat, 30 Mar 2024 09:10:39 +0800 Subject: [PATCH 4/4] Update vscode.md --- docs/guide/start-quickly/vscode.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/docs/guide/start-quickly/vscode.md b/docs/guide/start-quickly/vscode.md index 0af61b6..c40a88d 100644 --- a/docs/guide/start-quickly/vscode.md +++ b/docs/guide/start-quickly/vscode.md @@ -11,13 +11,18 @@ title: 使用VSCode开发 #### 2.4.2 运行/调试 +需要先安装 vscode 插件中的 go 插件。 + 在运行和调试中也可以看到三个task:`Backend`、`Frontend`、`Both (Backend & Frontend)`。运行`Both (Backend & Frontend)`可以同时启动前后端项目。 #### 2.4.3 settings +其它配置 +以下为非必须, 当你的 go 不在系统环境变量中时, 不能找到,你可能需要配置如下内容。 + 在工作区配置文件中有`go.toolsEnvVars`字段,是用于`VSCode`自身的go工具环境变量。此外在多go版本的系统中,可以通过`gopath`、`go.goroot`指定运行版本。 ```json "go.gopath": null, "go.goroot": null, -``` \ No newline at end of file +```