From 71f546508820dc98236e9e9ce64e443bbbbe828b Mon Sep 17 00:00:00 2001 From: Ilya Polyakovskiy Date: Fri, 11 Feb 2022 16:56:45 +0300 Subject: [PATCH] set net.ipv4.tcp_keepalive_time=60 only on Linux runners --- .github/workflows/workflow.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/workflow.yaml b/.github/workflows/workflow.yaml index 22a89e180..a8ed5fdd7 100644 --- a/.github/workflows/workflow.yaml +++ b/.github/workflows/workflow.yaml @@ -29,7 +29,7 @@ jobs: env: BUILDBUDDY_API_KEY: ${{ secrets.BUILDBUDDY_API_KEY }} run: | - sudo sysctl -w net.ipv4.tcp_keepalive_time=60 + [[ ${{ runner.os }} == Linux ]] && sudo sysctl -w net.ipv4.tcp_keepalive_time=60 case ${{ runner.os }} in macOS) BUILD_CONFIG=ci-macos-nixpkgs;; Linux) BUILD_CONFIG=ci-linux-nixpkgs;; @@ -123,7 +123,7 @@ jobs: BUILDBUDDY_API_KEY: ${{ secrets.BUILDBUDDY_API_KEY }} shell: bash run: | - sudo sysctl -w net.ipv4.tcp_keepalive_time=60 + [[ ${{ runner.os }} == Linux ]] && sudo sysctl -w net.ipv4.tcp_keepalive_time=60 case ${{ runner.os }} in macOS) BUILD_CONFIG=ci-macos-bindist;; Linux) BUILD_CONFIG=ci-linux-bindist;;