chore(trading): upload market-sim logs (#5622)

This commit is contained in:
Ben 2024-01-15 20:56:52 +00:00 committed by GitHub
parent b751bcf17d
commit 0fb4348e9c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -227,3 +227,31 @@ jobs:
name: worker-logs
path: ./logs/
retention-days: 15
#----------------------------------------------
# ----- upload market-sim logs -----
#----------------------------------------------
- name: Find Directory
id: find-dir
run: |
DIR=$(find /tmp -type d -name "vega-sim-*" -print -quit)
if [[ -d "$DIR" ]]; then
echo "Found directory: $DIR"
echo "DIR=$DIR" >> $GITHUB_ENV
else
echo "Directory not found."
exit 1
fi
- name: Compress Files
if: env.DIR
run: |
tar -czvf ${{ github.workspace }}/market-sim-logs.tar.gz -C "$DIR" .
echo "Compressed files at ${{ github.workspace }}/market-sim-logs.tar.gz"
- name: Upload Compressed market-sim-logs
uses: actions/upload-artifact@v3
if: env.DIR
with:
name: market-sim-logs
path: ${{ github.workspace }}/market-sim-logs.tar.gz
retention-days: 15