Tezt/cloud: allow to retrieve daemons daily logs
This MR introduces a new --retrieve-daily-logs <PATH> command line option that allows to retrieve the daily logs generated by the daemons.
For now:
- it only supports the L1 node and dal node daemons -- upcoming MRs
- it is disabled when
--proxyis used -- the proxy interferes with tezt generated paths, to be implemented - there is no GCP bucket upload -- to be implemented
Manually testing the MR
Run a dummy scenario such as:
dune exec tezt/tests/cloud/main.exe -- DAL --localhost -v --tezt-cloud dal --producers 1 --log-file experiment.log --retrieve-daily-logs ./experiment_logs
Running without --localhost should work as well
You should observe something like this at the end of the scenario
[10:37:03.424] Retrieving logs from bootstrap
[10:37:03.424] [scp#7] scp -r -O -o 'StrictHostKeyChecking=no' -i /home/vicall/.ssh/dal-tf -P 30000 root@127.0.0.1:/tmp/tezt-112884/1/bootstrap-node/daily_logs ./experiment_logs/bootstrap/bootstrap-node/daily_logs
[10:37:03.430] scp#7 exited with code 0.
[10:37:03.430] Retrieving logs from attester-0
[10:37:03.430] [scp#8] scp -r -O -o 'StrictHostKeyChecking=no' -i /home/vicall/.ssh/dal-tf -P 30050 root@127.0.0.1:/tmp/tezt-112884/1/baker-dal-node-0/daily_logs ./experiment_logs/attester-0/baker-dal-node-0/daily_logs
[10:37:03.436] scp#8 exited with code 0.
[10:37:03.436] Retrieving logs from attester-0
[10:37:03.436] [scp#9] scp -r -O -o 'StrictHostKeyChecking=no' -i /home/vicall/.ssh/dal-tf -P 30050 root@127.0.0.1:/tmp/tezt-112884/1/baker-node-0/daily_logs ./experiment_logs/attester-0/baker-node-0/daily_logs
[10:37:03.441] scp#9 exited with code 0.
[10:37:03.441] Retrieving logs from dal-producer-0
[10:37:03.441] [scp#10] scp -r -O -o 'StrictHostKeyChecking=no' -i /home/vicall/.ssh/dal-tf -P 30100 root@127.0.0.1:/tmp/tezt-112884/1/producer-dal-node-0/daily_logs ./experiment_logs/dal-producer-0/producer-dal-node-0/daily_logs
[10:37:03.447] scp#10 exited with code 0.
[10:37:03.447] Retrieving logs from dal-producer-0
[10:37:03.447] [scp#11] scp -r -O -o 'StrictHostKeyChecking=no' -i /home/vicall/.ssh/dal-tf -P 30100 root@127.0.0.1:/tmp/tezt-112884/1/producer-node-0/daily_logs ./experiment_logs/dal-producer-0/producer-node-0/daily_logs
[10:37:03.451] scp#11 exited with code 0.
[10:37:03.451] Shutting down processes...
and the ./experiment_logs folder should be populated with
experiment_logs
├── attester-0
│ ├── baker-dal-node-0
│ │ └── daily_logs
│ │ └── daily-20250724.log
│ └── baker-node-0
│ └── daily_logs
│ └── daily-20250724.log
├── bootstrap
│ ├── bootstrap-dal-node
│ │ └── daily_logs
│ │ └── daily-20250724.log
│ └── bootstrap-node
│ └── daily_logs
│ └── daily-20250724.log
└── dal-producer-0
├── producer-dal-node-0
│ └── daily_logs
│ └── daily-20250724.log
└── producer-node-0
└── daily_logs
└── daily-20250724.log
16 directories, 6 files
Checklist
-
Document the interface of any function added or modified (see the coding guidelines) -
Document any change to the user interface, including configuration parameters (see node configuration) -
Provide automatic testing (see the testing guide). -
For new features and bug fixes, add an item in the appropriate changelog ( docs/protocols/alpha.rstfor the protocol and the environment,CHANGES.rstat the root of the repository for everything else). -
Select suitable reviewers using the Reviewersfield below. -
Select as Assigneethe next person who should take action on that MR