Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
小 白蛋
Tke
Commits
34a9ea28
Commit
34a9ea28
authored
4 years ago
by
kaychen
Committed by
tke-robot
4 years ago
Browse files
Options
Download
Email Patches
Plain Diff
feat: installer fix bug
parent
1d237d5b
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
web/console/Wrapper.tsx
+8
-1
web/console/Wrapper.tsx
web/installer/src/modules/installer/actions/validateActions.ts
+4
-16
...nstaller/src/modules/installer/actions/validateActions.ts
web/installer/src/modules/installer/components/Step3.tsx
+4
-4
web/installer/src/modules/installer/components/Step3.tsx
web/installer/src/modules/installer/components/Step6.tsx
+9
-6
web/installer/src/modules/installer/components/Step6.tsx
web/installer/src/modules/installer/components/Step9.tsx
+6
-3
web/installer/src/modules/installer/components/Step9.tsx
with
31 additions
and
30 deletions
+31
-30
web/console/Wrapper.tsx
+
8
-
1
View file @
34a9ea28
...
...
@@ -475,6 +475,7 @@ export class Wrapper extends React.Component<ConsoleWrapperProps, ConsoleWrapper
userType
,
projects
});
let
isInBlankPage
=
window
.
location
.
pathname
.
indexOf
(
'
tkestack/blank
'
)
!==
-
1
;
if
(
userType
===
UserType
.
member
&&
this
.
props
.
platformType
===
PlatformTypeEnum
.
Manager
)
{
location
.
href
=
location
.
origin
+
'
/tkestack-project/application
'
;
}
else
if
(
...
...
@@ -483,8 +484,14 @@ export class Wrapper extends React.Component<ConsoleWrapperProps, ConsoleWrapper
this
.
props
.
platformType
===
PlatformTypeEnum
.
Business
)
{
location
.
href
=
location
.
origin
+
'
/tkestack
'
;
}
else
if
(
userType
===
UserType
.
other
&&
window
.
location
.
pathname
.
indexOf
(
'
tkestack/blank
'
)
===
-
1
)
{
}
else
if
(
userType
===
UserType
.
other
&&
!
isInBlankPage
)
{
window
.
location
.
pathname
=
'
tkestack/blank
'
;
}
else
if
(
isInBlankPage
)
{
if
(
userType
===
UserType
.
admin
)
{
location
.
href
=
location
.
origin
+
'
/tkestack
'
;
}
else
if
(
userType
===
UserType
.
member
)
{
location
.
href
=
location
.
origin
+
'
/tkestack-project/application
'
;
}
}
}
}
catch
(
error
)
{}
...
...
This diff is collapsed.
Click to expand it.
web/installer/src/modules/installer/actions/validateActions.ts
+
4
-
16
View file @
34a9ea28
...
...
@@ -701,14 +701,8 @@ export const validateActions = {
if
(
editState
.
openAudit
)
{
result
=
validateActions
.
_validateESUrl
(
editState
.
auditEsUrl
,
'
es
'
).
status
===
1
&&
validateActions
.
_validateESUsername
(
editState
.
auditEsUsername
,
editState
.
auditEsUsername
||
editState
.
auditEsPassword
?
'
es
'
:
null
).
status
===
1
&&
validateActions
.
_validateESPassword
(
editState
.
auditEsPassword
,
editState
.
auditEsUsername
||
editState
.
auditEsPassword
?
'
es
'
:
null
).
status
===
1
;
validateActions
.
_validateESUsername
(
editState
.
auditEsUsername
,
'
es
'
).
status
===
1
&&
validateActions
.
_validateESPassword
(
editState
.
auditEsPassword
,
'
es
'
).
status
===
1
;
}
return
result
;
...
...
@@ -717,14 +711,8 @@ export const validateActions = {
validateStep6
(
editState
:
EditState
)
{
return
dispatch
=>
{
const
v_auditEsUrl
=
validateActions
.
_validateESUrl
(
editState
.
auditEsUrl
,
'
es
'
),
v_auditEsUsername
=
validateActions
.
_validateESUsername
(
editState
.
auditEsUsername
,
editState
.
auditEsUsername
||
editState
.
auditEsPassword
?
'
es
'
:
null
),
v_auditEsPassword
=
validateActions
.
_validateESPassword
(
editState
.
auditEsPassword
,
editState
.
auditEsUsername
||
editState
.
auditEsPassword
?
'
es
'
:
null
);
v_auditEsUsername
=
validateActions
.
_validateESUsername
(
editState
.
auditEsUsername
,
'
es
'
),
v_auditEsPassword
=
validateActions
.
_validateESPassword
(
editState
.
auditEsPassword
,
'
es
'
);
dispatch
(
installerActions
.
updateEdit
({
...
...
This diff is collapsed.
Click to expand it.
web/installer/src/modules/installer/components/Step3.tsx
+
4
-
4
View file @
34a9ea28
...
...
@@ -111,7 +111,9 @@ export class Step3 extends React.Component<RootProps> {
<>
平台会自动为集群安装
<
ExternalLink
href
=
{
'
https://github.com/tkestack/tke/blob/master/docs/guide/zh-CN/features/gpumanager.md
'
}
href
=
{
'
https://github.com/tkestack/docs/blob/master/docs/zh/%E4%BA%A7%E5%93%81%E7%89%B9%E8%89%B2%E5%8A%9F%E8%83%BD/GPUManager.md
'
}
>
GPUManager
</
ExternalLink
>
...
...
@@ -120,9 +122,7 @@ export class Step3 extends React.Component<RootProps> {
)
:
(
<>
平台会自动为集群安装
<
ExternalLink
href
=
{
'
https://github.com/NVIDIA/k8s-device-plugin%EF%BC%89
'
}
>
nvidia-k8s-plugin
</
ExternalLink
>
<
ExternalLink
href
=
{
'
https://github.com/NVIDIA/k8s-device-plugin
'
}
>
nvidia-k8s-plugin
</
ExternalLink
>
</>
)
}
...
...
This diff is collapsed.
Click to expand it.
web/installer/src/modules/installer/components/Step6.tsx
+
9
-
6
View file @
34a9ea28
import
*
as
React
from
'
react
'
;
import
{
Button
,
Form
,
Switch
,
Input
,
InputNumber
}
from
'
@tencent/tea-component
'
;
import
{
Button
,
Form
,
Switch
,
Input
,
InputNumber
,
InputAdorment
}
from
'
@tencent/tea-component
'
;
import
{
RootProps
}
from
'
./InstallerApp
'
;
import
{
getValidateStatus
}
from
'
../../common/utils
'
;
...
...
@@ -41,11 +41,14 @@ export class Step6 extends React.Component<RootProps> {
onChange
=
{
value
=>
actions
.
installer
.
updateEdit
({
auditEsUrl
:
value
})
}
/>
</
Form
.
Item
>
<
Form
.
Item
label
=
"保留数据时间"
required
>
<
InputNumber
value
=
{
editState
.
auditEsReserveDays
}
onChange
=
{
value
=>
actions
.
installer
.
updateEdit
({
auditEsReserveDays
:
value
})
}
/>
<
Form
.
Item
label
=
"保留数据时间"
required
align
=
{
'
middle
'
}
>
<
InputAdorment
after
=
{
'
天
'
}
appearence
=
{
'
pure
'
}
>
<
InputNumber
min
=
{
1
}
value
=
{
editState
.
auditEsReserveDays
}
onChange
=
{
value
=>
actions
.
installer
.
updateEdit
({
auditEsReserveDays
:
value
})
}
/>
</
InputAdorment
>
</
Form
.
Item
>
<
Form
.
Item
label
=
"用户名"
...
...
This diff is collapsed.
Click to expand it.
web/installer/src/modules/installer/components/Step9.tsx
+
6
-
3
View file @
34a9ea28
...
...
@@ -124,9 +124,12 @@ export class Step9 extends React.Component<RootProps> {
<
Form
.
Item
label
=
"是否开启"
>
<
Form
.
Text
>
{
editState
.
openAudit
?
'
是
'
:
'
否
'
}
</
Form
.
Text
>
</
Form
.
Item
>
<
Form
.
Item
label
=
"ES地址"
>
<
Form
.
Text
>
{
editState
.
auditEsUrl
}
</
Form
.
Text
>
</
Form
.
Item
>
{
editState
.
openAudit
&&
(
<
Form
.
Item
label
=
"ES地址"
>
<
Form
.
Text
>
{
editState
.
auditEsUrl
}
</
Form
.
Text
>
</
Form
.
Item
>
)
}
{
(
editState
.
auditEsUsername
||
editState
.
auditEsPassword
)
&&
(
<>
<
Form
.
Item
label
=
"用户名"
>
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment