From 30003348ce182a53ea5e910bc0f331ea138f7202 Mon Sep 17 00:00:00 2001 From: wiz Date: Sun, 16 Mar 2025 12:49:26 +0900 Subject: [PATCH] ops: Fix premature socket close bug in nginx cache warmer scripts --- production/nginx-cache-heater | 2 +- production/nginx-cache-warmer | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/production/nginx-cache-heater b/production/nginx-cache-heater index 24ec8a061..e6dea270a 100755 --- a/production/nginx-cache-heater +++ b/production/nginx-cache-heater @@ -4,7 +4,7 @@ hostname=$(hostname) heat() { echo "$1" - curl -i -s "$1" | head -1 + curl -o /dev/null -s "$1" } heatURLs=( diff --git a/production/nginx-cache-warmer b/production/nginx-cache-warmer index f02091747..171f95430 100755 --- a/production/nginx-cache-warmer +++ b/production/nginx-cache-warmer @@ -6,19 +6,19 @@ slugs=(`curl -sSL https://${hostname}/api/v1/mining/pools/3y|jq -r -S '(.pools[] warmSlurp() { echo "$1" - curl -i -s -H 'User-Agent: Googlebot' "$1" | head -1 + curl -o /dev/null -s -H 'User-Agent: Googlebot' "$1" } warmUnfurl() { echo "$1" - curl -i -s -H 'User-Agent: Twitterbot' "$1" | head -1 + curl -o /dev/null -s -H 'User-Agent: Twitterbot' "$1" } warm() { echo "$1" - curl -i -s "$1" | head -1 + curl -o /dev/null -s "$1" } warmSlurpURLs=(