@@ -4,6 +4,9 @@ _base: string
4
4
_rules : [...]
5
5
controllerArgs : [...]
6
6
_targetNamespace : string
7
+ // imageControllerDefaultArgs: controllerArgs + [
8
+ // "--events-addr=" + "http://fluxcd-notification-controller." + _targetNamespace + ".svc:9090"
9
+ // ]
7
10
8
11
imageAutomationController : {
9
12
// About this name, refer to #429 for details.
@@ -12,12 +15,28 @@ imageAutomationController: {
12
15
dependsOn : [" fluxcd-ns " ]
13
16
properties : {
14
17
imagePullPolicy : " IfNotPresent "
15
- image : _base + " fluxcd/image-automation-controller:v0.36 .0 "
18
+ image : _base + " fluxcd/image-automation-controller:v0.39 .0 "
16
19
env : [
17
20
{
18
21
name : " RUNTIME_NAMESPACE "
19
22
value : _targetNamespace
20
23
},
24
+ {
25
+ name : " GOMAXPROCS "
26
+ valueFrom : {
27
+ resourceFieldRef : {
28
+ resource : " limits.cpu "
29
+ }
30
+ }
31
+ },
32
+ {
33
+ name : " GOMEMLIMIT "
34
+ valueFrom : {
35
+ resourceFieldRef : {
36
+ resource : " limits.memory "
37
+ }
38
+ }
39
+ }
21
40
]
22
41
livenessProbe : {
23
42
httpGet : {
@@ -68,14 +87,54 @@ imageAutomationController: {
68
87
" app " : " image-automation-controller "
69
88
}
70
89
},
90
+ {
91
+ type : " annotations "
92
+ properties : {
93
+ " prometheus.io/port " : " 8080 "
94
+ " prometheus.io/scrape " : " true "
95
+ }
96
+ },
97
+ {
98
+ type : " resource "
99
+ properties : {
100
+ limits : {
101
+ if parameter .imageAutomationControllerResourceLimits .cpu != _|_ {
102
+ cpu : parameter .imageAutomationControllerResourceLimits .cpu
103
+ }
104
+ if parameter .imageAutomationControllerResourceLimits .cpu == _|_ {
105
+ cpu : deploymentResources .limits .cpu
106
+ }
107
+ if parameter .imageAutomationControllerResourceLimits .memory != _|_ {
108
+ memory : parameter .imageAutomationControllerResourceLimits .memory
109
+ }
110
+ if parameter .imageAutomationControllerResourceLimits .memory == _|_ {
111
+ memory : deploymentResources .limits .memory
112
+ }
113
+ }
114
+ requests : {
115
+ if parameter .imageAutomationControllerResourceRequests .cpu != _|_ {
116
+ cpu : parameter .imageAutomationControllerResourceRequests .cpu
117
+ }
118
+ if parameter .imageAutomationControllerResourceRequests .cpu == _|_ {
119
+ cpu : deploymentResources .requests .cpu
120
+ }
121
+ if parameter .imageAutomationControllerResourceRequests .memory != _|_ {
122
+ memory : parameter .imageAutomationControllerResourceRequests .memory
123
+ }
124
+ if parameter .imageAutomationControllerResourceRequests .memory == _|_ {
125
+ memory : deploymentResources .requests .memory
126
+ }
127
+ }
128
+ }
129
+ },
71
130
{
72
131
type : " command "
73
132
properties : {
74
133
if parameter .imageAutomationControllerOptions != _|_ {
75
- args : controllerArgs + parameter .imageAutomationControllerOptions
134
+ args : eventAddrArgs + parameter .imageAutomationControllerOptions
76
135
}
77
136
if parameter .imageAutomationControllerOptions == _|_ {
78
- args : controllerArgs
137
+ args : eventAddrArgs
79
138
}
80
139
}
81
140
},
0 commit comments