avalonmediasystem / avalon

Avalon Media System – Samvera Application
http://www.avalonmediasystem.org/
Apache License 2.0
94 stars 51 forks source link

Audit usage of environment variables #6096

Open masaball opened 3 weeks ago

masaball commented 3 weeks ago

Description

From slack:

John M. 12:14 PM My avalon-docker 7.5.0 instance isn't automatically deleting masterfiles from dropbox. The environment variable is set to MASTER_FILE_STRATEGY=delete in docker-compose.yml, however, the avalon container's settings.yml has master_file_management: strategy: 'none'. Shouldn't the former override the latter?

Looking into it, I found that we do not seem to look at that environment variable at all when managing the master file.

If there is an environment variable that we explicitly make available to implementers, we should probably be using it. Do we need to go through the list of available environment variables and make sure that they are actually being utilized?

Secondly, should we prioritize environment variables over the settings file? (Answer: yes!) In active_fedora_env.rb we prioritize the settings file. But in ac_mediainfo.rb we set the environment variable from the settings file if the variable has not already been set, implicitly prioritizing the variable.

Done Looks Like