1
1
import { Component , OnInit , OnDestroy , ContentChild , TemplateRef , Input } from '@angular/core' ;
2
- import { Subject , Observable , throwError } from 'rxjs' ;
3
- import { takeUntil , take , catchError , map } from 'rxjs/operators' ;
2
+ import { Subject } from 'rxjs' ;
3
+ import { takeUntil , take } from 'rxjs/operators' ;
4
4
import { NotificationService } from '../../shared/notification.service' ;
5
5
import { ContainerInfo } from 'dockerode' ;
6
6
import { DockerEventsService } from '../docker-events.service' ;
7
7
import { DockerContainerService } from '../docker-container.service' ;
8
8
import { ContainerMenuService } from '../container-menu.service' ;
9
- import { TabService } from '../../tabs/tab.service' ;
10
- import { TimoneerTabs } from '../../timoneer-tabs' ;
11
9
12
10
@Component ( {
13
11
selector : 'tim-container-list' ,
@@ -32,7 +30,6 @@ export class ContainerListComponent implements OnInit, OnDestroy {
32
30
constructor ( private containerService : DockerContainerService ,
33
31
private daemonEvents : DockerEventsService ,
34
32
private menuService : ContainerMenuService ,
35
- private tabService : TabService ,
36
33
private notificationService : NotificationService ) { }
37
34
38
35
public ngOnInit ( ) {
@@ -62,14 +59,6 @@ export class ContainerListComponent implements OnInit, OnDestroy {
62
59
} ) ;
63
60
}
64
61
65
- public getImageName ( container : ContainerInfo ) {
66
- if ( container . Image . startsWith ( 'sha256:' ) ) {
67
- return container . Image . replace ( 'sha256:' , '' ) . slice ( 0 , 12 ) ;
68
- } else {
69
- return container . Image ;
70
- }
71
- }
72
-
73
62
public getPortMappings ( container : ContainerInfo ) {
74
63
return container . Ports . map ( p => p . PublicPort ? `${ p . PublicPort } :${ p . PrivatePort } ` : p . PrivatePort ) . join ( '\n' ) ;
75
64
}
0 commit comments