Skip to content

Commit

Permalink
pin prometheus to version 2.55.1 (#504)
Browse files Browse the repository at this point in the history
  • Loading branch information
nghtm authored Nov 21, 2024
1 parent fc1be0f commit d911db0
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,11 @@ generate_targets() {
}

# Retrieve the latest Prometheus version from GitHub releases
echo "Retrieving the latest Prometheus version..."
LATEST_VERSION=$(curl -s https://api.github.com/repos/prometheus/prometheus/releases/latest | grep -oP '"tag_name": "\K(.*?)(?=")' | sed 's/^v//')
#echo "Retrieving the latest Prometheus version..."
#LATEST_VERSION=$(curl -s https://api.github.com/repos/prometheus/prometheus/releases/latest | grep -oP '"tag_name": "\K(.*?)(?=")' | sed 's/^v//')

echo "Using pinned Prometheus version 2.55.1"
LATEST_VERSION=2.55.1

# Check if the latest version retrieval was successful
if [ -z "$LATEST_VERSION" ]; then
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,11 @@ if command -v prometheus &>/dev/null; then
echo "Prometheus is already installed. Skipping installation."
else
# Retrieve the latest Prometheus version from GitHub releases
echo "Retrieving the latest Prometheus version..."
LATEST_VERSION=$(curl -s https://api.github.com/repos/prometheus/prometheus/releases/latest | grep -oP '"tag_name": "\K(.*?)(?=")' | sed 's/^v//')
# echo "Retrieving the latest Prometheus version..."
# LATEST_VERSION=$(curl -s https://api.github.com/repos/prometheus/prometheus/releases/latest | grep -oP '"tag_name": "\K(.*?)(?=")' | sed 's/^v//')

echo "Using pinned Prometheus version 2.55.1"
LATEST_VERSION=2.55.1

# Check if the latest version retrieval was successful
if [ -z "$LATEST_VERSION" ]; then
Expand Down

0 comments on commit d911db0

Please sign in to comment.