Skip to content

Commit

Permalink
Do not call "bash -c" unnecessarily as entry points
Browse files Browse the repository at this point in the history
Closes: OSPRH-680
  • Loading branch information
ralonsoh committed Mar 14, 2024
1 parent d7d87d3 commit 2373da2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
7 changes: 2 additions & 5 deletions pkg/ovncontroller/daemonset.go
Original file line number Diff line number Diff line change
Expand Up @@ -131,14 +131,11 @@ func DaemonSet(
}

ovnControllerCmd = []string{
"/bin/bash", "-c",
"/usr/local/bin/container-scripts/net_setup.sh && ovn-controller",
}
ovnControllerArgs = []string{
strings.Join(
append(
[]string{"/usr/local/bin/container-scripts/net_setup.sh && ovn-controller"},
append(ovnControllerTLSArgs, "--pidfile", "unix:/run/openvswitch/db.sock")...,
),
append(ovnControllerTLSArgs, "--pidfile", "unix:/run/openvswitch/db.sock")...,
" ",
),
}
Expand Down
2 changes: 1 addition & 1 deletion pkg/ovndbcluster/statefulset.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ func StatefulSet(
var preStopCmd []string
var postStartCmd []string
cmd := []string{"/usr/bin/dumb-init"}
args := []string{"--single-child", "--", "/bin/bash", "-c", ServiceCommand}
args := []string{"--single-child", "--", ServiceCommand}
//
// https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/
//
Expand Down

0 comments on commit 2373da2

Please sign in to comment.