Skip to content

Commit 33e2365

Browse files
fix: Fixed the issue of failing to update reverse proxy files (#7910)
1 parent 79ecd60 commit 33e2365

File tree

3 files changed

+18
-3
lines changed

3 files changed

+18
-3
lines changed

agent/app/service/website.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1810,7 +1810,7 @@ func (w WebsiteService) UpdateProxyFile(req request.NginxProxyUpdate) (err error
18101810
if err != nil {
18111811
return err
18121812
}
1813-
includePath := fmt.Sprintf("/www/sites/%s/proxy/%s.conf", website.Alias, req.Name)
1813+
includePath := fmt.Sprintf("%s/%s.conf", GetSitePath(website, SiteProxyDir), req.Name)
18141814
absolutePath := path.Join(nginxFull.Install.GetPath(), includePath)
18151815
fileOp := files.NewFileOp()
18161816
oldRewriteContent, err = fileOp.GetContent(absolutePath)

frontend/src/components/log-file/index.vue

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,9 @@ interface LogProps {
4646
tail?: boolean;
4747
taskID?: string;
4848
colorMode?: string;
49+
taskType?: string;
50+
taskOperate?: string;
51+
resourceID?: number;
4952
}
5053
5154
const props = defineProps({
@@ -57,6 +60,9 @@ const props = defineProps({
5760
name: '',
5861
tail: false,
5962
colorMode: 'nginx',
63+
taskType: '',
64+
taskOperate: '',
65+
resourceID: 0,
6066
}),
6167
},
6268
defaultButton: {
@@ -106,6 +112,9 @@ const readReq = reactive({
106112
pageSize: 500,
107113
latest: false,
108114
taskID: '',
115+
taskType: '',
116+
taskOperate: '',
117+
resourceID: 0,
109118
});
110119
const isLoading = ref(false);
111120
const end = ref(false);
@@ -182,6 +191,9 @@ const getContent = async (pre: boolean) => {
182191
readReq.type = props.config.type;
183192
readReq.name = props.config.name;
184193
readReq.taskID = props.config.taskID;
194+
readReq.taskType = props.config.taskType;
195+
readReq.taskOperate = props.config.taskOperate;
196+
readReq.resourceID = props.config.resourceID;
185197
if (readReq.page < 1) {
186198
readReq.page = 1;
187199
}

frontend/src/views/website/website/create/index.vue

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -554,6 +554,7 @@ import { v4 as uuidv4 } from 'uuid';
554554
import { dateFormatSimple, getProvider, getAccountName } from '@/utils/util';
555555
import { Website } from '@/api/interface/website';
556556
import DomainCreate from '@/views/website/website/domain-create/index.vue';
557+
import { getPathByType } from '@/api/modules/files';
557558
558559
const websiteForm = ref<FormInstance>();
559560
@@ -818,12 +819,14 @@ const getRuntimes = async () => {
818819
} catch (error) {}
819820
};
820821
821-
const acceptParams = async (installPath: string) => {
822+
const acceptParams = async () => {
822823
website.value = initData();
823824
if (websiteForm.value) {
824825
websiteForm.value.resetFields();
825826
}
826-
staticPath.value = installPath + '/www/sites/';
827+
getPathByType('websiteDir').then((res) => {
828+
staticPath.value = res.data + '/sites/';
829+
});
827830
828831
const res = await getGroupList('website');
829832
groups.value = res.data;

0 commit comments

Comments
 (0)