|
59 | 59 | </uib-tab>
|
60 | 60 | <uib-tab heading="Environment" active="selectedTab.environment">
|
61 | 61 | <uib-tab-heading>Environment</uib-tab-heading>
|
62 |
| - <div ng-repeat="container in pod.spec.containers"> |
63 |
| - <h3>Container {{container.name}} Environment Variables</h3> |
64 |
| - <key-value-editor |
65 |
| - entries="container.env" |
66 |
| - is-readonly |
67 |
| - cannot-add |
68 |
| - cannot-sort |
69 |
| - cannot-delete |
70 |
| - ng-if="container.env.length"></key-value-editor> |
71 |
| - <em ng-if="!container.env.length">The container specification has no environment variables set.</em> |
| 62 | + |
| 63 | + <div class="row"> |
| 64 | + <div class="col-sm-6 col-lg-4"> |
| 65 | + <span ng-if="pod.spec.containers.length === 1"> |
| 66 | + <label for="selectLogContainer">Container:</label> |
| 67 | + {{pod.spec.containers[0].name}} |
| 68 | + </span> |
| 69 | + <ui-select |
| 70 | + ng-if="pod.spec.containers.length > 1" |
| 71 | + ng-model="tabs.env.selected.container"> |
| 72 | + <ui-select-match |
| 73 | + class="truncate" |
| 74 | + placeholder="Container Name"> |
| 75 | + <span ng-bind="tabs.env.selected.container"></span> |
| 76 | + </ui-select-match> |
| 77 | + <ui-select-choices |
| 78 | + repeat="container.name as container in pod.spec.containers"> |
| 79 | + {{container.name}} |
| 80 | + </ui-select-choices> |
| 81 | + </ui-select> |
| 82 | + </div> |
| 83 | + </div> |
| 84 | + |
| 85 | + <div |
| 86 | + class="row" |
| 87 | + ng-repeat="container in pod.spec.containers" |
| 88 | + ng-show="tabs.env.selected.container === container.name"> |
| 89 | + <div class="col-sm-12"> |
| 90 | + <h3>Container {{container.name}} Environment Variables</h3> |
| 91 | + <key-value-editor |
| 92 | + entries="container.env" |
| 93 | + is-readonly |
| 94 | + cannot-add |
| 95 | + cannot-sort |
| 96 | + cannot-delete |
| 97 | + ng-if="container.env.length"></key-value-editor> |
| 98 | + <em ng-if="!container.env.length">The container specification has no environment variables set.</em> |
| 99 | + </div> |
72 | 100 | </div>
|
| 101 | + |
73 | 102 | </uib-tab>
|
74 | 103 | <uib-tab ng-if="metricsAvailable" heading="Metrics" active="selectedTab.metrics">
|
75 | 104 | <!-- Use ng-if to remove the metrics directive when the tab is not active so
|
|
0 commit comments