Skip to content

Commit 84766c1

Browse files
Kautilya Tripathijoaquimrocha
authored andcommitted
frontend: Add feature to view deploy logs
This adds feature to view all the pods of pods in a deployment rather than going to a specific pod. Fixes: #2552 Signed-off-by: Kautilya Tripathi <ktripathi@microsoft.com>
1 parent 8ad8977 commit 84766c1

File tree

60 files changed

+840
-66
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+840
-66
lines changed

frontend/src/components/common/Resource/LogsButton.tsx

Lines changed: 461 additions & 0 deletions
Large diffs are not rendered by default.

frontend/src/components/common/Resource/MainInfoSection/MainInfoSectionHeader.tsx

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ import ErrorBoundary from '../../ErrorBoundary';
1212
import SectionHeader, { HeaderStyle } from '../../SectionHeader';
1313
import DeleteButton from '../DeleteButton';
1414
import EditButton from '../EditButton';
15+
import { LogsButton } from '../LogsButton';
1516
import { RestartButton } from '../RestartButton';
1617
import ScaleButton from '../ScaleButton';
1718

@@ -44,6 +45,9 @@ export function MainInfoHeader<T extends KubeObject>(props: MainInfoHeaderProps<
4445
case DefaultHeaderAction.RESTART:
4546
Action = RestartButton;
4647
break;
48+
case DefaultHeaderAction.DEPLOYMENT_LOGS:
49+
Action = LogsButton;
50+
break;
4751
case DefaultHeaderAction.SCALE:
4852
Action = ScaleButton;
4953
break;
@@ -79,6 +83,9 @@ export function MainInfoHeader<T extends KubeObject>(props: MainInfoHeaderProps<
7983
{
8084
id: DefaultHeaderAction.RESTART,
8185
},
86+
{
87+
id: DefaultHeaderAction.DEPLOYMENT_LOGS,
88+
},
8289
{
8390
id: DefaultHeaderAction.SCALE,
8491
},

frontend/src/components/common/Resource/MainInfoSection/__snapshots__/MainInfoSection.Normal.stories.storyshot

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,11 @@
4949
<div
5050
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
5151
/>
52+
<div
53+
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
54+
>
55+
0
56+
</div>
5257
<div
5358
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
5459
/>

frontend/src/components/common/Resource/MainInfoSection/__snapshots__/MainInfoSection.NullBacklink.stories.storyshot

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,11 @@
3131
<div
3232
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
3333
/>
34+
<div
35+
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
36+
>
37+
0
38+
</div>
3439
<div
3540
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
3641
/>

frontend/src/components/common/Resource/index.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ const checkExports = [
3535
'SimpleEditor',
3636
'ViewButton',
3737
'AuthVisible',
38+
'LogsButton',
3839
];
3940

4041
function getFilesToVerify() {

frontend/src/components/common/Resource/index.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ export { default as ResourceTableColumnChooser } from './ResourceTableColumnChoo
2727
export { addResourceTableColumnsProcessor } from './resourceTableSlice';
2828
export * from './RestartButton';
2929
export * from './ScaleButton';
30+
export * from './LogsButton';
3031
export { default as ScaleButton } from './ScaleButton';
3132
export * from './SimpleEditor';
3233
export { default as SimpleEditor } from './SimpleEditor';

frontend/src/components/configmap/__snapshots__/Details.Empty.stories.storyshot

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,11 @@
6363
<div
6464
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
6565
/>
66+
<div
67+
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
68+
>
69+
0
70+
</div>
6671
<div
6772
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
6873
/>

frontend/src/components/configmap/__snapshots__/Details.WithBase.stories.storyshot

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,11 @@
6363
<div
6464
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
6565
/>
66+
<div
67+
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
68+
>
69+
0
70+
</div>
6671
<div
6772
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
6873
/>

frontend/src/components/crd/__snapshots__/CustomResourceDefinition.Details.stories.storyshot

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,11 @@
5858
<div
5959
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
6060
/>
61+
<div
62+
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
63+
>
64+
0
65+
</div>
6166
<div
6267
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
6368
/>

frontend/src/components/crd/__snapshots__/CustomResourceDetails.NoError.stories.storyshot

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,11 @@
5858
<div
5959
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
6060
/>
61+
<div
62+
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
63+
>
64+
0
65+
</div>
6166
<div
6267
class="MuiGrid-root MuiGrid-item css-13i4rnv-MuiGrid-root"
6368
/>

0 commit comments

Comments
 (0)