From a28744b90755c3e5c1ab6e9e2270af01d0323ef0 Mon Sep 17 00:00:00 2001 From: zhengkunwang223 Date: Thu, 9 Mar 2023 18:27:10 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E8=A7=A3=E5=86=B3=E4=B8=A4=E4=B8=AA?= =?UTF-8?q?=E7=BD=91=E7=AB=99=E5=90=8C=E6=97=B6=E5=BC=80=E5=90=AF=E6=B5=81?= =?UTF-8?q?=E9=87=8F=E9=99=90=E5=88=B6=E6=8A=A5=E9=94=99=E7=9A=84BUG?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitignore | 1 + backend/app/dto/nginx.go | 3 +-- backend/app/service/nginx_utils.go | 3 --- cmd/server/nginx_conf/limit.conf | 2 -- cmd/server/nginx_conf/nginx_conf.go | 3 --- frontend/src/views/website/website/index.vue | 5 +++-- 6 files changed, 5 insertions(+), 12 deletions(-) delete mode 100644 cmd/server/nginx_conf/limit.conf diff --git a/.gitignore b/.gitignore index 39c52c06a..1a65a8daf 100644 --- a/.gitignore +++ b/.gitignore @@ -20,3 +20,4 @@ build backend/__debug_bin cmd/server/__debug_bin cmd/server/web +frontend/auto-imports.d.ts diff --git a/backend/app/dto/nginx.go b/backend/app/dto/nginx.go index b6b7b6730..dcfcffd62 100644 --- a/backend/app/dto/nginx.go +++ b/backend/app/dto/nginx.go @@ -46,6 +46,5 @@ var ScopeKeyMap = map[NginxKey][]string{ var StaticFileKeyMap = map[NginxKey]struct { }{ - SSL: {}, - LimitConn: {}, + SSL: {}, } diff --git a/backend/app/service/nginx_utils.go b/backend/app/service/nginx_utils.go index 9cb705d91..51156f6d4 100644 --- a/backend/app/service/nginx_utils.go +++ b/backend/app/service/nginx_utils.go @@ -160,9 +160,6 @@ func getNginxParamsFromStaticFile(scope dto.NginxKey, newParams []dto.NginxParam switch scope { case dto.SSL: newConfig = parser.NewStringParser(string(nginx_conf.SSL)).Parse() - case dto.LimitConn: - updateScope = constant.NginxScopeOut - newConfig = parser.NewStringParser(string(nginx_conf.Limit)).Parse() } for _, dir := range newConfig.GetDirectives() { addParam := dto.NginxParam{ diff --git a/cmd/server/nginx_conf/limit.conf b/cmd/server/nginx_conf/limit.conf deleted file mode 100644 index 2a755a006..000000000 --- a/cmd/server/nginx_conf/limit.conf +++ /dev/null @@ -1,2 +0,0 @@ -limit_conn_zone $binary_remote_addr zone=perip:10m; -limit_conn_zone $server_name zone=perserver:10m; \ No newline at end of file diff --git a/cmd/server/nginx_conf/nginx_conf.go b/cmd/server/nginx_conf/nginx_conf.go index eab723201..8f396ce51 100644 --- a/cmd/server/nginx_conf/nginx_conf.go +++ b/cmd/server/nginx_conf/nginx_conf.go @@ -10,8 +10,5 @@ var SSL []byte //go:embed website_default.conf var WebsiteDefault []byte -//go:embed limit.conf -var Limit []byte - //go:embed index.html var Index []byte diff --git a/frontend/src/views/website/website/index.vue b/frontend/src/views/website/website/index.vue index e89255052..369b51e9b 100644 --- a/frontend/src/views/website/website/index.vue +++ b/frontend/src/views/website/website/index.vue @@ -94,11 +94,12 @@ v-if="row.status === 'Running'" link type="success" + :icon="VideoPlay" @click="opWebsite('stop', row.id)" > {{ $t('commons.status.running') }} - + {{ $t('commons.status.stopped') }} @@ -185,7 +186,7 @@ import { ElMessageBox } from 'element-plus'; import { dateFormatSimple } from '@/utils/util'; import { MsgSuccess } from '@/utils/message'; import { useI18n } from 'vue-i18n'; -import { Promotion } from '@element-plus/icons-vue'; +import { Promotion, VideoPlay, VideoPause } from '@element-plus/icons-vue'; const shortcuts = [ {