PTG-Kitware / angel_system

BSD 3-Clause "New" or "Revised" License
7 stars 15 forks source link

Add built-in sanity check for using latest provisioned models #448

Open cameron-a-johnson opened 1 month ago

cameron-a-johnson commented 1 month ago

Here's an idea, or maybe this exists somewhere and I'm unaware:

We could add a loud warning somewhere for when the models in our model_files/ directory do not match hashes with those that we have in ansible/roles/provision-files/vars/main.yml

Purg commented 1 month ago

I just finished an experiment in this vein. This is definitely doable, but it does add a non-trival wait time to start up a container since some of our models are huge and take seconds to load in digets the checksum. Granted, I am using the python hashlib functionality to start, maybe a subprocess to use sha*sum is more appropriate/faster.

Purg commented 1 month ago

Even with things being threaded, this takes ~8 seconds to run.

Purg commented 1 month ago

image