diff options
| author | mo khan <mo@mokhan.ca> | 2021-07-10 20:04:25 -0600 |
|---|---|---|
| committer | mo khan <mo@mokhan.ca> | 2021-07-10 20:04:25 -0600 |
| commit | f6b5e73fd47c5695ab2bfb63f255c65deb33d165 (patch) | |
| tree | 58a1017e6f2c69542b19f22fbda24b7224c22902 | |
| parent | a970d44aa5e5c96751adb0b7fc263f6f025d59f5 (diff) | |
chore: connect to ngrok
| -rw-r--r-- | .env | 1 | ||||
| -rw-r--r-- | .gitignore | 1 | ||||
| -rw-r--r-- | .ruby-version | 2 | ||||
| -rw-r--r-- | Gemfile | 5 | ||||
| -rw-r--r-- | Gemfile.lock | 8 | ||||
| -rw-r--r-- | config/application.rb | 2 | ||||
| -rw-r--r-- | config/environments/development.rb | 2 | ||||
| -rw-r--r-- | config/puma.rb | 2 |
8 files changed, 16 insertions, 7 deletions
@@ -0,0 +1 @@ +NGROK_HOST=invalid.ngrok.io @@ -38,3 +38,4 @@ yarn-debug.log* config/*.pem Brewfile.lock.json +.env.local diff --git a/.ruby-version b/.ruby-version index 85588be..45418de 100644 --- a/.ruby-version +++ b/.ruby-version @@ -1 +1 @@ -ruby-3.0.0 +ruby-3.0.1 @@ -1,7 +1,8 @@ source 'https://rubygems.org' -gem 'gemoji' -gem 'octicons_helper' +gem 'dotenv', '~> 2.7' +gem 'gemoji', '~> 3.0' +gem 'octicons_helper', '~> 11.3' gem 'primer_view_components', '0.0.14' gem 'puma', '~> 5.0' gem 'rails', '~> 6.1.3' diff --git a/Gemfile.lock b/Gemfile.lock index fd8f90a..3e33caa 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -63,6 +63,7 @@ GEM builder (3.2.4) concurrent-ruby (1.1.9) crass (1.0.6) + dotenv (2.7.6) erubi (1.10.0) gemoji (3.0.1) globalid (0.4.2) @@ -156,8 +157,9 @@ PLATFORMS ruby DEPENDENCIES - gemoji - octicons_helper + dotenv (~> 2.7) + gemoji (~> 3.0) + octicons_helper (~> 11.3) primer_view_components (= 0.0.14) puma (~> 5.0) rails (~> 6.1.3) @@ -165,4 +167,4 @@ DEPENDENCIES webpacker (~> 5.0) BUNDLED WITH - 2.2.22 + 2.2.23 diff --git a/config/application.rb b/config/application.rb index f3c3564..e94642d 100644 --- a/config/application.rb +++ b/config/application.rb @@ -1,5 +1,6 @@ require_relative "boot" +require "dotenv" require "rails" require "active_model/railtie" require "active_record/railtie" @@ -8,6 +9,7 @@ require "action_view/railtie" require "rails/test_unit/railtie" require "primer/view_components/engine" +Dotenv.load(".env.local", ".env.#{Rails.env}", ".env") Bundler.require(*Rails.groups) module Sparkles diff --git a/config/environments/development.rb b/config/environments/development.rb index 6996a45..926a822 100644 --- a/config/environments/development.rb +++ b/config/environments/development.rb @@ -58,4 +58,6 @@ Rails.application.configure do # Uncomment if you wish to allow Action Cable access from any origin. # config.action_cable.disable_request_forgery_protection = true + + config.hosts << ENV.fetch('NGROK_HOST') end diff --git a/config/puma.rb b/config/puma.rb index d35cc07..623cba5 100644 --- a/config/puma.rb +++ b/config/puma.rb @@ -21,7 +21,7 @@ end # Specifies the `port` that Puma will listen on to receive requests; default is 3000. # -#port ENV.fetch("PORT") { 3000 } +port ENV.fetch("PORT") { 3000 } # Specifies the `environment` that Puma will run in. # |
