mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2024-11-27 20:49:03 +08:00
feat: 优化应用启动 (#6193)
This commit is contained in:
parent
37df602ae8
commit
6dec845848
@ -33,6 +33,7 @@ type WebsiteRes struct {
|
||||
SSLStatus string `json:"sslStatus"`
|
||||
AppInstallID uint `json:"appInstallId"`
|
||||
ChildSites []string `json:"childSites"`
|
||||
RuntimeType string `json:"runtimeType"`
|
||||
}
|
||||
|
||||
type WebsiteOption struct {
|
||||
|
@ -255,7 +255,7 @@ func (a *AppInstallService) Operate(req request.AppInstalledOperate) error {
|
||||
case constant.Rebuild:
|
||||
return rebuildApp(install)
|
||||
case constant.Start:
|
||||
out, err := compose.Start(dockerComposePath)
|
||||
out, err := compose.Up(dockerComposePath)
|
||||
if err != nil {
|
||||
return handleErr(install, err, out)
|
||||
}
|
||||
|
@ -159,6 +159,7 @@ func (w WebsiteService) PageWebsite(req request.WebsiteSearch) (int64, []respons
|
||||
var (
|
||||
appName string
|
||||
runtimeName string
|
||||
runtimeType string
|
||||
appInstallID uint
|
||||
)
|
||||
switch web.Type {
|
||||
@ -175,6 +176,7 @@ func (w WebsiteService) PageWebsite(req request.WebsiteSearch) (int64, []respons
|
||||
return 0, nil, err
|
||||
}
|
||||
runtimeName = runtime.Name
|
||||
runtimeType = runtime.Type
|
||||
appInstallID = runtime.ID
|
||||
}
|
||||
sitePath := path.Join(constant.AppInstallDir, constant.AppOpenresty, nginxInstall.Name, "www", "sites", web.Alias)
|
||||
@ -195,6 +197,7 @@ func (w WebsiteService) PageWebsite(req request.WebsiteSearch) (int64, []respons
|
||||
RuntimeName: runtimeName,
|
||||
SitePath: sitePath,
|
||||
AppInstallID: appInstallID,
|
||||
RuntimeType: runtimeType,
|
||||
}
|
||||
|
||||
sites, _ := websiteRepo.List(websiteRepo.WithParentID(web.ID))
|
||||
|
@ -32,6 +32,7 @@ export namespace Website {
|
||||
sitePath: string;
|
||||
appName: string;
|
||||
runtimeName: string;
|
||||
runtimeType: string;
|
||||
}
|
||||
export interface WebsiteRes extends CommonModel {
|
||||
protocol: string;
|
||||
|
@ -87,7 +87,7 @@ const handleClose = () => {
|
||||
em('close', false);
|
||||
};
|
||||
|
||||
const acceptParams = async (website: Website.Website) => {
|
||||
const acceptParams = async (website: Website.WebsiteDTO) => {
|
||||
deleteReq.value = {
|
||||
id: 0,
|
||||
deleteApp: false,
|
||||
|
@ -188,6 +188,7 @@
|
||||
<el-tag v-if="row.protocol == 'HTTPS'" :type="row.sslStatus">
|
||||
{{ dateFormatSimple(row.sslExpireDate) }}
|
||||
</el-tag>
|
||||
<span v-else></span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<fu-table-operations
|
||||
|
Loading…
Reference in New Issue
Block a user