mirror of
https://gitee.com/dromara/Jpom.git
synced 2024-12-02 11:58:01 +08:00
i18n: pages/docker
This commit is contained in:
parent
eae489e2e5
commit
1a9386904a
@ -1 +1 @@
|
||||
JPOM_PROXY_HOST="127.0.0.1:2122"
|
||||
JPOM_PROXY_HOST="https://demo.jpom.top"
|
||||
|
@ -12,11 +12,13 @@ import page404 from './pages/404/404'
|
||||
import build from './pages/build'
|
||||
import certificate from './pages/certificate'
|
||||
import dispatch from './pages/dispatch'
|
||||
import docker from './pages/docker'
|
||||
export default {
|
||||
pages: {
|
||||
404: page404,
|
||||
build,
|
||||
certificate,
|
||||
dispatch
|
||||
dispatch,
|
||||
docker
|
||||
}
|
||||
}
|
||||
|
@ -63,54 +63,6 @@ export default {
|
||||
containerLabelExample: 'Container labels, such as: key1=values1&keyvalue2',
|
||||
autoStart: 'Auto Start',
|
||||
start: 'Start',
|
||||
port_1: 'Port',
|
||||
container_1: 'Container',
|
||||
rebuildContainer_1: 'Rebuild Container',
|
||||
operationPrompt_1: 'Operation Prompt',
|
||||
containerRebuildDesc_1:
|
||||
'Container rebuild refers to creating an identical container using the already created container parameters.',
|
||||
containerRestartDeleteBefore_1: 'Before restarting, the previous container will be automatically deleted.',
|
||||
containerDataBackupWarning_1:
|
||||
'If the container data directory is not mounted, please backup the data before using this feature.',
|
||||
newContainerParamNotGuaranteed_1:
|
||||
'This feature cannot guarantee that the new container and the previous container parameters are exactly the same. Please use it carefully.',
|
||||
baseImage_1: 'Base Image',
|
||||
containerName_1: 'Container Name:',
|
||||
hostIp_1: 'Host IP',
|
||||
containerPort_1: 'Container Port',
|
||||
portProtocol_1: 'Port Protocol',
|
||||
mountedVolume_1: 'Mounted Volume',
|
||||
host_1: 'Host',
|
||||
hostDirectory_1: 'Host Directory',
|
||||
containerDirectory_1: 'Container Directory',
|
||||
environmentVariables_1: 'Environment Variables',
|
||||
variableName_1: 'Variable Name',
|
||||
variableValue_1: 'Variable Value',
|
||||
command_1: 'Command',
|
||||
commandValue_1: 'Command Value',
|
||||
fillRunningCommand_1: 'Fill in the running command',
|
||||
hostname_1: 'Hostname',
|
||||
network_1: 'Network',
|
||||
networkMode_1: 'Network Mode: bridge, container:<name|id>, host, container, none',
|
||||
createNetworkStack_1: 'Create a new network stack for containers on docker bridge',
|
||||
containerNoNetwork_1: 'This container has no network',
|
||||
reuseAnotherContainerNetworkStack_1: "Reuse another container's network stack",
|
||||
useHostNetworkStack_1:
|
||||
'Use the host network stack inside the container. Note: Host mode grants containers full access to local system services (such as D-bus), so it is considered insecure.',
|
||||
restartPolicy_1: 'Restart Policy',
|
||||
restartPolicyOptions_1: 'Restart Policy: no, always, unless-stopped, on-failure',
|
||||
noAutoRestart_1: 'Do not automatically restart',
|
||||
alwaysRestart_1: 'Always restart the container regardless of the exit code.',
|
||||
restartOnFailure_1:
|
||||
'Restart the container if it exits with a non-zero exit code. You can specify the number of times: on-failure:2',
|
||||
restartUnlessStopped_1: 'Restart the container unless it has been stopped',
|
||||
storageOptions_1: 'Storage Options',
|
||||
configName_1: 'Configuration Name (e.g., size)',
|
||||
configValue_1: 'Configuration Value (e.g., 5g)',
|
||||
containerRuntime_1: 'Container Runtime',
|
||||
containerLabels_1: 'Container Labels',
|
||||
containerLabelExample_1: 'Container labels, e.g., key1=values1&keyvalue2',
|
||||
autoStart_1: 'Auto Start',
|
||||
start_1: 'Start'
|
||||
noStart: 'No Start'
|
||||
}
|
||||
}
|
||||
|
@ -2,107 +2,53 @@ export default {
|
||||
c: {
|
||||
name: 'Name',
|
||||
containerName: 'Container Name',
|
||||
tag: 'Tag',
|
||||
pleaseSelectWorkspace: 'Please select workspace',
|
||||
tagLimitToAlphaNumericWithLength1To10: 'Tags are limited to alphanumeric with a length of 1-10',
|
||||
name_1: 'Name',
|
||||
containerName_1: 'Container Name',
|
||||
tag_1: 'Tag',
|
||||
pleaseSelectWorkspace_1: 'Please select workspace',
|
||||
tagLimitToAlphaNumericWithLength1To10_11: 'Tag is limited to alphanumeric with length 1-10'
|
||||
label: 'Label',
|
||||
selectWorkspace: 'Please select a workspace',
|
||||
labelRestriction: 'Label is restricted to alphanumeric characters with a length of 1-10'
|
||||
},
|
||||
p: {
|
||||
currentWorkspaceDoesNotHaveDocker: 'The current workspace does not have Docker',
|
||||
pleaseGoToSystemManagementAssetManagementDockerManagementToAddDockerOrAuthorizeAndAssignAnExistingDockerToThisWorkspace:
|
||||
'Please go to [System Management] -> [Asset Management] -> [Docker Management] to add a new Docker, or authorize and associate an existing Docker with this workspace',
|
||||
goNow: 'Go now',
|
||||
noDockerInWorkspace: 'There is no Docker in the current workspace',
|
||||
goToDockerManagement:
|
||||
'Please go to [System Management] -> [Asset Management] -> [Docker Management] to add a new Docker, or authorize and associate an existing Docker to this workspace',
|
||||
goToNow: 'Go now',
|
||||
noDocker: 'No Docker',
|
||||
pressCtrOrAltOptionToQuicklyReturnToTheFirstPage:
|
||||
'Press Ctr or Alt/Option and click the button to quickly return to the first page',
|
||||
quickReturn: 'Hold Ctrl or Alt/Option key and click the button to quickly return to the first page',
|
||||
search: 'Search',
|
||||
workspaceSynchronization: 'Workspace Synchronization',
|
||||
normal: 'Normal',
|
||||
workspaceSync: 'Workspace synchronization',
|
||||
statusNormal: 'Normal',
|
||||
unableToConnect: 'Unable to connect',
|
||||
clusterAssociatedDockerInfoIsLostCannotContinueToUseManagementFunctions:
|
||||
'The cluster-associated Docker information is lost, and management functions cannot be used',
|
||||
dockerInfoLost:
|
||||
'The associated Docker information for the cluster is lost and cannot continue to use management functions',
|
||||
infoLost: 'Information lost',
|
||||
console: 'Console',
|
||||
edit: 'Edit',
|
||||
delete: 'Delete',
|
||||
editDocker: 'Edit Docker',
|
||||
tagIsUsedForContainerBuildingToSelectContainerFunctionFromTag:
|
||||
'Tags are used for container building to select container functions (fromTag)',
|
||||
pleaseEnterTagNameAlphaNumericWithLength1To10:
|
||||
'Please enter a tag name with alphanumeric characters and a length of 1-10',
|
||||
tagForContainerBuild: 'Tag is used for container build selection (fromTag)',
|
||||
enterTagName: 'Please enter a tag name with alphanumeric characters with a length of 1-10',
|
||||
add: 'Add',
|
||||
synchronizeToOtherWorkspaces: 'Synchronize to other workspaces',
|
||||
warmPrompt: 'Warm prompt',
|
||||
synchronizationMechanismDeterminesThatTheContainerHostIsTheSameServerDocker:
|
||||
'The synchronization mechanism determines that the container host is the same server (Docker)',
|
||||
whenTheTargetWorkspaceDoesNotExistACorrespondingNodeItWillBeAutomaticallyCreatedADockerLogicDocker:
|
||||
'When the target workspace does not exist, a corresponding node will be automatically created, and a new Docker (logical Docker) will be created',
|
||||
whenTheTargetWorkspaceAlreadyExistsANodeItWillBeAutomaticallySynchronizedDockerRepositoryConfigurationInformation:
|
||||
'When the target workspace already exists, a node will be automatically synchronized, and Docker repository configuration information will be synchronized',
|
||||
selectWorkspace: 'Select workspace',
|
||||
syncToOtherWorkspace: 'Synchronize to other workspaces',
|
||||
warmTip: 'Friendly reminder',
|
||||
syncMechanism:
|
||||
'The synchronization mechanism determines that it is the same server (Docker) using the container host',
|
||||
createNewDocker:
|
||||
'When the target workspace does not have a corresponding node, a new Docker (logical Docker) will be automatically created',
|
||||
syncDockerInfo:
|
||||
'When the target workspace already has a node, the Docker repository configuration information will be automatically synchronized',
|
||||
chooseWorkspace: 'Choose workspace',
|
||||
status: 'Status',
|
||||
version: 'Version',
|
||||
lastModifier: 'Last modifier',
|
||||
lastModifiedBy: 'Last modified by',
|
||||
creationTime: 'Creation time',
|
||||
modificationTime: 'Modification time',
|
||||
operation: 'Operation',
|
||||
pleaseFillInTheContainerName: 'Please fill in the container name',
|
||||
pleaseFillInTheContainerAddress: 'Please fill in the container address',
|
||||
pleaseFillInTheAssociatedContainerTag: 'Please fill in the associated container tag',
|
||||
action: 'Action',
|
||||
enterContainerName: 'Please enter a container name',
|
||||
enterContainerAddress: 'Please enter a container address',
|
||||
enterAssociatedContainerTag: 'Please enter an associated container tag',
|
||||
systemPrompt: 'System prompt',
|
||||
areYouSureYouWantToDeleteThisRecordAfterDeletionTheAssociatedContainerTagWillBeUnavailableForBuilding:
|
||||
'Are you sure you want to delete this record? After deletion, the associated container tag will be unavailable for building',
|
||||
confirmDeletion:
|
||||
'Are you sure you want to delete this record? After deletion, the associated container tag for the build will no longer be usable',
|
||||
confirm: 'Confirm',
|
||||
cancel: 'Cancel',
|
||||
currentWorkspaceDoesNotHaveDocker_1: 'The current workspace does not have Docker',
|
||||
pleaseGoToSystemManagementAssetManagementDockerManagementToAddDockerOrAuthorizeAndAssignAnExistingDockerToThisWorkspace_1:
|
||||
'Please go to [System Management] -> [Asset Management] -> [Docker Management] to add a new Docker, or authorize and assign an existing Docker to this workspace',
|
||||
goNow_1: 'Go now',
|
||||
noDocker_1: 'No Docker',
|
||||
pressCtrOrAltOptionToQuicklyReturnToTheFirstPage_1:
|
||||
'Press Ctr or Alt/Option and click the button to quickly return to the first page',
|
||||
search_1: 'Search',
|
||||
workspaceSynchronization_1: 'Workspace Synchronization',
|
||||
normal_1: 'Normal',
|
||||
unableToConnect_1: 'Unable to connect',
|
||||
clusterAssociatedDockerInfoIsLostCannotContinueToUseManagementFunctions_1:
|
||||
'The cluster-associated Docker information is lost, and management functions cannot be used',
|
||||
infoLost_1: 'Information lost',
|
||||
console_1: 'Console',
|
||||
edit_1: 'Edit',
|
||||
delete_1: 'Delete',
|
||||
editDocker_1: 'Edit Docker',
|
||||
tagIsUsedForContainerBuildingToSelectContainerFunctionFromTag_1:
|
||||
'The tag is used for container building to select container function (fromTag)',
|
||||
pleaseEnterTagNameAlphaNumericWithLength1To10_11:
|
||||
'Please enter a tag name with alphanumeric characters and a length of 1-10',
|
||||
add_1: 'Add',
|
||||
synchronizeToOtherWorkspaces_1: 'Synchronize to other workspaces',
|
||||
warmPrompt_1: 'Warm prompt',
|
||||
synchronizationMechanismDeterminesThatTheContainerHostIsTheSameServerDocker_1:
|
||||
'The synchronization mechanism determines that the container host is the same server (Docker)',
|
||||
whenTheTargetWorkspaceDoesNotExistACorrespondingNodeItWillBeAutomaticallyCreatedADockerLogicDocker_1:
|
||||
'When the target workspace does not exist, a corresponding node will be automatically created (a logical Docker)',
|
||||
whenTheTargetWorkspaceAlreadyExistsANodeItWillBeAutomaticallySynchronizedDockerRepositoryConfigurationInformation_1:
|
||||
'When the target workspace already exists, a node will be automatically synchronized with the Docker repository configuration information',
|
||||
selectWorkspace_1: 'Select workspace',
|
||||
status_1: 'Status',
|
||||
version_1: 'Version',
|
||||
lastModifier_1: 'Last modifier',
|
||||
creationTime_1: 'Creation time',
|
||||
modificationTime_1: 'Modification time',
|
||||
operation_1: 'Operation',
|
||||
pleaseFillInTheContainerName_1: 'Please fill in the container name',
|
||||
pleaseFillInTheContainerAddress_1: 'Please fill in the container address',
|
||||
pleaseFillInTheAssociatedContainerTag_1: 'Please fill in the associated container tag',
|
||||
systemPrompt_1: 'System prompt',
|
||||
areYouSureYouWantToDeleteThisRecordAfterDeletionTheAssociatedContainerTagWillBeUnavailableForBuilding_1:
|
||||
'Are you sure you want to delete this record? After deletion, the associated container tag will be unavailable for building',
|
||||
confirm_1: 'Confirm',
|
||||
cancel_1: 'Cancel'
|
||||
cancel: 'Cancel'
|
||||
}
|
||||
}
|
||||
|
@ -58,6 +58,7 @@ export default {
|
||||
containerLabels: '容器标签',
|
||||
containerLabelExample: '容器标签,如:key1=values1&keyvalue2',
|
||||
autoStart: '自动启动',
|
||||
start: '启动'
|
||||
start: '启动',
|
||||
noStart: '未启动'
|
||||
}
|
||||
}
|
||||
|
@ -2,52 +2,47 @@ export default {
|
||||
c: {
|
||||
name: '名称',
|
||||
containerName: '容器名称',
|
||||
tag: '标签',
|
||||
pleaseSelectWorkspace: '请选择工作空间',
|
||||
tagLimitToAlphaNumericWithLength1To10: '标签限制为字母数字且长度 1-10'
|
||||
label: '标签',
|
||||
selectWorkspace: '请选择工作空间',
|
||||
labelRestriction: '标签限制为字母数字且长度 1-10'
|
||||
},
|
||||
p: {
|
||||
currentWorkspaceDoesNotHaveDocker: '当前工作空间还没有 Docker',
|
||||
pleaseGoToSystemManagementAssetManagementDockerManagementToAddDockerOrAuthorizeAndAssignAnExistingDockerToThisWorkspace:
|
||||
noDockerInWorkspace: '当前工作空间还没有 Docker',
|
||||
goToDockerManagement:
|
||||
'请到【系统管理】-> 【资产管理】-> 【Docker管理】新增Docker,或者将已新增的Docker授权关联、分配到此工作空间',
|
||||
goNow: '现在就去',
|
||||
goToNow: '现在就去',
|
||||
noDocker: '没有docker',
|
||||
pressCtrOrAltOptionToQuicklyReturnToTheFirstPage: '按住 Ctr 或者 Alt/Option 键点击按钮快速回到第一页',
|
||||
quickReturn: '按住 Ctr 或者 Alt/Option 键点击按钮快速回到第一页',
|
||||
search: '搜索',
|
||||
workspaceSynchronization: '工作空间同步',
|
||||
normal: '正常',
|
||||
workspaceSync: '工作空间同步',
|
||||
statusNormal: '正常',
|
||||
unableToConnect: '无法连接',
|
||||
clusterAssociatedDockerInfoIsLostCannotContinueToUseManagementFunctions:
|
||||
'集群关联的 docker 信息丢失,不能继续使用管理功能',
|
||||
dockerInfoLost: '集群关联的 docker 信息丢失,不能继续使用管理功能',
|
||||
infoLost: '信息丢失',
|
||||
console: '控制台',
|
||||
edit: '编辑',
|
||||
delete: '删除',
|
||||
editDocker: '编辑 Docker',
|
||||
tagIsUsedForContainerBuildingToSelectContainerFunctionFromTag: '标签用于容器构建选择容器功能(fromTag)',
|
||||
pleaseEnterTagNameAlphaNumericWithLength1To10: '请输入标签名 字母数字 长度 1-10',
|
||||
tagForContainerBuild: '标签用于容器构建选择容器功能(fromTag)',
|
||||
enterTagName: '请输入标签名 字母数字 长度 1-10',
|
||||
add: '新增',
|
||||
synchronizeToOtherWorkspaces: '同步到其他工作空间',
|
||||
warmPrompt: '温馨提示',
|
||||
synchronizationMechanismDeterminesThatTheContainerHostIsTheSameServerDocker:
|
||||
'同步机制采用容器 host 确定是同一个服务器(docker)',
|
||||
whenTheTargetWorkspaceDoesNotExistACorrespondingNodeItWillBeAutomaticallyCreatedADockerLogicDocker:
|
||||
'当目标工作空间不存在对应的节点时候将自动创建一个新的docker(逻辑docker)',
|
||||
whenTheTargetWorkspaceAlreadyExistsANodeItWillBeAutomaticallySynchronizedDockerRepositoryConfigurationInformation:
|
||||
'当目标工作空间已经存在节点时候将自动同步 docker 仓库配置信息',
|
||||
selectWorkspace: '选择工作空间',
|
||||
syncToOtherWorkspace: '同步到其他工作空间',
|
||||
warmTip: '温馨提示',
|
||||
syncMechanism: '同步机制采用容器 host 确定是同一个服务器(docker)',
|
||||
createNewDocker: '当目标工作空间不存在对应的节点时候将自动创建一个新的docker(逻辑docker)',
|
||||
syncDockerInfo: '当目标工作空间已经存在节点时候将自动同步 docker 仓库配置信息',
|
||||
chooseWorkspace: '选择工作空间',
|
||||
status: '状态',
|
||||
version: '版本',
|
||||
lastModifier: '最后修改人',
|
||||
lastModifiedBy: '最后修改人',
|
||||
creationTime: '创建时间',
|
||||
modificationTime: '修改时间',
|
||||
operation: '操作',
|
||||
pleaseFillInTheContainerName: '请填写容器名称',
|
||||
pleaseFillInTheContainerAddress: '请填写容器地址',
|
||||
pleaseFillInTheAssociatedContainerTag: '请填写关联容器标签',
|
||||
action: '操作',
|
||||
enterContainerName: '请填写容器名称',
|
||||
enterContainerAddress: '请填写容器地址',
|
||||
enterAssociatedContainerTag: '请填写关联容器标签',
|
||||
systemPrompt: '系统提示',
|
||||
areYouSureYouWantToDeleteThisRecordAfterDeletionTheAssociatedContainerTagWillBeUnavailableForBuilding:
|
||||
'真的要删除该记录么?删除后构建关联的容器标签将无法使用',
|
||||
confirmDeletion: '真的要删除该记录么?删除后构建关联的容器标签将无法使用',
|
||||
confirm: '确认',
|
||||
cancel: '取消'
|
||||
}
|
||||
|
@ -44,13 +44,16 @@
|
||||
<a-button type="primary" size="small" :loading="childLoading" @click="loadData">{{
|
||||
$tl('p.refresh')
|
||||
}}</a-button>
|
||||
|
||||
<a-statistic-countdown
|
||||
format=" {{$tl('p.seconds')}}"
|
||||
format="s"
|
||||
:title="$tl('p.refreshCountdown')"
|
||||
:value="countdownTime"
|
||||
@finish="silenceLoadData"
|
||||
/>
|
||||
>
|
||||
<template #suffix>
|
||||
<div style="font-size: 12px">{{ $tl('p.seconds') }}</div>
|
||||
</template>
|
||||
</a-statistic-countdown>
|
||||
</a-space>
|
||||
</template>
|
||||
<template #bodyCell="{ column, text, record }">
|
||||
|
@ -333,7 +333,7 @@
|
||||
><a-switch
|
||||
v-model:checked="temp.autorun"
|
||||
:checked-children="$tl('p.start')"
|
||||
un-checked-children="不{{$tl('p.start')}}"
|
||||
:un-checked-children="$tl('p.noStart')"
|
||||
/></a-col>
|
||||
<a-col :span="4" style="text-align: right">
|
||||
<a-tooltip>
|
||||
|
@ -42,11 +42,15 @@
|
||||
</div>
|
||||
<a-button type="primary" :loading="loading" @click="loadData">{{ $tl('c.search') }}</a-button>
|
||||
<a-statistic-countdown
|
||||
format=" {{$tl('c.seconds')}}"
|
||||
:title="$tl('c.refreshCountdown')"
|
||||
format="s"
|
||||
:title="$tl('c.refreshCountdown') + ' '"
|
||||
:value="countdownTime"
|
||||
@finish="autoUpdate"
|
||||
/>
|
||||
>
|
||||
<template #suffix>
|
||||
<div style="font-size: 12px">{{ $tl('c.seconds') }}</div>
|
||||
</template>
|
||||
</a-statistic-countdown>
|
||||
</a-space>
|
||||
</template>
|
||||
<template #bodyCell="{ column, text, record }">
|
||||
@ -310,11 +314,15 @@
|
||||
</div>
|
||||
<a-button type="primary" :loading="loading" @click="loadData">{{ $tl('c.search') }}</a-button>
|
||||
<a-statistic-countdown
|
||||
format=" {{$tl('c.seconds')}}"
|
||||
:title="$tl('c.refreshCountdown')"
|
||||
format="s"
|
||||
:title="$tl('c.refreshCountdown') + ' '"
|
||||
:value="countdownTime"
|
||||
@finish="autoUpdate"
|
||||
/>
|
||||
>
|
||||
<template #suffix>
|
||||
<div style="font-size: 12px">{{ $tl('c.seconds') }}</div>
|
||||
</template>
|
||||
</a-statistic-countdown>
|
||||
</a-space>
|
||||
</template>
|
||||
<a-collapse v-if="list && list.length">
|
||||
|
@ -1,13 +1,10 @@
|
||||
<template>
|
||||
<div>
|
||||
<template v-if="useSuggestions">
|
||||
<a-result
|
||||
title="当前工作空间还没有 Docker"
|
||||
sub-title="请到【系统管理】-> 【资产管理】-> 【Docker管理】新增Docker,或者将已新增的Docker授权关联、分配到此工作空间"
|
||||
>
|
||||
<a-result :title="$tl('p.noDockerInWorkspace')" :sub-title="$tl('p.goToDockerManagement')">
|
||||
<template #extra>
|
||||
<router-link to="/system/assets/docker-list">
|
||||
<a-button key="console" type="primary">现在就去</a-button></router-link
|
||||
<a-button key="console" type="primary">{{ $tl('p.goToNow') }}</a-button></router-link
|
||||
>
|
||||
</template>
|
||||
</a-result>
|
||||
@ -19,7 +16,7 @@
|
||||
default-auto-refresh
|
||||
:auto-refresh-time="5"
|
||||
table-name="docker-list"
|
||||
empty-description="没有docker"
|
||||
:empty-description="$tl('p.noDocker')"
|
||||
:active-page="activePage"
|
||||
size="middle"
|
||||
:data-source="list"
|
||||
@ -38,16 +35,19 @@
|
||||
<a-space wrap class="search-box">
|
||||
<a-input
|
||||
v-model:value="listQuery['%name%']"
|
||||
placeholder="名称"
|
||||
:placeholder="$tl('c.name')"
|
||||
class="search-input-item"
|
||||
@press-enter="loadData"
|
||||
/>
|
||||
|
||||
<a-tooltip title="按住 Ctr 或者 Alt/Option 键点击按钮快速回到第一页">
|
||||
<a-button type="primary" :loading="loading" @click="loadData">搜索</a-button>
|
||||
<a-tooltip :title="$tl('p.quickReturn')">
|
||||
<a-button type="primary" :loading="loading" @click="loadData">{{ $tl('p.search') }}</a-button>
|
||||
</a-tooltip>
|
||||
<a-button type="primary" :disabled="!tableSelections || !tableSelections.length" @click="syncToWorkspaceShow"
|
||||
>工作空间同步</a-button
|
||||
<a-button
|
||||
type="primary"
|
||||
:disabled="!tableSelections || !tableSelections.length"
|
||||
@click="syncToWorkspaceShow"
|
||||
>{{ $tl('p.workspaceSync') }}</a-button
|
||||
>
|
||||
</a-space>
|
||||
</template>
|
||||
@ -60,14 +60,14 @@
|
||||
|
||||
<template v-else-if="column.dataIndex instanceof Array && column.dataIndex.includes('status')">
|
||||
<template v-if="record.machineDocker">
|
||||
<a-tag v-if="record.machineDocker.status === 1" color="green">正常</a-tag>
|
||||
<a-tag v-if="record.machineDocker.status === 1" color="green">{{ $tl('p.statusNormal') }}</a-tag>
|
||||
<a-tooltip v-else :title="record.machineDocker.failureMsg">
|
||||
<a-tag color="red">无法连接</a-tag>
|
||||
<a-tag color="red">{{ $tl('p.unableToConnect') }}</a-tag>
|
||||
</a-tooltip>
|
||||
</template>
|
||||
|
||||
<a-tooltip v-else title="集群关联的 docker 信息丢失,不能继续使用管理功能">
|
||||
<a-tag color="red">信息丢失</a-tag>
|
||||
<a-tooltip v-else :title="$tl('p.dockerInfoLost')">
|
||||
<a-tag color="red">{{ $tl('p.infoLost') }}</a-tag>
|
||||
</a-tooltip>
|
||||
</template>
|
||||
<template v-else-if="column.dataIndex === 'tags'">
|
||||
@ -89,10 +89,10 @@
|
||||
type="primary"
|
||||
:disabled="!record.machineDocker || record.machineDocker.status !== 1"
|
||||
@click="handleConsole(record)"
|
||||
>控制台</a-button
|
||||
>{{ $tl('p.console') }}</a-button
|
||||
>
|
||||
<a-button size="small" type="primary" @click="handleEdit(record)">编辑</a-button>
|
||||
<a-button size="small" type="primary" danger @click="handleDelete(record)">删除</a-button>
|
||||
<a-button size="small" type="primary" @click="handleEdit(record)">{{ $tl('p.edit') }}</a-button>
|
||||
<a-button size="small" type="primary" danger @click="handleDelete(record)">{{ $tl('p.delete') }}</a-button>
|
||||
</a-space>
|
||||
</template>
|
||||
</template>
|
||||
@ -102,16 +102,20 @@
|
||||
v-model:open="editVisible"
|
||||
destroy-on-close
|
||||
:confirm-loading="confirmLoading"
|
||||
title="编辑 Docker"
|
||||
:title="$tl('p.editDocker')"
|
||||
:mask-closable="false"
|
||||
@ok="handleEditOk"
|
||||
>
|
||||
<a-form ref="editForm" :rules="rules" :model="temp" :label-col="{ span: 4 }" :wrapper-col="{ span: 18 }">
|
||||
<a-form-item label="容器名称" name="name">
|
||||
<a-input v-model:value="temp.name" placeholder="容器名称" />
|
||||
<a-form-item :label="$tl('c.containerName')" name="name">
|
||||
<a-input v-model:value="temp.name" :placeholder="$tl('c.containerName')" />
|
||||
</a-form-item>
|
||||
|
||||
<a-form-item label="标签" name="tagInput" help="标签用于容器构建选择容器功能(fromTag)">
|
||||
<a-form-item
|
||||
:label="$tl('c.label')"
|
||||
name="tagInput"
|
||||
:help="`${$tl('c.label')} 用于容器构建选择容器功能(fromTag)`"
|
||||
>
|
||||
<a-space direction="vertical" style="width: 100%">
|
||||
<div>
|
||||
<a-tooltip v-for="(tag, index) in temp.tagsArray" :key="index" :title="tag">
|
||||
@ -135,7 +139,7 @@
|
||||
v-model:value="temp.tagInput"
|
||||
type="text"
|
||||
size="small"
|
||||
placeholder="请输入标签名 字母数字 长度 1-10"
|
||||
:placeholder="$tl('p.enterTagName')"
|
||||
@blur="handleInputConfirm"
|
||||
@keyup.enter="handleInputConfirm"
|
||||
/>
|
||||
@ -145,7 +149,7 @@
|
||||
style="borderstyle: dashed"
|
||||
@click="showInput"
|
||||
>
|
||||
<PlusOutlined /> 新增
|
||||
<PlusOutlined /> {{ $tl('p.add') }}
|
||||
</a-tag>
|
||||
</template>
|
||||
</a-space>
|
||||
@ -166,22 +170,22 @@
|
||||
v-model:open="syncToWorkspaceVisible"
|
||||
destroy-on-close
|
||||
:confirm-loading="confirmLoading"
|
||||
title="同步到其他工作空间"
|
||||
:title="$tl('p.syncToOtherWorkspace')"
|
||||
:mask-closable="false"
|
||||
@ok="handleSyncToWorkspace"
|
||||
>
|
||||
<a-alert message="温馨提示" type="warning">
|
||||
<a-alert :message="$tl('p.warmTip')" type="warning">
|
||||
<template #description>
|
||||
<ul>
|
||||
<li>同步机制采用容器 host 确定是同一个服务器(docker)</li>
|
||||
<li>当目标工作空间不存在对应的节点时候将自动创建一个新的docker(逻辑docker)</li>
|
||||
<li>当目标工作空间已经存在节点时候将自动同步 docker 仓库配置信息</li>
|
||||
<li>{{ $tl('p.syncMechanism') }}</li>
|
||||
<li>{{ $tl('p.createNewDocker') }}</li>
|
||||
<li>{{ $tl('p.syncDockerInfo') }}</li>
|
||||
</ul>
|
||||
</template>
|
||||
</a-alert>
|
||||
<a-form :model="temp" :label-col="{ span: 6 }" :wrapper-col="{ span: 14 }">
|
||||
<a-form-item> </a-form-item>
|
||||
<a-form-item label="选择工作空间" name="workspaceId">
|
||||
<a-form-item :label="$tl('p.chooseWorkspace')" name="workspaceId">
|
||||
<a-select
|
||||
v-model:value="temp.workspaceId"
|
||||
show-search
|
||||
@ -195,7 +199,7 @@
|
||||
)
|
||||
}
|
||||
"
|
||||
placeholder="请选择工作空间"
|
||||
:placeholder="$tl('c.selectWorkspace')"
|
||||
>
|
||||
<a-select-option v-for="item in workspaceList" :key="item.id" :disabled="getWorkspaceId() === item.id">{{
|
||||
item.name
|
||||
@ -236,7 +240,7 @@ export default {
|
||||
|
||||
columns: [
|
||||
{
|
||||
title: '名称',
|
||||
title: this.$tl('c.name'),
|
||||
dataIndex: 'name',
|
||||
ellipsis: true,
|
||||
width: 100
|
||||
@ -249,33 +253,33 @@ export default {
|
||||
tooltip: true
|
||||
},
|
||||
{
|
||||
title: '状态',
|
||||
title: this.$tl('p.status'),
|
||||
dataIndex: ['machineDocker', 'status'],
|
||||
ellipsis: true,
|
||||
align: 'center',
|
||||
width: '100px'
|
||||
},
|
||||
{
|
||||
title: 'docker版本',
|
||||
title: `docker${this.$tl('p.version')}`,
|
||||
dataIndex: ['machineDocker', 'dockerVersion'],
|
||||
ellipsis: true,
|
||||
width: '120px',
|
||||
tooltip: true
|
||||
},
|
||||
{
|
||||
title: '标签',
|
||||
title: this.$tl('c.label'),
|
||||
dataIndex: 'tags',
|
||||
width: 100,
|
||||
ellipsis: true
|
||||
},
|
||||
{
|
||||
title: '最后修改人',
|
||||
title: this.$tl('p.lastModifiedBy'),
|
||||
dataIndex: 'modifyUser',
|
||||
width: '120px',
|
||||
ellipsis: true
|
||||
},
|
||||
{
|
||||
title: '创建时间',
|
||||
title: this.$tl('p.creationTime'),
|
||||
dataIndex: 'createTimeMillis',
|
||||
ellipsis: true,
|
||||
sorter: true,
|
||||
@ -283,7 +287,7 @@ export default {
|
||||
width: '170px'
|
||||
},
|
||||
{
|
||||
title: '修改时间',
|
||||
title: this.$tl('p.modificationTime'),
|
||||
dataIndex: 'modifyTimeMillis',
|
||||
sorter: true,
|
||||
ellipsis: true,
|
||||
@ -291,7 +295,7 @@ export default {
|
||||
width: '170px'
|
||||
},
|
||||
{
|
||||
title: '操作',
|
||||
title: this.$tl('p.action'),
|
||||
dataIndex: 'operation',
|
||||
|
||||
fixed: 'right',
|
||||
@ -301,16 +305,16 @@ export default {
|
||||
],
|
||||
rules: {
|
||||
// id: [{ required: true, message: "Please input ID", trigger: "blur" }],
|
||||
name: [{ required: true, message: '请填写容器名称', trigger: 'blur' }],
|
||||
host: [{ required: true, message: '请填写容器地址', trigger: 'blur' }],
|
||||
name: [{ required: true, message: this.$tl('p.enterContainerName'), trigger: 'blur' }],
|
||||
host: [{ required: true, message: this.$tl('p.enterContainerAddress'), trigger: 'blur' }],
|
||||
tagInput: [
|
||||
// { required: true, message: "Please input ID", trigger: "blur" },
|
||||
{ pattern: /^\w{1,10}$/, message: '标签限制为字母数字且长度 1-10' }
|
||||
{ pattern: /^\w{1,10}$/, message: this.$tl('c.labelRestriction') }
|
||||
],
|
||||
|
||||
tag: [
|
||||
{ required: true, message: '请填写关联容器标签', trigger: 'blur' },
|
||||
{ pattern: /^\w{1,10}$/, message: '标签限制为字母数字且长度 1-10' }
|
||||
{ required: true, message: this.$tl('p.enterAssociatedContainerTag'), trigger: 'blur' },
|
||||
{ pattern: /^\w{1,10}$/, message: this.$tl('c.labelRestriction') }
|
||||
]
|
||||
},
|
||||
workspaceList: [],
|
||||
@ -360,6 +364,9 @@ export default {
|
||||
this.loadData()
|
||||
},
|
||||
methods: {
|
||||
$tl(key, ...args) {
|
||||
return this.$t(`pages.docker.list.${key}`, ...args)
|
||||
},
|
||||
// 加载数据
|
||||
loadData(pointerEvent) {
|
||||
this.loading = true
|
||||
@ -452,11 +459,11 @@ export default {
|
||||
// 删除
|
||||
handleDelete(record) {
|
||||
$confirm({
|
||||
title: '系统提示',
|
||||
title: this.$tl('p.systemPrompt'),
|
||||
zIndex: 1009,
|
||||
content: '真的要删除该记录么?删除后构建关联的容器标签将无法使用',
|
||||
okText: '确认',
|
||||
cancelText: '取消',
|
||||
content: this.$tl('p.confirmDeletion'),
|
||||
okText: this.$tl('p.confirm'),
|
||||
cancelText: this.$tl('p.cancel'),
|
||||
onOk: () => {
|
||||
return deleteDcoker({
|
||||
id: record.id
|
||||
@ -530,7 +537,7 @@ export default {
|
||||
handleSyncToWorkspace() {
|
||||
if (!this.temp.workspaceId) {
|
||||
$notification.warn({
|
||||
message: '请选择工作空间'
|
||||
message: this.$tl('c.selectWorkspace')
|
||||
})
|
||||
return false
|
||||
}
|
||||
|
@ -25,7 +25,7 @@
|
||||
<a-switch
|
||||
v-model:checked="timestamps"
|
||||
:checked-children="$tl('p.show')"
|
||||
un-checked-children="不{{$tl('p.show')}}"
|
||||
:un-checked-children="$tl('p.hide')"
|
||||
/>
|
||||
</div>
|
||||
<a-button type="primary" size="small" @click="initWebSocket"
|
||||
|
@ -47,11 +47,15 @@
|
||||
|
||||
<a-button type="primary" :loading="loading" @click="loadData">{{ $tl('p.search') }}</a-button>
|
||||
<a-statistic-countdown
|
||||
format=" {{$tl('p.sSeconds')}}"
|
||||
format="s"
|
||||
:title="$tl('p.refreshCountdown')"
|
||||
:value="countdownTime"
|
||||
@finish="loadData"
|
||||
/>
|
||||
>
|
||||
<template #suffix>
|
||||
<div style="font-size: 12px">{{ $tl('p.sSeconds') }}</div>
|
||||
</template>
|
||||
</a-statistic-countdown>
|
||||
</a-space>
|
||||
</template>
|
||||
<template #bodyCell="{ column, text, record }">
|
||||
|
@ -22,7 +22,7 @@
|
||||
<a-switch
|
||||
v-model:checked="timestamps"
|
||||
:checked-children="$tl('p.show')"
|
||||
un-checked-children="不{{$tl('p.show')}}"
|
||||
:un-checked-children="$tl('p.hide')"
|
||||
/>
|
||||
</div>
|
||||
<a-button type="primary" size="small" @click="init"><ReloadOutlined /> {{ $tl('p.refresh') }} </a-button>
|
||||
|
@ -28,11 +28,15 @@
|
||||
<a-button type="primary" :loading="loading" @click="loadData">{{ $tl('p.search') }}</a-button>
|
||||
<a-button type="primary" @click="handleAdd">{{ $tl('p.create') }}</a-button>
|
||||
<a-statistic-countdown
|
||||
format=" {{$tl('p.seconds')}}"
|
||||
format="s"
|
||||
:title="$tl('p.refreshCountdown')"
|
||||
:value="countdownTime"
|
||||
@finish="loadData"
|
||||
/>
|
||||
>
|
||||
<template #suffix>
|
||||
<div style="font-size: 12px">{{ $tl('p.seconds') }}</div>
|
||||
</template>
|
||||
</a-statistic-countdown>
|
||||
</a-space>
|
||||
</template>
|
||||
|
||||
|
@ -62,11 +62,15 @@
|
||||
</a-tooltip>
|
||||
<a-button type="primary" :loading="loading" @click="loadData">{{ $tl('p.search') }}</a-button>
|
||||
<a-statistic-countdown
|
||||
format=" {{$tl('p.seconds')}}"
|
||||
format="s"
|
||||
:title="$tl('p.refreshCountdown')"
|
||||
:value="countdownTime"
|
||||
@finish="loadData"
|
||||
/>
|
||||
>
|
||||
<template #suffix>
|
||||
<div style="font-size: 12px">{{ $tl('p.seconds') }}</div>
|
||||
</template>
|
||||
</a-statistic-countdown>
|
||||
</a-space>
|
||||
</template>
|
||||
|
||||
|
@ -64,7 +64,7 @@ export default defineConfig(({ mode }: ConfigEnv) => {
|
||||
proxy: {
|
||||
// http
|
||||
'/api': {
|
||||
target: `http://${HOST}`,
|
||||
target: HOST.includes('http') ? HOST : `http://${HOST}`,
|
||||
changeOrigin: true,
|
||||
ws: true,
|
||||
rewrite: (path) => path.replace(/^\/api/, ''),
|
||||
|
Loading…
Reference in New Issue
Block a user