From 039ad74561bdcaa5fa2c0ad8de88a846a11755c0 Mon Sep 17 00:00:00 2001 From: TsMask <340112800@qq.com> Date: Tue, 10 Oct 2023 11:55:12 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=BC=80=E5=8F=91=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 18 +++++++++++++++++- restagent/{restconf.yaml => dev.yaml} | 2 +- 2 files changed, 18 insertions(+), 2 deletions(-) rename restagent/{restconf.yaml => dev.yaml} (99%) diff --git a/README.md b/README.md index 8c3dfa9..e174e17 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,19 @@ # ems_backend -后端 \ No newline at end of file +后端 + +```bash +cd /home/lichang/ems_backend +go mod download +cd restagent/ +# 打包命名 omcDevApp +go build -ldflags="-s -w" -o omcDevApp + +# 启动 +./omcDevApp -c dev.yaml + +nohup ./omcDevApp -c ./dev.yaml > ./dev.log 2>&1 & + +# 查找进程并杀死 +ps aux | grep omcDevApp | awk '{print $2}' | xargs kill +``` \ No newline at end of file diff --git a/restagent/restconf.yaml b/restagent/dev.yaml similarity index 99% rename from restagent/restconf.yaml rename to restagent/dev.yaml index dd342ad..eaa2491 100644 --- a/restagent/restconf.yaml +++ b/restagent/dev.yaml @@ -40,7 +40,7 @@ database: password: 1000omc@kp! host: "192.168.0.229" port: 33066 - name: omc_db + name: "omc_db_dev" backup: "../temp/database" # Redis 缓存数据,数据源声明全小写