@spinnaker/ecs 0.0.0-main-2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +1186 -0
- package/LICENSE.txt +203 -0
- package/dist/common/common.module.d.ts +1 -0
- package/dist/common/footer.component.d.ts +1 -0
- package/dist/domain/IEcsLoadBalancer.d.ts +119 -0
- package/dist/ecs.help.d.ts +1 -0
- package/dist/ecs.module.d.ts +4 -0
- package/dist/ecs.settings.d.ts +9 -0
- package/dist/ecsCluster/IEcsCapacityProviderDetails.d.ts +10 -0
- package/dist/ecsCluster/IEcsCluster.d.ts +5 -0
- package/dist/ecsCluster/ecsCluster.read.service.d.ts +7 -0
- package/dist/iamRoles/IRole.d.ts +6 -0
- package/dist/iamRoles/iamRole.read.service.d.ts +5 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +6010 -0
- package/dist/index.js.map +1 -0
- package/dist/instance/details/instance.details.controller.d.ts +2 -0
- package/dist/loadBalancer/EcsLoadBalancerClusterContainer.d.ts +6 -0
- package/dist/loadBalancer/TargetGroup.d.ts +11 -0
- package/dist/loadBalancer/details/loadBalancerDetails.d.ts +27 -0
- package/dist/loadBalancer/details/targetGroupDetails.d.ts +30 -0
- package/dist/loadBalancer/listener.d.ts +10 -0
- package/dist/loadBalancer/loadBalancer.transformer.d.ts +8 -0
- package/dist/loadBalancer/targetGroup.states.d.ts +1 -0
- package/dist/metricAlarm/MetricAlarm.d.ts +6 -0
- package/dist/metricAlarm/metricAlarm.read.service.d.ts +5 -0
- package/dist/pipeline/stages/destroyAsg/ecsDestroyAsgStage.d.ts +2 -0
- package/dist/pipeline/stages/disableAsg/ecsDisableAsgStage.d.ts +2 -0
- package/dist/pipeline/stages/disableCluster/ecsDisableClusterStage.d.ts +2 -0
- package/dist/pipeline/stages/enableAsg/ecsEnableAsgStage.d.ts +2 -0
- package/dist/pipeline/stages/findImageFromTags/ecsFindImageFromTagStage.d.ts +2 -0
- package/dist/pipeline/stages/resizeAsg/ecsResizeAsgStage.d.ts +2 -0
- package/dist/pipeline/stages/scaleDownCluster/ecsScaleDownClusterStage.d.ts +2 -0
- package/dist/pipeline/stages/shrinkCluster/ecsShrinkClusterStage.d.ts +2 -0
- package/dist/placementStrategy/IPlacementStrategy.d.ts +4 -0
- package/dist/placementStrategy/placementStrategy.service.d.ts +11 -0
- package/dist/secrets/ISecret.d.ts +5 -0
- package/dist/secrets/secret.read.service.d.ts +5 -0
- package/dist/securityGroup/details/securityGroupDetail.controller.d.ts +2 -0
- package/dist/securityGroup/securityGroup.module.d.ts +1 -0
- package/dist/securityGroup/securityGroup.reader.d.ts +5 -0
- package/dist/securityGroup/securityGroup.transformer.d.ts +2 -0
- package/dist/serverGroup/configure/serverGroupCommandBuilder.service.d.ts +2 -0
- package/dist/serverGroup/configure/serverGroupConfiguration.service.d.ts +165 -0
- package/dist/serverGroup/configure/wizard/CloneServerGroup.ecs.controller.d.ts +2 -0
- package/dist/serverGroup/configure/wizard/advancedSettings/advancedSettings.component.d.ts +2 -0
- package/dist/serverGroup/configure/wizard/capacityProvider/CapacityProvider.d.ts +7 -0
- package/dist/serverGroup/configure/wizard/container/Container.d.ts +32 -0
- package/dist/serverGroup/configure/wizard/horizontalScaling/horizontalScaling.component.d.ts +2 -0
- package/dist/serverGroup/configure/wizard/location/ServerGroupBasicSettings.controller.d.ts +2 -0
- package/dist/serverGroup/configure/wizard/logging/logging.component.d.ts +1 -0
- package/dist/serverGroup/configure/wizard/networking/Networking.d.ts +28 -0
- package/dist/serverGroup/configure/wizard/serviceDiscovery/ServiceDiscovery.d.ts +34 -0
- package/dist/serverGroup/configure/wizard/taskDefinition/TaskDefinition.d.ts +39 -0
- package/dist/serverGroup/details/resize/resizeCapacity.component.d.ts +1 -0
- package/dist/serverGroup/details/resize/resizeServerGroup.controller.d.ts +2 -0
- package/dist/serverGroup/details/rollback/rollbackServerGroup.controller.d.ts +2 -0
- package/dist/serverGroup/details/serverGroupDetails.ecs.controller.d.ts +2 -0
- package/dist/serverGroup/details/serverGroupDetails.module.d.ts +1 -0
- package/dist/serverGroup/events/EventsLink.d.ts +4 -0
- package/dist/serverGroup/events/events.component.d.ts +3 -0
- package/dist/serverGroup/events/events.controller.d.ts +19 -0
- package/dist/serverGroup/events/serverGroupEventsReader.service.d.ts +10 -0
- package/dist/serverGroup/serverGroup.module.d.ts +1 -0
- package/dist/serverGroup/serverGroup.transformer.d.ts +11 -0
- package/dist/serviceDiscovery/IServiceDiscovery.d.ts +12 -0
- package/dist/serviceDiscovery/serviceDiscovery.read.service.d.ts +4 -0
- package/package.json +47 -0
- package/src/common/common.module.ts +6 -0
- package/src/common/footer.component.ts +29 -0
- package/src/domain/IEcsLoadBalancer.ts +129 -0
- package/src/ecs.help.ts +91 -0
- package/src/ecs.module.ts +116 -0
- package/src/ecs.settings.ts +17 -0
- package/src/ecsCluster/IEcsCapacityProviderDetails.ts +11 -0
- package/src/ecsCluster/IEcsCluster.ts +5 -0
- package/src/ecsCluster/ecsCluster.read.service.ts +23 -0
- package/src/iamRoles/IRole.ts +6 -0
- package/src/iamRoles/iamRole.read.service.ts +14 -0
- package/src/index.ts +1 -0
- package/src/instance/details/instance.details.controller.js +356 -0
- package/src/instance/details/instanceDetails.html +204 -0
- package/src/loadBalancer/EcsLoadBalancerClusterContainer.tsx +48 -0
- package/src/loadBalancer/TargetGroup.tsx +74 -0
- package/src/loadBalancer/details/loadBalancerDetails.tsx +235 -0
- package/src/loadBalancer/details/targetGroupDetails.tsx +251 -0
- package/src/loadBalancer/listener.tsx +65 -0
- package/src/loadBalancer/loadBalancer.transformer.ts +21 -0
- package/src/loadBalancer/targetGroup.states.ts +59 -0
- package/src/logo/ecs.icon.svg +27 -0
- package/src/logo/ecs.logo.less +5 -0
- package/src/logo/ecs.logo.svg +27 -0
- package/src/metricAlarm/MetricAlarm.ts +6 -0
- package/src/metricAlarm/metricAlarm.read.service.ts +14 -0
- package/src/pipeline/stages/cloneServerGroup/cloneServerGroupStage.html +101 -0
- package/src/pipeline/stages/cloneServerGroup/cloneServerGroupStepLabel.html +1 -0
- package/src/pipeline/stages/cloneServerGroup/ecsCloneServerGroupStage.js +94 -0
- package/src/pipeline/stages/destroyAsg/destroyAsgStage.html +9 -0
- package/src/pipeline/stages/destroyAsg/destroyAsgStepLabel.html +1 -0
- package/src/pipeline/stages/destroyAsg/ecsDestroyAsgStage.js +65 -0
- package/src/pipeline/stages/disableAsg/disableAsgStage.html +11 -0
- package/src/pipeline/stages/disableAsg/disableAsgStepLabel.html +1 -0
- package/src/pipeline/stages/disableAsg/ecsDisableAsgStage.js +70 -0
- package/src/pipeline/stages/disableCluster/disableClusterStage.html +26 -0
- package/src/pipeline/stages/disableCluster/ecsDisableClusterStage.js +84 -0
- package/src/pipeline/stages/enableAsg/ecsEnableAsgStage.js +73 -0
- package/src/pipeline/stages/enableAsg/enableAsgStage.html +11 -0
- package/src/pipeline/stages/enableAsg/enableAsgStepLabel.html +1 -0
- package/src/pipeline/stages/findImageFromTags/ecsFindImageFromTagStage.js +26 -0
- package/src/pipeline/stages/findImageFromTags/findImageFromTagsExecutionDetails.html +36 -0
- package/src/pipeline/stages/findImageFromTags/findImageFromTagsStage.html +9 -0
- package/src/pipeline/stages/resizeAsg/ecsResizeAsgStage.js +128 -0
- package/src/pipeline/stages/resizeAsg/resizeAsgStage.html +87 -0
- package/src/pipeline/stages/resizeAsg/resizeAsgStepLabel.html +1 -0
- package/src/pipeline/stages/scaleDownCluster/ecsScaleDownClusterStage.js +78 -0
- package/src/pipeline/stages/scaleDownCluster/scaleDownClusterStage.html +35 -0
- package/src/pipeline/stages/shrinkCluster/ecsShrinkClusterStage.js +73 -0
- package/src/pipeline/stages/shrinkCluster/shrinkClusterStage.html +34 -0
- package/src/placementStrategy/IPlacementStrategy.ts +4 -0
- package/src/placementStrategy/placementStrategy.service.ts +63 -0
- package/src/secrets/ISecret.ts +5 -0
- package/src/secrets/secret.read.service.ts +14 -0
- package/src/securityGroup/details/securityGroupDetail.controller.js +147 -0
- package/src/securityGroup/details/securityGroupDetail.html +104 -0
- package/src/securityGroup/securityGroup.module.ts +12 -0
- package/src/securityGroup/securityGroup.reader.ts +16 -0
- package/src/securityGroup/securityGroup.transformer.js +13 -0
- package/src/serverGroup/configure/serverGroupCommandBuilder.service.js +281 -0
- package/src/serverGroup/configure/serverGroupConfiguration.service.ts +747 -0
- package/src/serverGroup/configure/wizard/CloneServerGroup.ecs.controller.js +259 -0
- package/src/serverGroup/configure/wizard/advancedSettings/advancedSettings.component.html +194 -0
- package/src/serverGroup/configure/wizard/advancedSettings/advancedSettings.component.js +17 -0
- package/src/serverGroup/configure/wizard/advancedSettings/advancedSettings.html +10 -0
- package/src/serverGroup/configure/wizard/capacityProvider/CapacityProvider.tsx +381 -0
- package/src/serverGroup/configure/wizard/capacityProvider/capacityProvider.html +11 -0
- package/src/serverGroup/configure/wizard/container/Container.tsx +347 -0
- package/src/serverGroup/configure/wizard/container/container.html +9 -0
- package/src/serverGroup/configure/wizard/horizontalScaling/horizontalScaling.component.html +118 -0
- package/src/serverGroup/configure/wizard/horizontalScaling/horizontalScaling.component.js +20 -0
- package/src/serverGroup/configure/wizard/horizontalScaling/horizontalScaling.html +13 -0
- package/src/serverGroup/configure/wizard/location/ServerGroupBasicSettings.controller.js +41 -0
- package/src/serverGroup/configure/wizard/location/basicSettings.html +137 -0
- package/src/serverGroup/configure/wizard/logging/logging.component.html +29 -0
- package/src/serverGroup/configure/wizard/logging/logging.component.ts +12 -0
- package/src/serverGroup/configure/wizard/logging/logging.html +7 -0
- package/src/serverGroup/configure/wizard/networking/Networking.tsx +261 -0
- package/src/serverGroup/configure/wizard/networking/networking.html +9 -0
- package/src/serverGroup/configure/wizard/serverGroupWizard.html +55 -0
- package/src/serverGroup/configure/wizard/serviceDiscovery/ServiceDiscovery.tsx +250 -0
- package/src/serverGroup/configure/wizard/serviceDiscovery/serviceDiscovery.html +11 -0
- package/src/serverGroup/configure/wizard/taskDefinition/TaskDefinition.tsx +460 -0
- package/src/serverGroup/configure/wizard/taskDefinition/taskDefinition.html +51 -0
- package/src/serverGroup/configure/wizard/templateSelection/templateSelection.html +9 -0
- package/src/serverGroup/configure/wizard/verticalScaling/verticalScaling.html +10 -0
- package/src/serverGroup/details/resize/resizeCapacity.component.html +94 -0
- package/src/serverGroup/details/resize/resizeCapacity.component.ts +14 -0
- package/src/serverGroup/details/resize/resizeServerGroup.controller.js +85 -0
- package/src/serverGroup/details/resize/resizeServerGroup.html +28 -0
- package/src/serverGroup/details/rollback/rollbackServerGroup.controller.js +97 -0
- package/src/serverGroup/details/rollback/rollbackServerGroup.html +67 -0
- package/src/serverGroup/details/serverGroupDetails.ecs.controller.js +366 -0
- package/src/serverGroup/details/serverGroupDetails.html +216 -0
- package/src/serverGroup/details/serverGroupDetails.module.ts +5 -0
- package/src/serverGroup/events/EventsLink.tsx +5 -0
- package/src/serverGroup/events/events.component.ts +35 -0
- package/src/serverGroup/events/events.controller.ts +45 -0
- package/src/serverGroup/events/events.html +36 -0
- package/src/serverGroup/events/serverGroupEventsReader.service.ts +27 -0
- package/src/serverGroup/serverGroup.module.ts +6 -0
- package/src/serverGroup/serverGroup.transformer.spec.ts +184 -0
- package/src/serverGroup/serverGroup.transformer.ts +117 -0
- package/src/serviceDiscovery/IServiceDiscovery.ts +13 -0
- package/src/serviceDiscovery/serviceDiscovery.read.service.ts +8 -0
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
<svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100">
|
|
2
|
+
<title>Compute</title>
|
|
3
|
+
<g>
|
|
4
|
+
<polygon points="19.64 22.51 16 24.32 16 75.68 19.64 77.49 33.98 51.07 19.64 22.51" fill="#9d5025"/>
|
|
5
|
+
<polygon points="30.72 31.78 36.08 24.19 60.1 34.87 54.5 35.76 30.72 31.78" fill="#9d5025"/>
|
|
6
|
+
<polygon points="26.56 68.77 32.46 76.88 60.1 64.95 54.76 64.12 26.56 68.77" fill="#9d5025"/>
|
|
7
|
+
<polygon points="28.12 75.5 19.64 77.49 19.64 22.51 28.12 24.44 28.12 75.5" fill="#f58536"/>
|
|
8
|
+
<polygon points="23.66 20.5 28.12 18.27 36.52 53.56 28.12 81.73 23.66 79.5 23.66 20.5" fill="#9d5025"/>
|
|
9
|
+
<polygon points="54.46 64.08 60.1 64.95 65.26 50.58 60.1 34.87 54.46 35.76 54.46 64.08" fill="#9d5025"/>
|
|
10
|
+
<polygon points="36.8 79.28 28.12 81.73 28.12 18.27 36.8 20.73 36.8 79.28" fill="#f58536"/>
|
|
11
|
+
<polygon points="66.01 63.84 28.12 70.88 28.12 81.73 66.01 71.03 66.01 63.84" fill="#f58536"/>
|
|
12
|
+
<polygon points="66.08 36 28.12 28.79 28.12 18.27 66.08 29.04 66.08 36" fill="#f58536"/>
|
|
13
|
+
<polygon points="60.1 27.34 66.19 29.02 66.19 71.03 60.1 72.7 60.1 27.34" fill="#f58536"/>
|
|
14
|
+
<polygon points="84 44.45 67.7 45.22 61.94 44.83 78.42 31.55 84 44.45" fill="#6b3a19"/>
|
|
15
|
+
<polygon points="61.94 44.83 78.42 43.9 78.42 31.55 61.94 34.22 61.94 44.83" fill="#9d5025"/>
|
|
16
|
+
<polygon points="46.43 43.79 63.13 26.96 71.62 43.22 54.31 44.32 46.43 43.79" fill="#6b3a19"/>
|
|
17
|
+
<polygon points="46.43 43.79 63.13 42.37 63.13 26.96 46.43 30.87 46.43 43.79" fill="#9d5025"/>
|
|
18
|
+
<polygon points="61.94 55.39 84 55.77 78.42 68.67 61.94 66 61.94 55.39" fill="#9d5025"/>
|
|
19
|
+
<polygon points="46.43 56.43 71.62 57.01 63.13 73.26 46.43 69.36 46.43 56.43" fill="#9d5025"/>
|
|
20
|
+
<polygon points="46.43 56.43 63.13 57.86 71.62 57.01 54.31 55.9 46.43 56.43" fill="#fbbf93"/>
|
|
21
|
+
<polygon points="84 55.77 67.7 55.01 61.94 55.39 78.42 56.33 84 55.77" fill="#fbbf93"/>
|
|
22
|
+
<polygon points="78.42 43.9 84 44.45 84 33.22 78.42 31.55 78.42 43.9" fill="#f58536"/>
|
|
23
|
+
<polygon points="71.62 43.22 63.13 42.37 63.13 26.96 71.62 29.51 71.62 43.22" fill="#f58536"/>
|
|
24
|
+
<polygon points="78.42 56.33 84 55.77 84 67 78.42 68.67 78.42 56.33" fill="#f58536"/>
|
|
25
|
+
<polygon points="71.62 57.01 63.13 57.86 63.13 73.26 71.62 70.72 71.62 57.01" fill="#f58536"/>
|
|
26
|
+
</g>
|
|
27
|
+
</svg>
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { module } from 'angular';
|
|
2
|
+
|
|
3
|
+
import { REST } from '@spinnaker/core';
|
|
4
|
+
import type { IMetricAlarmDescriptor } from './MetricAlarm';
|
|
5
|
+
|
|
6
|
+
export class MetricAlarmReader {
|
|
7
|
+
public listMetricAlarms(): PromiseLike<IMetricAlarmDescriptor[]> {
|
|
8
|
+
return REST('/ecs/cloudMetrics/alarms').get();
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export const METRIC_ALARM_READ_SERVICE = 'spinnaker.ecs.metricAlarm.read.service';
|
|
13
|
+
|
|
14
|
+
module(METRIC_ALARM_READ_SERVICE, []).service('metricAlarmReader', MetricAlarmReader);
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
<div ng-controller="ecsCloneServerGroupStageCtrl as cloneServerGroupStageCtrl">
|
|
2
|
+
<div ng-if="!pipeline.strategy">
|
|
3
|
+
<div ng-if="viewState.loading">
|
|
4
|
+
<h4 class="text-center">
|
|
5
|
+
<span us-spinner="{radius:20, width:6, length: 12}"></span>
|
|
6
|
+
</h4>
|
|
7
|
+
</div>
|
|
8
|
+
<div ng-if="!viewState.loading">
|
|
9
|
+
<account-region-cluster-selector
|
|
10
|
+
application="application"
|
|
11
|
+
component="stage"
|
|
12
|
+
accounts="accounts"
|
|
13
|
+
single-region="true"
|
|
14
|
+
cluster-field="targetCluster"
|
|
15
|
+
>
|
|
16
|
+
</account-region-cluster-selector>
|
|
17
|
+
</div>
|
|
18
|
+
</div>
|
|
19
|
+
<stage-config-field label="Target">
|
|
20
|
+
<target-select model="stage" options="cloneServerGroupStageCtrl.cloneTargets"></target-select>
|
|
21
|
+
</stage-config-field>
|
|
22
|
+
<div>
|
|
23
|
+
<div class="form-group">
|
|
24
|
+
<div class="col-md-3 sm-label-right">Capacity</div>
|
|
25
|
+
<div class="col-md-9 radio">
|
|
26
|
+
<label>
|
|
27
|
+
<input
|
|
28
|
+
type="radio"
|
|
29
|
+
ng-model="stage.useSourceCapacity"
|
|
30
|
+
ng-value="true"
|
|
31
|
+
ng-click="cloneServerGroupStageCtrl.removeCapacity()"
|
|
32
|
+
id="useSourceCapacityTrue"
|
|
33
|
+
/>
|
|
34
|
+
Copy the capacity from the current server group
|
|
35
|
+
<help-field key="serverGroupCapacity.useSourceCapacityTrue"></help-field>
|
|
36
|
+
</label>
|
|
37
|
+
</div>
|
|
38
|
+
<div class="col-md-9 col-md-offset-3 radio">
|
|
39
|
+
<label>
|
|
40
|
+
<input type="radio" ng-model="stage.useSourceCapacity" ng-value="false" id="useSourceCapacityFalse" />
|
|
41
|
+
Let me specify the capacity
|
|
42
|
+
<help-field key="serverGroupCapacity.useSourceCapacityFalse"></help-field>
|
|
43
|
+
</label>
|
|
44
|
+
</div>
|
|
45
|
+
</div>
|
|
46
|
+
<div class="form-group">
|
|
47
|
+
<div class="col-md-2 col-md-offset-3">Min</div>
|
|
48
|
+
<div class="col-md-2">Max</div>
|
|
49
|
+
<div class="col-md-2">Desired</div>
|
|
50
|
+
</div>
|
|
51
|
+
<div class="form-group">
|
|
52
|
+
<div class="col-md-2 col-md-offset-3">
|
|
53
|
+
<input
|
|
54
|
+
type="number"
|
|
55
|
+
ng-disabled="stage.useSourceCapacity"
|
|
56
|
+
class="form-control input-sm"
|
|
57
|
+
ng-model="stage.capacity.min"
|
|
58
|
+
min="0"
|
|
59
|
+
max="{{stage.capacity.max}}"
|
|
60
|
+
required
|
|
61
|
+
/>
|
|
62
|
+
</div>
|
|
63
|
+
<div class="col-md-2">
|
|
64
|
+
<input
|
|
65
|
+
type="number"
|
|
66
|
+
ng-disabled="stage.useSourceCapacity"
|
|
67
|
+
class="form-control input-sm"
|
|
68
|
+
ng-model="stage.capacity.max"
|
|
69
|
+
min="{{stage.capacity.min}}"
|
|
70
|
+
required
|
|
71
|
+
/>
|
|
72
|
+
</div>
|
|
73
|
+
<div class="col-md-2">
|
|
74
|
+
<input
|
|
75
|
+
type="number"
|
|
76
|
+
ng-disabled="stage.useSourceCapacity"
|
|
77
|
+
class="form-control input-sm"
|
|
78
|
+
ng-model="stage.capacity.desired"
|
|
79
|
+
min="{{stage.capacity.min}}"
|
|
80
|
+
max="{{stage.capacity.max}}"
|
|
81
|
+
required
|
|
82
|
+
/>
|
|
83
|
+
</div>
|
|
84
|
+
</div>
|
|
85
|
+
</div>
|
|
86
|
+
<stage-config-field label="Traffic">
|
|
87
|
+
<div class="checkbox">
|
|
88
|
+
<label>
|
|
89
|
+
<input
|
|
90
|
+
type="checkbox"
|
|
91
|
+
ng-click="cloneServerGroupStageCtrl.toggleSuspendedProcess('AddToLoadBalancer')"
|
|
92
|
+
ng-checked="!cloneServerGroupStageCtrl.processIsSuspended('AddToLoadBalancer')"
|
|
93
|
+
/>
|
|
94
|
+
Send client requests to new instances
|
|
95
|
+
</label>
|
|
96
|
+
</div>
|
|
97
|
+
</stage-config-field>
|
|
98
|
+
<stage-platform-health-override application="application" stage="stage" platform-health-type="'Ecs'">
|
|
99
|
+
</stage-platform-health-override>
|
|
100
|
+
<deployment-strategy-selector field-columns="6" command="stage"></deployment-strategy-selector>
|
|
101
|
+
</div>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<span class="task-label"> Clone Server Group: {{step.context.source.serverGroupName}} ({{step.context.region}}) </span>
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
import { module } from 'angular';
|
|
4
|
+
import _ from 'lodash';
|
|
5
|
+
|
|
6
|
+
import { AccountService, NameUtils, Registry, StageConstants } from '@spinnaker/core';
|
|
7
|
+
|
|
8
|
+
export const ECS_PIPELINE_STAGES_CLONESERVERGROUP_ECSCLONESERVERGROUPSTAGE =
|
|
9
|
+
'spinnaker.ecs.pipeline.stage.cloneServerGroupStage';
|
|
10
|
+
export const name = ECS_PIPELINE_STAGES_CLONESERVERGROUP_ECSCLONESERVERGROUPSTAGE; // for backwards compatibility
|
|
11
|
+
module(ECS_PIPELINE_STAGES_CLONESERVERGROUP_ECSCLONESERVERGROUPSTAGE, [])
|
|
12
|
+
.config(function () {
|
|
13
|
+
Registry.pipeline.registerStage({
|
|
14
|
+
provides: 'cloneServerGroup',
|
|
15
|
+
cloudProvider: 'ecs',
|
|
16
|
+
templateUrl: require('./cloneServerGroupStage.html'),
|
|
17
|
+
executionStepLabelUrl: require('./cloneServerGroupStepLabel.html'),
|
|
18
|
+
accountExtractor: (stage) => [stage.context.credentials],
|
|
19
|
+
validators: [
|
|
20
|
+
{ type: 'requiredField', fieldName: 'targetCluster', fieldLabel: 'cluster' },
|
|
21
|
+
{ type: 'requiredField', fieldName: 'target' },
|
|
22
|
+
{ type: 'requiredField', fieldName: 'region' },
|
|
23
|
+
{ type: 'requiredField', fieldName: 'credentials', fieldLabel: 'account' },
|
|
24
|
+
],
|
|
25
|
+
});
|
|
26
|
+
})
|
|
27
|
+
.controller('ecsCloneServerGroupStageCtrl', [
|
|
28
|
+
'$scope',
|
|
29
|
+
function ($scope) {
|
|
30
|
+
const stage = $scope.stage;
|
|
31
|
+
|
|
32
|
+
$scope.viewState = {
|
|
33
|
+
accountsLoaded: false,
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
AccountService.listAccounts('ecs').then((accounts) => {
|
|
37
|
+
$scope.accounts = accounts;
|
|
38
|
+
$scope.viewState.accountsLoaded = true;
|
|
39
|
+
});
|
|
40
|
+
|
|
41
|
+
this.cloneTargets = StageConstants.TARGET_LIST;
|
|
42
|
+
stage.target = stage.target || this.cloneTargets[0].val;
|
|
43
|
+
stage.application = $scope.application.name;
|
|
44
|
+
stage.cloudProvider = 'ecs';
|
|
45
|
+
stage.cloudProviderType = 'ecs';
|
|
46
|
+
|
|
47
|
+
if (
|
|
48
|
+
stage.isNew &&
|
|
49
|
+
$scope.application.attributes.platformHealthOnlyShowOverride &&
|
|
50
|
+
$scope.application.attributes.platformHealthOnly
|
|
51
|
+
) {
|
|
52
|
+
stage.interestingHealthProviderNames = ['Ecs'];
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
if (!stage.credentials && $scope.application.defaultCredentials.ecs) {
|
|
56
|
+
stage.credentials = $scope.application.defaultCredentials.ecs;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
this.targetClusterUpdated = () => {
|
|
60
|
+
if (stage.targetCluster) {
|
|
61
|
+
const clusterName = NameUtils.parseServerGroupName(stage.targetCluster);
|
|
62
|
+
stage.stack = clusterName.stack;
|
|
63
|
+
stage.freeFormDetails = clusterName.freeFormDetails;
|
|
64
|
+
} else {
|
|
65
|
+
stage.stack = '';
|
|
66
|
+
stage.freeFormDetails = '';
|
|
67
|
+
}
|
|
68
|
+
};
|
|
69
|
+
|
|
70
|
+
$scope.$watch('stage.targetCluster', this.targetClusterUpdated);
|
|
71
|
+
|
|
72
|
+
this.removeCapacity = () => {
|
|
73
|
+
delete stage.capacity;
|
|
74
|
+
};
|
|
75
|
+
|
|
76
|
+
if (!_.has(stage, 'useSourceCapacity')) {
|
|
77
|
+
stage.useSourceCapacity = true;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
this.toggleSuspendedProcess = (process) => {
|
|
81
|
+
stage.suspendedProcesses = stage.suspendedProcesses || [];
|
|
82
|
+
const processIndex = stage.suspendedProcesses.indexOf(process);
|
|
83
|
+
if (processIndex === -1) {
|
|
84
|
+
stage.suspendedProcesses.push(process);
|
|
85
|
+
} else {
|
|
86
|
+
stage.suspendedProcesses.splice(processIndex, 1);
|
|
87
|
+
}
|
|
88
|
+
};
|
|
89
|
+
|
|
90
|
+
this.processIsSuspended = (process) => {
|
|
91
|
+
return stage.suspendedProcesses && stage.suspendedProcesses.includes(process);
|
|
92
|
+
};
|
|
93
|
+
},
|
|
94
|
+
]);
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
<div ng-controller="ecsDestroyAsgStageCtrl as destroyAsgStageCtrl" class="form-horizontal">
|
|
2
|
+
<div ng-if="!pipeline.strategy">
|
|
3
|
+
<account-region-cluster-selector application="application" component="stage" accounts="accounts">
|
|
4
|
+
</account-region-cluster-selector>
|
|
5
|
+
</div>
|
|
6
|
+
<stage-config-field label="Target">
|
|
7
|
+
<target-select model="stage" options="targets"></target-select>
|
|
8
|
+
</stage-config-field>
|
|
9
|
+
</div>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<span class="task-label"> Destroy Server Group: {{step.context.serverGroupName}} ({{step.context.region}}) </span>
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
import { module } from 'angular';
|
|
4
|
+
|
|
5
|
+
import { AccountService, Registry, StageConstants } from '@spinnaker/core';
|
|
6
|
+
|
|
7
|
+
export const ECS_PIPELINE_STAGES_DESTROYASG_ECSDESTROYASGSTAGE = 'spinnaker.ecs.pipeline.stage.ecs.destroyAsgStage';
|
|
8
|
+
export const name = ECS_PIPELINE_STAGES_DESTROYASG_ECSDESTROYASGSTAGE; // for backwards compatibility
|
|
9
|
+
module(ECS_PIPELINE_STAGES_DESTROYASG_ECSDESTROYASGSTAGE, [])
|
|
10
|
+
.config(function () {
|
|
11
|
+
Registry.pipeline.registerStage({
|
|
12
|
+
provides: 'destroyServerGroup',
|
|
13
|
+
alias: 'destroyAsg',
|
|
14
|
+
cloudProvider: 'ecs',
|
|
15
|
+
templateUrl: require('./destroyAsgStage.html'),
|
|
16
|
+
executionStepLabelUrl: require('./destroyAsgStepLabel.html'),
|
|
17
|
+
accountExtractor: (stage) => [stage.context.credentials],
|
|
18
|
+
configAccountExtractor: (stage) => [stage.credentials],
|
|
19
|
+
validators: [
|
|
20
|
+
{
|
|
21
|
+
type: 'targetImpedance',
|
|
22
|
+
message:
|
|
23
|
+
'This pipeline will attempt to destroy a server group without deploying a new version into the same cluster.',
|
|
24
|
+
},
|
|
25
|
+
{ type: 'requiredField', fieldName: 'cluster' },
|
|
26
|
+
{ type: 'requiredField', fieldName: 'target' },
|
|
27
|
+
{ type: 'requiredField', fieldName: 'regions' },
|
|
28
|
+
{ type: 'requiredField', fieldName: 'credentials', fieldLabel: 'account' },
|
|
29
|
+
],
|
|
30
|
+
});
|
|
31
|
+
})
|
|
32
|
+
.controller('ecsDestroyAsgStageCtrl', [
|
|
33
|
+
'$scope',
|
|
34
|
+
function ($scope) {
|
|
35
|
+
const stage = $scope.stage;
|
|
36
|
+
|
|
37
|
+
$scope.state = {
|
|
38
|
+
accounts: false,
|
|
39
|
+
regionsLoaded: false,
|
|
40
|
+
};
|
|
41
|
+
|
|
42
|
+
AccountService.listAccounts('ecs').then(function (accounts) {
|
|
43
|
+
$scope.accounts = accounts;
|
|
44
|
+
$scope.state.accounts = true;
|
|
45
|
+
});
|
|
46
|
+
|
|
47
|
+
$scope.regions = ['us-east-1', 'us-west-1', 'eu-west-1', 'us-west-2'];
|
|
48
|
+
|
|
49
|
+
$scope.targets = StageConstants.TARGET_LIST;
|
|
50
|
+
|
|
51
|
+
stage.regions = stage.regions || [];
|
|
52
|
+
stage.cloudProvider = 'ecs';
|
|
53
|
+
|
|
54
|
+
if (!stage.credentials && $scope.application.defaultCredentials.ecs) {
|
|
55
|
+
stage.credentials = $scope.application.defaultCredentials.ecs;
|
|
56
|
+
}
|
|
57
|
+
if (!stage.regions.length && $scope.application.defaultRegions.ecs) {
|
|
58
|
+
stage.regions.push($scope.application.defaultRegions.ecs);
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
if (!stage.target) {
|
|
62
|
+
stage.target = $scope.targets[0].val;
|
|
63
|
+
}
|
|
64
|
+
},
|
|
65
|
+
]);
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<div ng-controller="ecsDisableAsgStageCtrl as disableAsgStageCtrl" class="form-horizontal">
|
|
2
|
+
<div ng-if="!pipeline.strategy">
|
|
3
|
+
<account-region-cluster-selector application="application" component="stage" accounts="accounts">
|
|
4
|
+
</account-region-cluster-selector>
|
|
5
|
+
</div>
|
|
6
|
+
<stage-config-field label="Target">
|
|
7
|
+
<target-select model="stage" options="targets"></target-select>
|
|
8
|
+
</stage-config-field>
|
|
9
|
+
<stage-platform-health-override application="application" stage="stage" platform-health-type="'Ecs'">
|
|
10
|
+
</stage-platform-health-override>
|
|
11
|
+
</div>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<span class="task-label"> Disable Server Group: {{step.context.serverGroupName}} ({{step.context.region}}) </span>
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
import { module } from 'angular';
|
|
4
|
+
|
|
5
|
+
import { AccountService, PipelineTemplates, Registry, StageConstants } from '@spinnaker/core';
|
|
6
|
+
|
|
7
|
+
export const ECS_PIPELINE_STAGES_DISABLEASG_ECSDISABLEASGSTAGE = 'spinnaker.ecs.pipeline.stage.disableAsgStage';
|
|
8
|
+
export const name = ECS_PIPELINE_STAGES_DISABLEASG_ECSDISABLEASGSTAGE; // for backwards compatibility
|
|
9
|
+
module(ECS_PIPELINE_STAGES_DISABLEASG_ECSDISABLEASGSTAGE, [])
|
|
10
|
+
.config(function () {
|
|
11
|
+
Registry.pipeline.registerStage({
|
|
12
|
+
provides: 'disableServerGroup',
|
|
13
|
+
alias: 'disableAsg',
|
|
14
|
+
cloudProvider: 'ecs',
|
|
15
|
+
templateUrl: require('./disableAsgStage.html'),
|
|
16
|
+
executionDetailsUrl: PipelineTemplates.disableAsgExecutionDetails,
|
|
17
|
+
executionStepLabelUrl: require('./disableAsgStepLabel.html'),
|
|
18
|
+
validators: [
|
|
19
|
+
{
|
|
20
|
+
type: 'targetImpedance',
|
|
21
|
+
message:
|
|
22
|
+
'This pipeline will attempt to disable a server group without deploying a new version into the same cluster.',
|
|
23
|
+
},
|
|
24
|
+
{ type: 'requiredField', fieldName: 'cluster' },
|
|
25
|
+
{ type: 'requiredField', fieldName: 'target' },
|
|
26
|
+
{ type: 'requiredField', fieldName: 'regions' },
|
|
27
|
+
{ type: 'requiredField', fieldName: 'credentials', fieldLabel: 'account' },
|
|
28
|
+
],
|
|
29
|
+
});
|
|
30
|
+
})
|
|
31
|
+
.controller('ecsDisableAsgStageCtrl', [
|
|
32
|
+
'$scope',
|
|
33
|
+
function ($scope) {
|
|
34
|
+
const stage = $scope.stage;
|
|
35
|
+
|
|
36
|
+
$scope.state = {
|
|
37
|
+
accounts: false,
|
|
38
|
+
regionsLoaded: false,
|
|
39
|
+
};
|
|
40
|
+
|
|
41
|
+
AccountService.listAccounts('ecs').then(function (accounts) {
|
|
42
|
+
$scope.accounts = accounts;
|
|
43
|
+
$scope.state.accounts = true;
|
|
44
|
+
});
|
|
45
|
+
|
|
46
|
+
$scope.targets = StageConstants.TARGET_LIST;
|
|
47
|
+
|
|
48
|
+
stage.regions = stage.regions || [];
|
|
49
|
+
stage.cloudProvider = 'ecs';
|
|
50
|
+
|
|
51
|
+
if (
|
|
52
|
+
stage.isNew &&
|
|
53
|
+
$scope.application.attributes.platformHealthOnlyShowOverride &&
|
|
54
|
+
$scope.application.attributes.platformHealthOnly
|
|
55
|
+
) {
|
|
56
|
+
stage.interestingHealthProviderNames = ['Ecs'];
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
if (!stage.credentials && $scope.application.defaultCredentials.ecs) {
|
|
60
|
+
stage.credentials = $scope.application.defaultCredentials.ecs;
|
|
61
|
+
}
|
|
62
|
+
if (!stage.regions.length && $scope.application.defaultRegions.ecs) {
|
|
63
|
+
stage.regions.push($scope.application.defaultRegions.ecs);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
if (!stage.target) {
|
|
67
|
+
stage.target = $scope.targets[0].val;
|
|
68
|
+
}
|
|
69
|
+
},
|
|
70
|
+
]);
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<div ng-controller="ecsDisableClusterStageCtrl as disableClusterStageCtrl" class="form-horizontal">
|
|
2
|
+
<div ng-if="!pipeline.strategy">
|
|
3
|
+
<account-region-cluster-selector application="application" component="stage" accounts="accounts">
|
|
4
|
+
</account-region-cluster-selector>
|
|
5
|
+
</div>
|
|
6
|
+
<stage-config-field label="Disable Options">
|
|
7
|
+
<div class="form-inline">
|
|
8
|
+
Keep the
|
|
9
|
+
<input
|
|
10
|
+
type="number"
|
|
11
|
+
min="0"
|
|
12
|
+
required
|
|
13
|
+
ng-model="stage.remainingEnabledServerGroups"
|
|
14
|
+
class="form-control input-sm"
|
|
15
|
+
style="width: 50px"
|
|
16
|
+
/>
|
|
17
|
+
<select class="form-control input-sm" ng-model="stage.preferLargerOverNewer" style="width: 100px">
|
|
18
|
+
<option value="true">largest</option>
|
|
19
|
+
<option value="false">newest</option>
|
|
20
|
+
</select>
|
|
21
|
+
{{disableClusterStageCtrl.pluralize('server group', stage.remainingEnabledServerGroups)}} enabled.
|
|
22
|
+
</div>
|
|
23
|
+
</stage-config-field>
|
|
24
|
+
<stage-platform-health-override application="application" stage="stage" platform-health-type="'Ecs'">
|
|
25
|
+
</stage-platform-health-override>
|
|
26
|
+
</div>
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
import { module } from 'angular';
|
|
4
|
+
|
|
5
|
+
import { AccountService, Registry } from '@spinnaker/core';
|
|
6
|
+
|
|
7
|
+
export const ECS_PIPELINE_STAGES_DISABLECLUSTER_ECSDISABLECLUSTERSTAGE =
|
|
8
|
+
'spinnaker.ecs.pipeline.stage.disableClusterStage';
|
|
9
|
+
export const name = ECS_PIPELINE_STAGES_DISABLECLUSTER_ECSDISABLECLUSTERSTAGE; // for backwards compatibility
|
|
10
|
+
module(ECS_PIPELINE_STAGES_DISABLECLUSTER_ECSDISABLECLUSTERSTAGE, [])
|
|
11
|
+
.config(function () {
|
|
12
|
+
Registry.pipeline.registerStage({
|
|
13
|
+
provides: 'disableCluster',
|
|
14
|
+
cloudProvider: 'ecs',
|
|
15
|
+
templateUrl: require('./disableClusterStage.html'),
|
|
16
|
+
validators: [
|
|
17
|
+
{ type: 'requiredField', fieldName: 'cluster' },
|
|
18
|
+
{
|
|
19
|
+
type: 'requiredField',
|
|
20
|
+
fieldName: 'remainingEnabledServerGroups',
|
|
21
|
+
fieldLabel: 'Keep [X] enabled Server Groups',
|
|
22
|
+
},
|
|
23
|
+
{ type: 'requiredField', fieldName: 'regions' },
|
|
24
|
+
{ type: 'requiredField', fieldName: 'credentials', fieldLabel: 'account' },
|
|
25
|
+
],
|
|
26
|
+
});
|
|
27
|
+
})
|
|
28
|
+
.controller('ecsDisableClusterStageCtrl', [
|
|
29
|
+
'$scope',
|
|
30
|
+
function ($scope) {
|
|
31
|
+
const ctrl = this;
|
|
32
|
+
|
|
33
|
+
const stage = $scope.stage;
|
|
34
|
+
|
|
35
|
+
$scope.state = {
|
|
36
|
+
accounts: false,
|
|
37
|
+
regionsLoaded: false,
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
AccountService.listAccounts('ecs').then(function (accounts) {
|
|
41
|
+
$scope.accounts = accounts;
|
|
42
|
+
$scope.state.accounts = true;
|
|
43
|
+
});
|
|
44
|
+
|
|
45
|
+
ctrl.reset = () => {
|
|
46
|
+
ctrl.accountUpdated();
|
|
47
|
+
ctrl.resetSelectedCluster();
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
stage.regions = stage.regions || [];
|
|
51
|
+
stage.cloudProvider = 'ecs';
|
|
52
|
+
|
|
53
|
+
if (
|
|
54
|
+
stage.isNew &&
|
|
55
|
+
$scope.application.attributes.platformHealthOnlyShowOverride &&
|
|
56
|
+
$scope.application.attributes.platformHealthOnly
|
|
57
|
+
) {
|
|
58
|
+
stage.interestingHealthProviderNames = ['Ecs'];
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
if (!stage.credentials && $scope.application.defaultCredentials.ecs) {
|
|
62
|
+
stage.credentials = $scope.application.defaultCredentials.ecs;
|
|
63
|
+
}
|
|
64
|
+
if (!stage.regions.length && $scope.application.defaultRegions.ecs) {
|
|
65
|
+
stage.regions.push($scope.application.defaultRegions.ecs);
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
if (stage.remainingEnabledServerGroups === undefined) {
|
|
69
|
+
stage.remainingEnabledServerGroups = 1;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
ctrl.pluralize = function (str, val) {
|
|
73
|
+
if (val === 1) {
|
|
74
|
+
return str;
|
|
75
|
+
}
|
|
76
|
+
return str + 's';
|
|
77
|
+
};
|
|
78
|
+
|
|
79
|
+
if (stage.preferLargerOverNewer === undefined) {
|
|
80
|
+
stage.preferLargerOverNewer = 'false';
|
|
81
|
+
}
|
|
82
|
+
stage.preferLargerOverNewer = stage.preferLargerOverNewer.toString();
|
|
83
|
+
},
|
|
84
|
+
]);
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
import { module } from 'angular';
|
|
4
|
+
|
|
5
|
+
import { AccountService, Registry, StageConstants } from '@spinnaker/core';
|
|
6
|
+
|
|
7
|
+
export const ECS_PIPELINE_STAGES_ENABLEASG_ECSENABLEASGSTAGE = 'spinnaker.ecs.pipeline.stage.enableAsgStage';
|
|
8
|
+
export const name = ECS_PIPELINE_STAGES_ENABLEASG_ECSENABLEASGSTAGE; // for backwards compatibility
|
|
9
|
+
module(ECS_PIPELINE_STAGES_ENABLEASG_ECSENABLEASGSTAGE, [])
|
|
10
|
+
.config(function () {
|
|
11
|
+
Registry.pipeline.registerStage({
|
|
12
|
+
provides: 'enableServerGroup',
|
|
13
|
+
alias: 'enableAsg',
|
|
14
|
+
cloudProvider: 'ecs',
|
|
15
|
+
templateUrl: require('./enableAsgStage.html'),
|
|
16
|
+
executionStepLabelUrl: require('./enableAsgStepLabel.html'),
|
|
17
|
+
validators: [
|
|
18
|
+
{ type: 'requiredField', fieldName: 'cluster' },
|
|
19
|
+
{ type: 'requiredField', fieldName: 'target' },
|
|
20
|
+
{ type: 'requiredField', fieldName: 'regions' },
|
|
21
|
+
{ type: 'requiredField', fieldName: 'credentials', fieldLabel: 'account' },
|
|
22
|
+
],
|
|
23
|
+
});
|
|
24
|
+
})
|
|
25
|
+
.controller('ecsEnableAsgStageCtrl', [
|
|
26
|
+
'$scope',
|
|
27
|
+
function ($scope) {
|
|
28
|
+
const ctrl = this;
|
|
29
|
+
|
|
30
|
+
const stage = $scope.stage;
|
|
31
|
+
|
|
32
|
+
$scope.state = {
|
|
33
|
+
accounts: false,
|
|
34
|
+
regionsLoaded: false,
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
AccountService.listAccounts('ecs').then(function (accounts) {
|
|
38
|
+
$scope.accounts = accounts;
|
|
39
|
+
$scope.state.accounts = true;
|
|
40
|
+
});
|
|
41
|
+
|
|
42
|
+
ctrl.reset = () => {
|
|
43
|
+
ctrl.accountUpdated();
|
|
44
|
+
ctrl.resetSelectedCluster();
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
$scope.targets = StageConstants.TARGET_LIST;
|
|
48
|
+
|
|
49
|
+
stage.regions = stage.regions || [];
|
|
50
|
+
stage.cloudProvider = 'ecs';
|
|
51
|
+
|
|
52
|
+
if (
|
|
53
|
+
stage.isNew &&
|
|
54
|
+
$scope.application.attributes.platformHealthOnlyShowOverride &&
|
|
55
|
+
$scope.application.attributes.platformHealthOnly
|
|
56
|
+
) {
|
|
57
|
+
stage.interestingHealthProviderNames = ['Ecs'];
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
if (!stage.credentials && $scope.application.defaultCredentials.ecs) {
|
|
61
|
+
stage.credentials = $scope.application.defaultCredentials.ecs;
|
|
62
|
+
}
|
|
63
|
+
if (!stage.regions.length && $scope.application.defaultRegions.ecs) {
|
|
64
|
+
stage.regions.push($scope.application.defaultRegions.ecs);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
if (!stage.target) {
|
|
68
|
+
stage.target = $scope.targets[0].val;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
$scope.$watch('stage.credentials', $scope.accountUpdated);
|
|
72
|
+
},
|
|
73
|
+
]);
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<div ng-controller="ecsEnableAsgStageCtrl as enableAsgStageCtrl" class="form-horizontal">
|
|
2
|
+
<div ng-if="!pipeline.strategy">
|
|
3
|
+
<account-region-cluster-selector application="application" component="stage" accounts="accounts">
|
|
4
|
+
</account-region-cluster-selector>
|
|
5
|
+
</div>
|
|
6
|
+
<stage-config-field label="Target">
|
|
7
|
+
<target-select model="stage" options="targets"></target-select>
|
|
8
|
+
</stage-config-field>
|
|
9
|
+
<stage-platform-health-override application="application" stage="stage" platform-health-type="'Ecs'">
|
|
10
|
+
</stage-platform-health-override>
|
|
11
|
+
</div>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<span class="task-label"> Enable Server Group: {{step.context.serverGroupName}} ({{step.context.region}}) </span>
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
import { module } from 'angular';
|
|
4
|
+
|
|
5
|
+
import { Registry } from '@spinnaker/core';
|
|
6
|
+
|
|
7
|
+
export const ECS_PIPELINE_STAGES_FINDIMAGEFROMTAGS_ECSFINDIMAGEFROMTAGSTAGE =
|
|
8
|
+
'spinnaker.ecs.pipeline.stage.findImageFromTagsStage';
|
|
9
|
+
export const name = ECS_PIPELINE_STAGES_FINDIMAGEFROMTAGS_ECSFINDIMAGEFROMTAGSTAGE; // for backwards compatibility
|
|
10
|
+
module(ECS_PIPELINE_STAGES_FINDIMAGEFROMTAGS_ECSFINDIMAGEFROMTAGSTAGE, [])
|
|
11
|
+
.config(function () {
|
|
12
|
+
Registry.pipeline.registerStage({
|
|
13
|
+
provides: 'findImageFromTags',
|
|
14
|
+
cloudProvider: 'ecs',
|
|
15
|
+
templateUrl: require('./findImageFromTagsStage.html'),
|
|
16
|
+
executionDetailsUrl: require('./findImageFromTagsExecutionDetails.html'),
|
|
17
|
+
executionConfigSections: ['findImageConfig', 'taskStatus'],
|
|
18
|
+
validators: [{ type: 'requiredField', fieldName: 'imageLabelOrSha' }],
|
|
19
|
+
});
|
|
20
|
+
})
|
|
21
|
+
.controller('ecsFindImageFromTagsStageCtrl', [
|
|
22
|
+
'$scope',
|
|
23
|
+
function ($scope) {
|
|
24
|
+
$scope.stage.cloudProvider = $scope.stage.cloudProvider || 'ecs';
|
|
25
|
+
},
|
|
26
|
+
]);
|