Skip to content
Snippets Groups Projects
Select Git revision
  • 04f3b545bdec072f1f73c8cb8f261d52bbcc881b
  • master default protected
  • deploy-components-in-1-job
  • fix-exit-code-dsconfig
  • L2SS-2347-dithering-is-global-setting
  • refactor-control-power-properties
  • update-lcu-rollout-procedure
  • test-pytango-10.0.3
  • deploy-components-parallel
  • L2SS-2407-swap-iers-caltable-monitoring-port
  • L2SS-2357-fix-ruff
  • sync-up-with-meta-pypcc
  • stabilise-landing-page
  • all-stations-lofar2
  • v0.39.7-backports
  • Move-sdptr-to-v1.5.0
  • fix-build-ubuntu
  • tokens-in-env-files
  • fix-build
  • L2SS-2214-deploy-cdb
  • fix-missing-init
  • v0.56.0 protected
  • 0.53.0rc2
  • 0.53.0rc1
  • last-working-mapper-refactor
  • v0.52.9 protected
  • v0.52.8 protected
  • v0.52.7 protected
  • v0.55.5-r2 protected
  • v0.52.8-rc1 protected
  • v0.55.5 protected
  • v0.55.4 protected
  • 0.55.2.dev0
  • 0.55.1.dev0
  • 0.55.0.dev0
  • v0.54.0 protected
  • 0.53.2.dev0
  • 0.53.1.dev0
  • v0.52.3-r2 protected
  • remove-snmp-client
  • v0.52.3 protected
41 results

run_integration_test.sh

Blame
  • Code owners
    Assign users and groups as approvers for specific file changes. Learn more.
    run_integration_test.sh 1.46 KiB
    #!/bin/bash -e
    
    if [ -z "$LOFAR20_DIR" ]; then
        # We assume we aren't in the PATH, so we can derive our path.
        # We need our parent directory.
        LOFAR20_DIR_RELATIVE=$(dirname "$0")/..
    
        # As an absolute path
        LOFAR20_DIR=$(readlink -f "${LOFAR20_DIR_RELATIVE}")
    fi
    
    cd "$LOFAR20_DIR/docker-compose" || exit 1
    
    # Make sure builds are recent, and use our building parameters.
    make build
    
    # Start and stop sequence
    make stop device-sdp device-recv device-sst device-unb2 device-xst sdptr-sim recv-sim unb2-sim apsct-sim apspu-sim
    make start databaseds dsconfig elk
    
    # Give dsconfig and databaseds time to start
    sleep 60
    
    # Update the dsconfig
    # Do not remove `bash`, otherwise statement ignored by gitlab ci shell!
    bash "${LOFAR20_DIR}"/sbin/update_ConfigDb.sh "${LOFAR20_DIR}"/CDB/LOFAR_ConfigDb.json
    bash "${LOFAR20_DIR}"/sbin/update_ConfigDb.sh "${LOFAR20_DIR}"/CDB/stations/simulators_ConfigDb.json
    
    cd "$LOFAR20_DIR/docker-compose" || exit 1
    make start sdptr-sim recv-sim unb2-sim apsct-sim apspu-sim
    
    # Give the simulators time to start
    sleep 5
    
    make start device-sdp device-recv device-sst device-unb2 device-xst
    
    # Give devices time to restart
    # TODO(Corne Lukken): Use a nicer more reliable mechanism
    sleep 60
    
    # Start the integration test
    cd "$LOFAR20_DIR/docker-compose" || exit 1
    make start integration-test
    
    # Give devices time to restart
    sleep 60
    
    # Run the integration test with the output displayed on stdout
    docker start -a "${CONTAINER_NAME_PREFIX}"integration-test