Sha256: ecd61b7c85f2ed32a8c36991f046bb874dfa00f9d67cd12788cb6393031f1594

Contents?: true

Size: 974 Bytes

Versions: 34

Compression:

Stored size: 974 Bytes

Contents

# Do things here that you only want to apply to your docker environment
#
if ENV['DOCKER'].to_s =~ /true/
  #
  # Modify workarea configuration
  #
  Workarea.configure do |config|
    config.headless_chrome_options << 'no-sandbox'
  end

  #
  # Modify application configuration
  #
  Rails.application.configure do
    <%= 'config.file_watcher = ActiveSupport::FileUpdateChecker' unless include_docker_sync? %>

    # Uncomment if you want to use mailcatcher
    # config.action_mailer.delivery_method = :smtp
    # config.action_mailer.smtp_settings = { :address => 'mailcatcher', :port => 1025 }

    # Allow web console in Docker
    if Rails.env.development?
      config.web_console.whitelisted_ips = Socket.ip_address_list.reduce([]) do |res, addrinfo|
        addrinfo.ipv4? ? res << IPAddr.new(addrinfo.ip_address).mask(24) : res
      end
      WebConsole::Request.whitelisted_ips = WebConsole::Whitelist.new(config.web_console.whitelisted_ips)
    end
  end
end

Version data entries

34 entries across 34 versions & 1 rubygems

Version Path
workarea-core-3.4.25 lib/generators/workarea/docker/templates/docker_init.rb.erb
workarea-core-3.4.24 lib/generators/workarea/docker/templates/docker_init.rb.erb
workarea-core-3.4.23 lib/generators/workarea/docker/templates/docker_init.rb.erb
workarea-core-3.4.22 lib/generators/workarea/docker/templates/docker_init.rb.erb
workarea-core-3.4.21 lib/generators/workarea/docker/templates/docker_init.rb.erb
workarea-core-3.4.20 lib/generators/workarea/docker/templates/docker_init.rb.erb
workarea-core-3.4.19 lib/generators/workarea/docker/templates/docker_init.rb.erb
workarea-core-3.4.18 lib/generators/workarea/docker/templates/docker_init.rb.erb
workarea-core-3.4.17 lib/generators/workarea/docker/templates/docker_init.rb.erb
workarea-core-3.4.16 lib/generators/workarea/docker/templates/docker_init.rb.erb
workarea-core-3.4.15 lib/generators/workarea/docker/templates/docker_init.rb.erb
workarea-core-3.4.14 lib/generators/workarea/docker/templates/docker_init.rb.erb
workarea-core-3.4.13 lib/generators/workarea/docker/templates/docker_init.rb.erb
workarea-core-3.4.12 lib/generators/workarea/docker/templates/docker_init.rb.erb