I am looking at assigning variables to an entry point script at runtime. I am working on dockerizing one of our internal applications. In my ENTRYPOINT script I have defined some logic to create a database.php file which will include the DB Username and Password. I'd like to run something similar to the following. How do I define DB_USERNAME
and DB_PASSWORD
as values read on run time?
docker run -d --name some-app -e DB_USERNAME=secret_username -e DB_PASSWORD=securepassword