Skip to content

Commit

Permalink
Trying something else
Browse files Browse the repository at this point in the history
Signed-off-by: Loic Pottier <[email protected]>
  • Loading branch information
lpottier committed Oct 10, 2024
1 parent 2aa7dab commit 20ee753
Showing 1 changed file with 59 additions and 50 deletions.
109 changes: 59 additions & 50 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -452,58 +452,67 @@ jobs:
-Damqpcpp_DIR=$AMS_AMQPCPP_PATH \
$GITHUB_WORKSPACE
make
- name: Run tests Torch=On FAISS=On RMQ=On AMSlib RabbitMQ egress
run: |
cd build
source /spack/share/spack/setup-env.sh
spack env activate -p /ams-spack-env
# We overwrite the rmq.json created by CMake
echo """{
\"db\": {
\"dbType\": \"rmq\",
\"rmq_config\": {
\"rabbitmq-name\": \"rabbit\",
\"rabbitmq-user\": \"${RABBITMQ_USER}\",
\"rabbitmq-password\": \"${RABBITMQ_PASS}\",
\"service-port\": ${RABBITMQ_PORT},
\"service-host\": \"${RABBITMQ_HOST}\",
\"rabbitmq-vhost\": \"/\",
\"rabbitmq-outbound-queue\": \"test-ci\",
\"rabbitmq-exchange\": \"ams-fanout\",
\"rabbitmq-routing-key\": \"training\"
},
\"update_surrogate\": false
},
\"ml_models\": {},
\"domain_models\": {}
}""" > $GITHUB_WORKSPACE/build/tests/AMSlib/rmq.json
# echo """{
# \"rabbitmq-name\": \"rabbit\",
# \"rabbitmq-user\": \"${RABBITMQ_USER}\",
# \"rabbitmq-password\": \"${RABBITMQ_PASS}\",
# \"service-port\": ${RABBITMQ_PORT},
# \"service-host\": \"${RABBITMQ_HOST}\",
# \"rabbitmq-vhost\": \"/\",
# \"rabbitmq-outbound-queue\": \"test-ci\",
# \"rabbitmq-exchange\": \"ams-fanout\",
# \"rabbitmq-routing-key\": \"training\"
# }""" > $GITHUB_WORKSPACE/rmq.json
# python3 $GITHUB_WORKSPACE/tools/rmq/send_ams.py -c $GITHUB_WORKSPACE/rmq.json -r test3 -n 10
AMS_LOG_LEVEL=debug AMS_OBJECTS=$GITHUB_WORKSPACE/build/tests/AMSlib/rmq.json $GITHUB_WORKSPACE/build/tests/AMSlib/ams_rmq 0 8 9 "double" 2 1024 2 #> $GITHUB_WORKSPACE/output.txt 2>&1 || $GITHUB_WORKSPACE/output.txt
#ctest --output-on-failure -R AMSEndToEndFromJSON::NoModel::Double::DB::rmq::HOST
- name: Setup upterm session
uses: lhotari/action-upterm@v1
with:
## limits ssh access and adds the ssh public key for the user which triggered the workflow
limit-access-to-actor: true
env:
RABBITMQ_USER: guest
RABBITMQ_PASS: guest
RABBITMQ_HOST: rabbitmq
RABBITMQ_PORT: 5672
- name: Persist logs
run: |
pwd
ls -alh $GITHUB_WORKSPACE/output.txt
cat $GITHUB_WORKSPACE/output.txt
shell: bash
# - name: Run tests Torch=On FAISS=On RMQ=On AMSlib RabbitMQ egress
# run: |
# cd build
# source /spack/share/spack/setup-env.sh
# spack env activate -p /ams-spack-env

# # We overwrite the rmq.json created by CMake
# echo """{
# \"db\": {
# \"dbType\": \"rmq\",
# \"rmq_config\": {
# \"rabbitmq-name\": \"rabbit\",
# \"rabbitmq-user\": \"${RABBITMQ_USER}\",
# \"rabbitmq-password\": \"${RABBITMQ_PASS}\",
# \"service-port\": ${RABBITMQ_PORT},
# \"service-host\": \"${RABBITMQ_HOST}\",
# \"rabbitmq-vhost\": \"/\",
# \"rabbitmq-outbound-queue\": \"test-ci\",
# \"rabbitmq-exchange\": \"ams-fanout\",
# \"rabbitmq-routing-key\": \"training\"
# },
# \"update_surrogate\": false
# },
# \"ml_models\": {},
# \"domain_models\": {}
# }""" > $GITHUB_WORKSPACE/build/tests/AMSlib/rmq.json

# # echo """{
# # \"rabbitmq-name\": \"rabbit\",
# # \"rabbitmq-user\": \"${RABBITMQ_USER}\",
# # \"rabbitmq-password\": \"${RABBITMQ_PASS}\",
# # \"service-port\": ${RABBITMQ_PORT},
# # \"service-host\": \"${RABBITMQ_HOST}\",
# # \"rabbitmq-vhost\": \"/\",
# # \"rabbitmq-outbound-queue\": \"test-ci\",
# # \"rabbitmq-exchange\": \"ams-fanout\",
# # \"rabbitmq-routing-key\": \"training\"
# # }""" > $GITHUB_WORKSPACE/rmq.json

# # python3 $GITHUB_WORKSPACE/tools/rmq/send_ams.py -c $GITHUB_WORKSPACE/rmq.json -r test3 -n 10
# # #> $GITHUB_WORKSPACE/output.txt 2>&1 || $GITHUB_WORKSPACE/output.txt
# AMS_LOG_LEVEL=debug AMS_OBJECTS=$GITHUB_WORKSPACE/build/tests/AMSlib/rmq.json $GITHUB_WORKSPACE/build/tests/AMSlib/ams_rmq 0 8 9 "double" 2 1024 2

# #ctest --output-on-failure -R AMSEndToEndFromJSON::NoModel::Double::DB::rmq::HOST
# env:
# RABBITMQ_USER: guest
# RABBITMQ_PASS: guest
# RABBITMQ_HOST: rabbitmq
# RABBITMQ_PORT: 5672
# - name: Persist logs
# run: |
# pwd
# ls -alh $GITHUB_WORKSPACE/output.txt
# cat $GITHUB_WORKSPACE/output.txt

0 comments on commit 20ee753

Please sign in to comment.