Skip to content

Commit

Permalink
Replace deprecated netstat with ss
Browse files Browse the repository at this point in the history
Signed-off-by: Tom Fenech <[email protected]>
  • Loading branch information
fenech committed May 25, 2023
1 parent c711a39 commit bef9d2f
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
2 changes: 1 addition & 1 deletion dockerfiles/alpine/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ ADD test/ /tests
RUN /tests/all.sh

FROM resource AS integrationtests
RUN apk --no-cache add squid
RUN apk --no-cache add iproute2-ss squid
ADD test/ /tests/test
ADD integration-tests /tests/integration-tests
RUN /tests/integration-tests/integration.sh
Expand Down
2 changes: 1 addition & 1 deletion dockerfiles/ubuntu/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ ADD test/ /tests
RUN /tests/all.sh

FROM resource AS integrationtests
RUN apt update && apt install -y net-tools squid
RUN apt update && apt install -y iproute2 squid
ADD test/ /tests/test
ADD integration-tests /tests/integration-tests
RUN /tests/integration-tests/integration.sh
Expand Down
5 changes: 1 addition & 4 deletions integration-tests/helpers.sh
Original file line number Diff line number Diff line change
Expand Up @@ -139,10 +139,7 @@ __run() {
set +e
attempts=10
while (( attempts )); do
( netstat -an | grep LISTEN | grep 3128 ) >/dev/null 2>&1
rc=$?

if [[ $rc == 0 ]]; then
if ss -ltn | grep -q 3128; then
break
else
echo "Waiting for proxy to finish reconfiguring..."
Expand Down

0 comments on commit bef9d2f

Please sign in to comment.