Skip to content

Commit 9ca9b3d

Browse files
committed
Restoring lost defaults for ansible env vars
Signed-off-by: Jiri Podivin <[email protected]>
1 parent 991d251 commit 9ca9b3d

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

pkg/dataplane/util/ansible_execution.go

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,9 +63,10 @@ func AnsibleExecution(
6363
}
6464

6565
ansibleEE := EEJob{
66-
Name: executionName,
67-
Namespace: deployment.GetNamespace(),
68-
Labels: labels,
66+
Name: executionName,
67+
Namespace: deployment.GetNamespace(),
68+
Labels: labels,
69+
EnvConfigMapName: "openstack-aee-default-env",
6970
}
7071

7172
ansibleEE.NetworkAttachments = aeeSpec.NetworkAttachments

pkg/dataplane/util/ansibleee.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -230,10 +230,14 @@ func labelsForOpenStackAnsibleEE(name string, labels map[string]string) map[stri
230230
}
231231

232232
func (a *EEJob) addEnvFrom(job *batchv1.Job) {
233+
// Add optional config map
234+
235+
optional := true
233236
job.Spec.Template.Spec.Containers[0].EnvFrom = []corev1.EnvFromSource{
234237
{
235238
ConfigMapRef: &corev1.ConfigMapEnvSource{
236239
LocalObjectReference: corev1.LocalObjectReference{Name: a.EnvConfigMapName},
240+
Optional: &(optional),
237241
},
238242
},
239243
}

0 commit comments

Comments
 (0)