Sha256: 0d0bc4b62e6a48fcd65c4b5ceae4111e27116ff632a98158a5370bbd692241c4
Contents?: true
Size: 916 Bytes
Versions: 4
Compression:
Stored size: 916 Bytes
Contents
# Load gem files # load_path_libs = File.expand_path(File.join(File.dirname(__FILE__), "lib")) load_path_libs = File.expand_path "lib", File.dirname(__FILE__) $LOAD_PATH.unshift(load_path_libs) unless $LOAD_PATH.include?(load_path_libs) require "rest-ftp-daemon" # Create global queue $queue = RestFtpDaemon::JobQueue.new # Create global counters $counters = RestFtpDaemon::Counters.new # Initialize workers $pool = RestFtpDaemon::WorkerPool.new # Rack authent unless Conf[:adminpwd].nil? use Rack::Auth::Basic, "Restricted Area" do |username, password| [username, password] == ["admin", Conf[:adminpwd]] end end # Serve static assets use Rack::Static, urls: ["/css", "/js", "/images"], root: "#{Conf.app_libs}/static/" # Rack reloader and mini-profiler unless Conf.app_env == "production" # use Rack::Reloader, 1 # use Rack::MiniProfiler end # Launch the main daemon run RestFtpDaemon::API::Root
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
rest-ftp-daemon-0.306.1 | config.ru |
rest-ftp-daemon-0.306.0 | config.ru |
rest-ftp-daemon-0.305.0 | config.ru |
rest-ftp-daemon-0.304.0 | config.ru |