Skip to content

Commit

Permalink
fix: test function
Browse files Browse the repository at this point in the history
Signed-off-by: Lenin Mehedy <lenin.mehedy@swirldslabs.com>
  • Loading branch information
leninmehedy committed Sep 21, 2023
1 parent 337277c commit ac4cfba
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dev/scripts/gateway.sh
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ function expose_envoy_gateway_svc() {
}

function unexpose_envoy_gateway_svc() {
export GATEWAY_SVC_PID=$(ps aux | grep "kubectl port-forward svc/${ENVOY_SERVICE}" | sed -n 2p | awk '{ print $2 }')
export GATEWAY_SVC_PID=$(ps aux | grep "kubectl port-forward svc/${ENVOY_SERVICE}" | grep -v "grep" | sed -n 1p | awk '{ print $2 }')
[[ -z "${GATEWAY_SVC_PID}" ]] && echo "No Envoy Gateway Service PID is found" && return 0

if [[ "${GATEWAY_SVC_PID}" ]]; then
Expand Down

0 comments on commit ac4cfba

Please sign in to comment.