Skip to content

Commit

Permalink
Remove pod container Command for route agent and gateway
Browse files Browse the repository at this point in the history
...since the associated Docker files specify an ENTRYPOINT.
This addresses a FIXME.

Signed-off-by: Tom Pantelis <[email protected]>
  • Loading branch information
tpantelis committed Jul 26, 2024
1 parent e0ca350 commit f9f4c99
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 5 deletions.
1 change: 0 additions & 1 deletion controllers/submariner/gateway_resources.go
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,6 @@ func newGatewayPodTemplate(cr *v1alpha1.Submariner, name string, podSelectorLabe
Name: name,
Image: getImagePath(cr, opnames.GatewayImage, names.GatewayComponent),
ImagePullPolicy: images.GetPullPolicy(cr.Spec.Version, cr.Spec.ImageOverrides[names.GatewayComponent]),
Command: []string{"submariner.sh"},
SecurityContext: &corev1.SecurityContext{
Capabilities: &corev1.Capabilities{
Add: []corev1.Capability{"net_admin"},
Expand Down
2 changes: 0 additions & 2 deletions controllers/submariner/route_agent_resources.go
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,6 @@ func newRouteAgentDaemonSet(cr *v1alpha1.Submariner, name string) *appsv1.Daemon
Name: name,
Image: getImagePath(cr, opnames.RouteAgentImage, names.RouteAgentComponent),
ImagePullPolicy: images.GetPullPolicy(cr.Spec.Version, cr.Spec.ImageOverrides[names.RouteAgentComponent]),
// FIXME: Should be entrypoint script, find/use correct file for routeagent
Command: []string{"submariner-route-agent.sh"},
SecurityContext: &corev1.SecurityContext{
Capabilities: &corev1.Capabilities{Add: []corev1.Capability{"ALL"}},
AllowPrivilegeEscalation: ptr.To(true),
Expand Down
2 changes: 0 additions & 2 deletions scripts/test/system.sh
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,6 @@ function verify_subm_gateway_pod() {
validate_pod_container_equals 'securityContext.privileged' 'true'
validate_pod_container_equals 'securityContext.readOnlyRootFilesystem' 'false'
validate_pod_container_equals 'securityContext.runAsNonRoot' 'false'
validate_pod_container_has 'command' 'submariner.sh'

jq -r '.spec.containers[].env' "$json_file"
validate_pod_container_env 'SUBMARINER_NAMESPACE' "$subm_ns"
Expand Down Expand Up @@ -322,7 +321,6 @@ function verify_subm_routeagent_pod() {
validate_pod_container_equals 'securityContext.privileged' 'true'
validate_pod_container_equals 'securityContext.readOnlyRootFilesystem' 'false'
validate_pod_container_equals 'securityContext.runAsNonRoot' 'false'
validate_pod_container_has 'command' 'submariner-route-agent.sh'

jq -r '.spec.containers[].env' "$json_file"
validate_pod_container_env 'SUBMARINER_NAMESPACE' "$subm_ns"
Expand Down

0 comments on commit f9f4c99

Please sign in to comment.