2017-06-20 10:54:27 +00:00
|
|
|
<div ng-if="applicationState.endpoint.apiVersion >= 1.25" id="service-secrets">
|
2017-05-27 07:23:49 +00:00
|
|
|
<rd-widget>
|
2022-07-19 03:29:50 +00:00
|
|
|
<rd-widget-header icon="list" feather-icon="true" title-text="Secrets"> </rd-widget-header>
|
2017-05-27 07:23:49 +00:00
|
|
|
<rd-widget-body classes="no-padding">
|
2022-01-17 05:53:32 +00:00
|
|
|
<div class="form-inline" style="padding: 10px" authorization="DockerServiceUpdate">
|
2017-05-27 07:23:49 +00:00
|
|
|
Add a secret:
|
2018-10-28 02:39:09 +00:00
|
|
|
<select class="form-control" ng-options="secret.Name for secret in secrets | orderBy: 'Name'" ng-model="state.addSecret.secret">
|
2017-05-27 07:23:49 +00:00
|
|
|
<option selected disabled hidden value="">Select a secret</option>
|
|
|
|
</select>
|
2020-04-10 21:54:53 +00:00
|
|
|
<div class="form-group" ng-if="applicationState.endpoint.apiVersion >= 1.3 && state.addSecret.override">
|
2017-11-20 13:44:23 +00:00
|
|
|
Target:
|
2020-04-10 21:54:53 +00:00
|
|
|
<input class="form-control" ng-model="state.addSecret.target" placeholder="/path/in/container" />
|
2017-11-20 13:44:23 +00:00
|
|
|
</div>
|
2020-04-10 21:54:53 +00:00
|
|
|
<div class="btn-group btn-group-sm" ng-if="applicationState.endpoint.apiVersion >= 1.3">
|
2022-07-26 23:18:06 +00:00
|
|
|
<label class="btn btn-light" ng-model="state.addSecret.override" uib-btn-radio="false">Default location</label>
|
|
|
|
<label class="btn btn-light" ng-model="state.addSecret.override" uib-btn-radio="true">Override</label>
|
2017-11-20 13:44:23 +00:00
|
|
|
</div>
|
2022-07-26 23:20:21 +00:00
|
|
|
<a class="btn btn-default btn-sm" ng-click="addSecret(service, state.addSecret)"> <pr-icon icon="'plus'" mode="'alt'" feather="true"></pr-icon> add secret </a>
|
2017-05-27 07:23:49 +00:00
|
|
|
</div>
|
2022-01-17 05:53:32 +00:00
|
|
|
<table class="table" style="margin-top: 5px">
|
2017-05-27 07:23:49 +00:00
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th>Name</th>
|
|
|
|
<th>File name</th>
|
|
|
|
<th>UID</th>
|
|
|
|
<th>GID</th>
|
|
|
|
<th>Mode</th>
|
|
|
|
<th></th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
<tr ng-repeat="secret in service.ServiceSecrets">
|
2020-04-10 21:54:53 +00:00
|
|
|
<td
|
|
|
|
><a ui-sref="docker.secrets.secret({id: secret.Id})">{{ secret.Name }}</a></td
|
|
|
|
>
|
2017-05-27 07:23:49 +00:00
|
|
|
<td>{{ secret.FileName }}</td>
|
|
|
|
<td>{{ secret.Uid }}</td>
|
|
|
|
<td>{{ secret.Gid }}</td>
|
|
|
|
<td>{{ secret.Mode }}</td>
|
2019-05-24 06:04:58 +00:00
|
|
|
<td authorization="DockerServiceUpdate">
|
2022-07-26 23:18:06 +00:00
|
|
|
<button class="btn btn-xs btn-light pull-right" type="button" ng-click="removeSecret(service, $index)" ng-disabled="isUpdating">
|
2022-08-03 00:56:29 +00:00
|
|
|
<pr-icon icon="'trash-2'" feather="true" class-name="'icon-secondary icon-md'"></pr-icon> Remove secret
|
2017-05-27 07:23:49 +00:00
|
|
|
</button>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
<tr ng-if="service.ServiceSecrets.length === 0">
|
|
|
|
<td colspan="6" class="text-center text-muted">No secrets associated to this service.</td>
|
|
|
|
</tr>
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
</rd-widget-body>
|
2019-05-24 06:04:58 +00:00
|
|
|
<rd-widget-footer authorization="DockerServiceUpdate">
|
2017-05-27 07:23:49 +00:00
|
|
|
<div class="btn-toolbar" role="toolbar">
|
|
|
|
<div class="btn-group" role="group">
|
|
|
|
<button type="button" class="btn btn-primary btn-sm" ng-disabled="!hasChanges(service, ['ServiceSecrets'])" ng-click="updateService(service)">Apply changes</button>
|
|
|
|
<button type="button" class="btn btn-default btn-sm dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
|
|
|
<span class="caret"></span>
|
|
|
|
</button>
|
|
|
|
<ul class="dropdown-menu">
|
|
|
|
<li><a ng-click="cancelChanges(service, ['ServiceSecrets'])">Reset changes</a></li>
|
|
|
|
<li><a ng-click="cancelChanges(service)">Reset all changes</a></li>
|
|
|
|
</ul>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</rd-widget-footer>
|
|
|
|
</rd-widget>
|
|
|
|
</div>
|