@@ -3,6 +3,7 @@ package helmclient
3
3
import (
4
4
"bytes"
5
5
"context"
6
+ "time"
6
7
7
8
"helm.sh/helm/v3/pkg/chartutil"
8
9
@@ -115,6 +116,7 @@ func ExampleHelmClient_InstallOrUpgradeChart() {
115
116
Namespace : "default" ,
116
117
UpgradeCRDs : true ,
117
118
Wait : true ,
119
+ Timeout : 32 * time .Second ,
118
120
}
119
121
120
122
// Install a chart release.
@@ -132,6 +134,7 @@ func ExampleHelmClient_InstallOrUpgradeChart_useChartDirectory() {
132
134
Namespace : "default" ,
133
135
UpgradeCRDs : true ,
134
136
Wait : true ,
137
+ Timeout : 32 * time .Second ,
135
138
}
136
139
137
140
if _ , err := helmClient .InstallOrUpgradeChart (context .Background (), & chartSpec , nil ); err != nil {
@@ -147,6 +150,7 @@ func ExampleHelmClient_InstallOrUpgradeChart_useLocalChartArchive() {
147
150
Namespace : "default" ,
148
151
UpgradeCRDs : true ,
149
152
Wait : true ,
153
+ Timeout : 32 * time .Second ,
150
154
}
151
155
152
156
if _ , err := helmClient .InstallOrUpgradeChart (context .Background (), & chartSpec , nil ); err != nil {
@@ -162,6 +166,7 @@ func ExampleHelmClient_InstallOrUpgradeChart_useURL() {
162
166
Namespace : "default" ,
163
167
UpgradeCRDs : true ,
164
168
Wait : true ,
169
+ Timeout : 32 * time .Second ,
165
170
}
166
171
167
172
if _ , err := helmClient .InstallOrUpgradeChart (context .Background (), & chartSpec , nil ); err != nil {
@@ -177,6 +182,7 @@ func ExampleHelmClient_InstallOrUpgradeChart_useDefaultRollBackStrategy() {
177
182
Namespace : "default" ,
178
183
UpgradeCRDs : true ,
179
184
Wait : true ,
185
+ Timeout : 32 * time .Second ,
180
186
}
181
187
182
188
// Use the default rollback strategy offer by HelmClient (revert to the previous version).
@@ -213,6 +219,7 @@ func ExampleHelmClient_InstallOrUpgradeChart_useCustomRollBackStrategy() {
213
219
Namespace : "default" ,
214
220
UpgradeCRDs : true ,
215
221
Wait : true ,
222
+ Timeout : 32 * time .Second ,
216
223
}
217
224
218
225
// Use a custom rollback strategy (customRollBack needs to implement RollBack).
@@ -237,6 +244,7 @@ func ExampleHelmClient_LintChart() {
237
244
Namespace : "default" ,
238
245
UpgradeCRDs : true ,
239
246
Wait : true ,
247
+ Timeout : 32 * time .Second ,
240
248
ValuesYaml : `deployments:
241
249
etcdOperator: true
242
250
backupOperator: false` ,
@@ -254,6 +262,7 @@ func ExampleHelmClient_TemplateChart() {
254
262
Namespace : "default" ,
255
263
UpgradeCRDs : true ,
256
264
Wait : true ,
265
+ Timeout : 32 * time .Second ,
257
266
ValuesYaml : `deployments:
258
267
etcdOperator: true
259
268
backupOperator: false` ,
@@ -290,6 +299,7 @@ func ExampleHelmClient_UninstallRelease() {
290
299
ChartName : "stable/etcd-operator" ,
291
300
Namespace : "default" ,
292
301
Wait : true ,
302
+ Timeout : 32 * time .Second ,
293
303
DryRun : true ,
294
304
KeepHistory : true ,
295
305
}
@@ -337,6 +347,7 @@ func ExampleHelmClient_RollbackRelease() {
337
347
Namespace : "default" ,
338
348
UpgradeCRDs : true ,
339
349
Wait : true ,
350
+ Timeout : 32 * time .Second ,
340
351
}
341
352
342
353
// Rollback to the previous version of the release.
0 commit comments