@spinnaker/core 0.29.0 → 0.29.1
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/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@spinnaker/core",
|
|
3
3
|
"license": "Apache-2.0",
|
|
4
|
-
"version": "0.29.
|
|
4
|
+
"version": "0.29.1",
|
|
5
5
|
"module": "dist/index.js",
|
|
6
6
|
"typings": "dist/index.d.ts",
|
|
7
7
|
"publishConfig": {
|
|
@@ -123,5 +123,5 @@
|
|
|
123
123
|
"shx": "0.3.3",
|
|
124
124
|
"typescript": "4.3.5"
|
|
125
125
|
},
|
|
126
|
-
"gitHead": "
|
|
126
|
+
"gitHead": "2f7f8de7b0c43ea29ac505a9b4c0f5d9b29456f4"
|
|
127
127
|
}
|
|
@@ -8,72 +8,101 @@ export interface IRedBlackStrategyAdditionalFieldsProps extends IDeploymentStrat
|
|
|
8
8
|
command: IRedBlackCommand;
|
|
9
9
|
}
|
|
10
10
|
|
|
11
|
-
export
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
11
|
+
export class AdditionalFields extends React.Component<IRedBlackStrategyAdditionalFieldsProps> {
|
|
12
|
+
private rollbackOnFailureChange = (e: React.ChangeEvent<HTMLInputElement>) => {
|
|
13
|
+
this.props.command.rollback.onFailure = e.target.checked;
|
|
14
|
+
this.forceUpdate();
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
private scaleDownChange = (e: React.ChangeEvent<HTMLInputElement>) => {
|
|
18
|
+
this.props.command.scaleDown = e.target.checked;
|
|
19
|
+
this.forceUpdate();
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
private maxRemainingAsgsChange = (e: React.ChangeEvent<HTMLInputElement>) => {
|
|
23
|
+
this.props.command.maxRemainingAsgs = parseInt(e.target.value, 10);
|
|
24
|
+
this.forceUpdate();
|
|
25
|
+
};
|
|
26
|
+
|
|
27
|
+
private delayBeforeDisableSecChange = (e: React.ChangeEvent<HTMLInputElement>) => {
|
|
28
|
+
this.props.command.delayBeforeDisableSec = parseInt(e.target.value, 10);
|
|
29
|
+
this.forceUpdate();
|
|
30
|
+
};
|
|
31
|
+
|
|
32
|
+
private delayBeforeScaleDownSecChange = (e: React.ChangeEvent<HTMLInputElement>) => {
|
|
33
|
+
this.props.command.delayBeforeScaleDownSec = parseInt(e.target.value, 10);
|
|
34
|
+
this.forceUpdate();
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
public render() {
|
|
38
|
+
const { command } = this.props;
|
|
39
|
+
return (
|
|
40
|
+
<div className="form-group">
|
|
41
|
+
<div className="col-md-12 checkbox" style={{ marginTop: 0 }}>
|
|
42
|
+
<label>
|
|
43
|
+
<input
|
|
44
|
+
type="checkbox"
|
|
45
|
+
checked={command.rollback?.onFailure ?? false}
|
|
46
|
+
onChange={this.rollbackOnFailureChange}
|
|
47
|
+
/>
|
|
48
|
+
Rollback to previous server group if deployment fails <HelpField id="strategy.redblack.rollback" />
|
|
49
|
+
</label>
|
|
50
|
+
</div>
|
|
51
|
+
<div className="col-md-12 checkbox">
|
|
52
|
+
<label>
|
|
53
|
+
<input type="checkbox" checked={command.scaleDown} onChange={this.scaleDownChange} />
|
|
54
|
+
Scale down replaced server groups to zero instances <HelpField id="strategy.redblack.scaleDown" />
|
|
55
|
+
</label>
|
|
56
|
+
</div>
|
|
57
|
+
<div className="col-md-12 form-inline">
|
|
58
|
+
<label>
|
|
59
|
+
Maximum number of server groups to leave
|
|
60
|
+
<HelpField id="strategy.redblack.maxRemainingAsgs" />
|
|
61
|
+
</label>
|
|
62
|
+
<input
|
|
63
|
+
className="form-control input-sm"
|
|
64
|
+
style={{ width: '50px' }}
|
|
65
|
+
type="number"
|
|
66
|
+
value={command.maxRemainingAsgs}
|
|
67
|
+
onChange={this.maxRemainingAsgsChange}
|
|
68
|
+
min="2"
|
|
69
|
+
/>
|
|
70
|
+
</div>
|
|
71
|
+
<div className="col-md-12 form-inline">
|
|
72
|
+
<label>
|
|
73
|
+
Wait Before Disable
|
|
74
|
+
<HelpField content="Time to wait before disabling all old server groups in this cluster" />
|
|
75
|
+
</label>
|
|
76
|
+
<input
|
|
77
|
+
className="form-control input-sm"
|
|
78
|
+
style={{ width: '60px' }}
|
|
79
|
+
min="0"
|
|
80
|
+
type="number"
|
|
81
|
+
value={command.delayBeforeDisableSec}
|
|
82
|
+
onChange={this.delayBeforeDisableSecChange}
|
|
83
|
+
placeholder="0"
|
|
84
|
+
/>
|
|
85
|
+
seconds
|
|
86
|
+
</div>
|
|
87
|
+
{command.scaleDown && (
|
|
88
|
+
<div className="col-md-12 form-inline" style={{ marginTop: '5px' }}>
|
|
89
|
+
<label>
|
|
90
|
+
Wait Before Scale Down
|
|
91
|
+
<HelpField content="Time to wait before scaling down all old server groups in this cluster" />
|
|
92
|
+
</label>
|
|
93
|
+
<input
|
|
94
|
+
className="form-control input-sm"
|
|
95
|
+
style={{ width: '60px' }}
|
|
96
|
+
min="0"
|
|
97
|
+
type="number"
|
|
98
|
+
value={command.delayBeforeScaleDownSec}
|
|
99
|
+
onChange={this.delayBeforeScaleDownSecChange}
|
|
100
|
+
placeholder="0"
|
|
101
|
+
/>
|
|
102
|
+
seconds
|
|
103
|
+
</div>
|
|
104
|
+
)}
|
|
76
105
|
</div>
|
|
77
|
-
)
|
|
78
|
-
|
|
79
|
-
|
|
106
|
+
);
|
|
107
|
+
}
|
|
108
|
+
}
|