forked from External/greenlight
		
	@@ -6,6 +6,7 @@ README.md
 | 
				
			|||||||
# Rails
 | 
					# Rails
 | 
				
			||||||
.env
 | 
					.env
 | 
				
			||||||
.env.prod
 | 
					.env.prod
 | 
				
			||||||
 | 
					sample.env
 | 
				
			||||||
*.rbc
 | 
					*.rbc
 | 
				
			||||||
capybara-*.html
 | 
					capybara-*.html
 | 
				
			||||||
.rspec
 | 
					.rspec
 | 
				
			||||||
@@ -17,4 +18,10 @@ public/system
 | 
				
			|||||||
coverage/
 | 
					coverage/
 | 
				
			||||||
spec/tmp
 | 
					spec/tmp
 | 
				
			||||||
.rvmrc
 | 
					.rvmrc
 | 
				
			||||||
scripts/
 | 
					.byebug_history
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# docker
 | 
				
			||||||
 | 
					docker-compose.yml
 | 
				
			||||||
 | 
					production-compose.yml
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					.atom
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										4
									
								
								.gitignore
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										4
									
								
								.gitignore
									
									
									
									
										vendored
									
									
								
							@@ -8,8 +8,8 @@
 | 
				
			|||||||
/.bundle
 | 
					/.bundle
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# Ignore the default SQLite database.
 | 
					# Ignore the default SQLite database.
 | 
				
			||||||
/db/*.sqlite3
 | 
					/db/**/*.sqlite3
 | 
				
			||||||
/db/*.sqlite3-journal
 | 
					/db/**/*.sqlite3-journal
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# Ignore all logfiles and tempfiles.
 | 
					# Ignore all logfiles and tempfiles.
 | 
				
			||||||
/log/*
 | 
					/log/*
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -5,5 +5,4 @@ test:
 | 
				
			|||||||
  adapter: async
 | 
					  adapter: async
 | 
				
			||||||
 | 
					
 | 
				
			||||||
production:
 | 
					production:
 | 
				
			||||||
  adapter: redis
 | 
					  adapter: async
 | 
				
			||||||
  url: redis://localhost:6379/1
 | 
					 | 
				
			||||||
 
 | 
				
			|||||||
@@ -22,4 +22,4 @@ test:
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
production:
 | 
					production:
 | 
				
			||||||
  <<: *default
 | 
					  <<: *default
 | 
				
			||||||
  database: db/production.sqlite3
 | 
					  database: db/production/production.sqlite3
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -33,11 +33,8 @@ Rails.application.configure do
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  config.active_job.queue_adapter = :async
 | 
					  config.active_job.queue_adapter = :async
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  # action cable socket URI
 | 
					 | 
				
			||||||
  config.action_cable.url = "ws://localhost/cable"
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # allowed action cable origins
 | 
					  # allowed action cable origins
 | 
				
			||||||
  config.action_cable.allowed_request_origins = ['http://localhost']
 | 
					  Rails.application.config.action_cable.disable_request_forgery_protection = true
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  # Print deprecation notices to the Rails logger.
 | 
					  # Print deprecation notices to the Rails logger.
 | 
				
			||||||
  config.active_support.deprecation = :log
 | 
					  config.active_support.deprecation = :log
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -16,7 +16,7 @@ Rails.application.configure do
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  # Disable serving static files from the `/public` folder by default since
 | 
					  # Disable serving static files from the `/public` folder by default since
 | 
				
			||||||
  # Apache or NGINX already handles this.
 | 
					  # Apache or NGINX already handles this.
 | 
				
			||||||
  config.public_file_server.enabled = ENV['RAILS_SERVE_STATIC_FILES'].present?
 | 
					  config.public_file_server.enabled = ENV['DISABLE_RAILS_SERVE_STATIC_FILES'].blank?
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  # Compress JavaScripts and CSS.
 | 
					  # Compress JavaScripts and CSS.
 | 
				
			||||||
  config.assets.js_compressor = :uglifier
 | 
					  config.assets.js_compressor = :uglifier
 | 
				
			||||||
@@ -63,11 +63,11 @@ Rails.application.configure do
 | 
				
			|||||||
  # Set this to true and configure the email server for immediate delivery to raise delivery errors.
 | 
					  # Set this to true and configure the email server for immediate delivery to raise delivery errors.
 | 
				
			||||||
  # config.action_mailer.raise_delivery_errors = false
 | 
					  # config.action_mailer.raise_delivery_errors = false
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  # action cable socket URI
 | 
					  # action cable origins
 | 
				
			||||||
  config.action_cable.url = "ws://#{ENV['HOSTNAME']}/cable" # TODO this should use WSS protocol
 | 
					  unless ENV["RAILS_ACTION_CABLE_FORGERY_PROTECTION"].present?
 | 
				
			||||||
 | 
					    Rails.application.config.action_cable.disable_request_forgery_protection = true
 | 
				
			||||||
  # allowed action cable origins
 | 
					  end
 | 
				
			||||||
  config.action_cable.allowed_request_origins = ["https://#{ENV['HOSTNAME']}", "http://#{ENV['HOSTNAME']}"]
 | 
					  # config.action_cable.allowed_request_origins = ["https://#{ENV['HOSTNAME']}", "http://#{ENV['HOSTNAME']}"]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  # Send deprecation notices to registered listeners.
 | 
					  # Send deprecation notices to registered listeners.
 | 
				
			||||||
  config.active_support.deprecation = :notify
 | 
					  config.active_support.deprecation = :notify
 | 
				
			||||||
@@ -79,7 +79,7 @@ Rails.application.configure do
 | 
				
			|||||||
  # require 'syslog/logger'
 | 
					  # require 'syslog/logger'
 | 
				
			||||||
  # config.logger = ActiveSupport::TaggedLogging.new(Syslog::Logger.new 'app-name')
 | 
					  # config.logger = ActiveSupport::TaggedLogging.new(Syslog::Logger.new 'app-name')
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  if ENV["RAILS_LOG_TO_STDOUT"].present?
 | 
					  if ENV["DISABLE_RAILS_LOG_TO_STDOUT"].blank?
 | 
				
			||||||
    logger           = ActiveSupport::Logger.new(STDOUT)
 | 
					    logger           = ActiveSupport::Logger.new(STDOUT)
 | 
				
			||||||
    logger.formatter = config.log_formatter
 | 
					    logger.formatter = config.log_formatter
 | 
				
			||||||
    config.logger = ActiveSupport::TaggedLogging.new(logger)
 | 
					    config.logger = ActiveSupport::TaggedLogging.new(logger)
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -9,7 +9,7 @@ threads threads_count, threads_count
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
# Specifies the `port` that Puma will listen on to receive requests, default is 3000.
 | 
					# Specifies the `port` that Puma will listen on to receive requests, default is 3000.
 | 
				
			||||||
#
 | 
					#
 | 
				
			||||||
port        ENV.fetch("PORT") { 9292 }
 | 
					port        ENV.fetch("PORT") { 80 }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# Specifies the `environment` that Puma will run in.
 | 
					# Specifies the `environment` that Puma will run in.
 | 
				
			||||||
#
 | 
					#
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user