From ea6f4c8c107f2f3117c38b49e767ee1e49b64886 Mon Sep 17 00:00:00 2001 From: Teresa Noviello Date: Tue, 2 Nov 2021 16:00:45 +0000 Subject: [PATCH] not intended for public repository, removing with BFG repo cleaner --- agent.yaml | 41 -------------------------------- traces_logger.sh | 62 ------------------------------------------------ 2 files changed, 103 deletions(-) delete mode 100755 agent.yaml delete mode 100755 traces_logger.sh diff --git a/agent.yaml b/agent.yaml deleted file mode 100755 index 95683fc..0000000 --- a/agent.yaml +++ /dev/null @@ -1,41 +0,0 @@ -version: '3' -services: - - agent: - # The default image is set to the static one - image: ${AGENT_IMAGE:-containers.instana.io/instana/release/agent/static:latest} - # image: containers.instana.io/instana/release/agent/static:latest - # To use the dynamic agent (for example, to test the latest Java version), use this image instead: - # image: instana/agent:latest - pid: "host" - privileged: true - volumes: - - /var/run:/var/run - - /run:/run - - /dev:/dev - - /sys:/sys - - /var/log:/var/log - # Mount the logs directly so we can directly access the span-*.log files to check the produced spans. - # - ./agent/logs:/opt/instana/agent/data/log - - ${INSTANA_AGENT_LOGS_VOLUME:-./agent/logs}:/opt/instana/agent/data/log - - ./agent-configuration/com.instana.agent.main.sender.File.cfg:/opt/instana/agent/etc/instana/com.instana.agent.main.sender.File.cfg - environment: - - INSTANA_AGENT_ENDPOINT=${INSTANA_AGENT_ENDPOINT} - - INSTANA_AGENT_ENDPOINT_PORT=${INSTANA_AGENT_ENDPOINT_PORT} - - INSTANA_AGENT_KEY=${INSTANA_AGENT_KEY} - - INSTANA_DOWNLOAD_KEY=${INSTANA_DOWNLOAD_KEY} - - INSTANA_AGENT_ZONE=${INSTANA_AGENT_ZONE} - - INSTANA_MVN_REPOSITORY_FEATURES_PATH=artifactory/features-internal@id=features@snapshots@snapshotsUpdate=always - - INSTANA_MVN_REPOSITORY_SHARED_PATH=artifactory/shared@id=shared@snapshots@snapshotsUpdate=always - - INSTANA_LOG_LEVEL=DEBUG - expose: - - "42699" - -#networks: -# robot-shop: - -networks: - default: - external: - #name: robot-shop - name: robot-shop_robot-shop diff --git a/traces_logger.sh b/traces_logger.sh deleted file mode 100755 index 5caa6e8..0000000 --- a/traces_logger.sh +++ /dev/null @@ -1,62 +0,0 @@ -#!/bin/bash -x -# The script starts a dockerised instana-agent that is logging all the traces - -AGENT_STATIC_IMAGE=containers.instana.io/instana/release/agent/static:latest -AGENT_DYNAMIC_IMAGE=instana/agent:latest -INSTANA_AGENT_LOGS_VOLUME_DEFAULT="${PWD}/agent/logs" - -# get the agent image info -eval $(egrep '[A-Z]+=' .env | egrep -v "^#[ ]*") - -if [ ! -v $AGENT_IMAGE ]; then - echo "Info: the AGENT_IMAGE variable is not set. The agent image will be set to a default choice. If you want a different behaviour, please set AGENT_IMAGE in your .env file and restart the process."; -fi; - -if [ ! -v $INSTANA_AGENT_LOGS_VOLUME ]; then - echo "Info: the INSTANA_AGENT_LOGS_VOLUME variable is not set. The agent image will be set to a default choice. If you want a different behaviour, please set INSTANA_AGENT_LOGS_VOLUME in your .env file and restart the process."; - INSTANA_AGENT_LOGS_VOLUME=${INSTANA_AGENT_LOGS_VOLUME_DEFAULT} -fi - -rm -f "${INSTANA_AGENT_LOGS_VOLUME}/*.log" -mkdir -p ${INSTANA_AGENT_LOGS_VOLUME} - -#CHECKING THE NETWORK REQUIREMENTS -docker network ls|egrep "robot-shop_robot-shop" > /dev/null 2>&1 -Ret=$? - -if [ $Ret != 0 ]; then - echo "Warning: robot-shop dedicated network doesn't exist, the script will attempt to create it." - docker network create "robot-shop_robot-shop" > /dev/null 2>&1 - Ret=$? - if [ $Ret != 0 ]; then - echo "Warning: it was not possible to create robot-shop dedicated network. Possibly docker-compose will fix this itch, good luck :-) " - else - echo "Info: it was possible to create robot-shop dedicated network. " - fi -fi - -echo "Starting the traces-logging agent in the backgroud" -docker-compose -f agent.yaml up -d -echo "Info: the docker agent container is running. You can check the current operations with \"tail -100f agent/logs/agent.log\"" - -echo "Check: waiting for the agent discovery-time" -# wait for for sensors discovery a maximum of 10 minutes -elapsedTime=5 -while [ $elapsedTime -lt 300 ]; do - if [[ $(grep -i -c "Discovery time" ${INSTANA_AGENT_LOGS_VOLUME}/agent.log) -gt 1 ]]; then - break - else - echo "Check: Process discovery not completed after $elapsedTime s. Retrying ..." - ((elapsedTime += 5)) - sleep 5 - fi -done -# wait one minute to catch possible errors in PID sensor activation -echo "Check: waiting to catch possible errors in PID sensor activation" -sleep 60 - -echo "Info: starting robot-shop apps" -docker-compose -f docker-compose.yaml up -d - -cd load-gen -./load-gen.sh -v