Skip to content

Commit

Permalink
Merge pull request #3467 from manyfold3d/tunnel-configs
Browse files Browse the repository at this point in the history
Configure SSL and hostname in dev mode for use with ngrok tunnels
  • Loading branch information
Floppy authored Jan 22, 2025
2 parents b69792c + 4738303 commit 5184b59
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions config/environments/development.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@
# Enable server timing
config.server_timing = true

# Configure SSL and hostname in dev mode for use with ngrok tunnels
config.assume_ssl = config.force_ssl = (ENV.fetch("HTTPS_ONLY", nil) === "enabled")
config.hosts << ENV["PUBLIC_HOSTNAME"] if ENV.key?("PUBLIC_HOSTNAME")

# Enable/disable caching. By default caching is disabled.
# Run rails dev:cache to toggle caching.
if Rails.root.join("tmp/caching-dev.txt").exist?
Expand Down

0 comments on commit 5184b59

Please sign in to comment.