ruby on rails - Checking in configuration files with sensitive information into code repos -


what best strategy in regards checking in sensitive information git? example, database connection credentials, api keys, etc. rails app, best add environment files .gitignore?

thanks.

your best bet use environment variables.

check out these 2 links. second link show how keep sensitive information secure using environment variables store sensitive data.

rails environment variables

environment variables in ruby on rails