galaxyproject / galaxy-helm

Minimal setup required to run Galaxy under Kubernetes
MIT License
38 stars 36 forks source link

Move the probedb.py script #467

Open ksuderman opened 2 months ago

ksuderman commented 2 months ago

The probedb.py script that is used for the livenessProbe (and others) lives in the /tmp directory, so eventually the tmp cleanup job to be added in #448 will break the probes. Move the script somewhere like /usr/local/bin/ before #448 is merged.

nuwang commented 2 months ago

The mapped file should be read-only and not deletable I believe, so I don't think the cleanup screen will affect it, but if there's a better location we can move it to, that would still make sense.

ksuderman commented 2 months ago

I just checked on a cluster I just launched and the probedb.py script is rw for root and the cron jobs run as root by default. We could set the mode to 444 or 400 or something similar, but that might just lead to unexpected surprises in the future. I'll get a PR for this ASAP since the maintenance PR was merged.

nuwang commented 2 months ago

Can root actually delete it though? I think even root should be unable to affect that file.

ksuderman commented 2 months ago

Good point. Since it is a config map and not an actual file it shouldn't be deletable. I'll test, but I would feel better if the script didn't live in /tmp

ksuderman commented 2 months ago

This is a bit of a false alarm. The cronjob cleans up /galaxy/server/database/tmp and not the /tmp directory where the probedb script lives. It might be a best practice to move it somewhere like /usr/local/bin, but it is not urgent.