Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1202 - Standardize config files #4308

Open
wants to merge 1 commit into
base: development
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ jobs:
RAILS_ENV: test
MYSQL_ROOT_PASSWORD: password
MYSQL_SOCKET: /tmp/mysql.sock
SECRET_KEY_BASE: secret_key_base
DEVISE_SECRET_KEY: devise_secret_key
DEVISE_PEPPER: ''
steps:
- name: Checkout code
uses: actions/checkout@v3
Expand Down
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ mongo.log

/public/assets/

config/database.yml
config/environments/development.rb
db/schema.rb

Expand Down
7 changes: 3 additions & 4 deletions config/initializers/devise.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# confirmation, reset password and unlock tokens in the database.
# Devise will use the `secret_key_base` as its `secret_key`
# by default. You can change it below and use your own secret key.
config.secret_key = 'cba9d1f2e2f6690b06c01a5a325d4508dde18fca6952cf0a401f1ca1309879b755707e70e16b4d51d56a4cc92f7cd504dfc84296986e2a892abd1b9805a1abdf'
config.secret_key = ENV['DEVISE_SECRET_KEY']

# ==> Controller configuration
# Configure the parent class to the devise controllers.
Expand Down Expand Up @@ -111,13 +111,12 @@
# a value less than 10 in other environments. Note that, for bcrypt (the default
# algorithm), the cost increases exponentially with the number of stretches (e.g.
# a value of 20 is already extremely slow: approx. 60 seconds for 1 calculation).
# config.stretches = Rails.env.test? ? 1 : 11
# config.stretches = Rails.env.test? ? 1 : 11
config.stretches = 1

# Set up a pepper to generate the hashed password.
# config.pepper = 'b0564e7f7af0f749de25a955f9a8a9361c5da8b74aa0648b849835c87ca7406b96e3376dc049a27eaa5b0c0342b5ad2ff3c221d3918b219c4187dfb8b7a0ccd6'
config.pepper = "" # This needs to be externalized and fixed.

config.pepper = ENV['DEVISE_PEPPER']

# Send a notification to the original email when the user's email is changed.
# config.send_email_changed_notification = false
Expand Down
2 changes: 1 addition & 1 deletion config/initializers/secret_token.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@

# Make sure your secret_key_base is kept private
# if you're sharing your code publicly.
Fromthepage::Application.config.secret_key_base = '37836f846a22dd28a11ccacc3e4f3c399d19dec8250db04dbec6aacdd727344fa5f056c18a3c50369fcbea58840e578435f108eb85f5bf264f88e503026993fa'
Fromthepage::Application.config.secret_key_base = ENV['SECRET_KEY_BASE']
Loading