github.com/pyroscope-io/pyroscope@v0.37.3-0.20230725203016-5f6947968bd0/benchmark/server-entrypoint.sh (about)

     1  #!/bin/bash
     2  
     3  cat /tmp/server.yml.example | grep -B 1000 'static-configs:' > /tmp/server.yml
     4  
     5  PYROBENCH_PULL_TARGETS="${PYROBENCH_PULL_TARGETS:-10}"
     6  
     7  echo "starting pyroscope with $PYROBENCH_PULL_TARGETS pull targets"
     8  
     9  for ((x=0 ; x<$PYROBENCH_PULL_TARGETS ; x++)); do
    10    echo "      - application: pyrobench-pull-target" >> /tmp/server.yml
    11    echo "        targets:"                           >> /tmp/server.yml
    12    echo "          - pyrobench:4042"                 >> /tmp/server.yml
    13    echo "        labels:"                            >> /tmp/server.yml
    14    echo "          pod: pod-$x"                      >> /tmp/server.yml
    15  done
    16  
    17  pyroscope server -config /tmp/server.yml