Skip to content

Commit

Permalink
Fixes #12146: moved core dependencies into gemspec
Browse files Browse the repository at this point in the history
  • Loading branch information
dmitri-d authored and Dominic Cleal committed Nov 19, 2015
1 parent f24be74 commit bf8936e
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 17 deletions.
5 changes: 1 addition & 4 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
source 'http://rubygems.org'

gem 'json'
gem 'sinatra'
gem 'rack', '>= 1.1', '< 1.6'
gemspec

Dir["#{File.dirname(__FILE__)}/bundler.d/*.rb"].each do |bundle|
# puts "adding custom gem file #{bundle}"
self.instance_eval(Bundler.read_file(bundle))
end
2 changes: 1 addition & 1 deletion bin/smart-proxy
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@

$LOAD_PATH.unshift(*Dir[File.expand_path("../../lib", __FILE__), File.expand_path("../../modules", __FILE__)])

require 'smart_proxy'
require 'smart_proxy_main'
Proxy::Launcher.new.launch
2 changes: 1 addition & 1 deletion bin/smart-proxy-win-service
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ $LOAD_PATH.unshift(*Dir[File.expand_path("../../lib", __FILE__), File.expand_pat

raise "win-service executable can only be used as a service in windows environment" unless RUBY_PLATFORM =~ /mingw/

require 'smart_proxy'
require 'smart_proxy_main'
require 'win32/daemon'
include Win32

Expand Down
2 changes: 1 addition & 1 deletion config.ru
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
$LOAD_PATH.unshift *Dir[File.expand_path("../lib", __FILE__), File.expand_path("../modules", __FILE__)]

require 'smart_proxy'
require 'smart_proxy_main'
::Proxy::Plugins.configure_loaded_plugins
::Proxy::Plugins.enabled_plugins.each {|p| instance_eval(p.https_rackup)}
File renamed without changes.
16 changes: 6 additions & 10 deletions smart_proxy.gemspec
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
require 'rake'

Gem::Specification.new do |s|
s.name = "smart_proxy"
s.version = File.read(File.join(File.dirname(__FILE__), 'VERSION')).chomp.gsub('-', '.')
Expand All @@ -8,20 +6,18 @@ Gem::Specification.new do |s|
s.homepage = "http://theforeman.org/"
s.platform = Gem::Platform::RUBY
s.summary = "Foreman Proxy Agent, manage remote DHCP, DNS, TFTP and Puppet servers"
s.files = FileList["{bin,public,config,views,lib,modules}/**/*", "VERSION"].to_a
s.default_executable = 'bin/smart_proxy.rb'
s.files = (Dir.glob("{bin,public,config,views,lib,modules}/**/*") + ["VERSION"])
s.executables << 'smart-proxy'
s.require_paths = ["lib", "modules"]
s.test_files = FileList["{test}/**/*test.rb"].to_a
s.test_files = Dir.glob("{test}/**/*test.rb")
s.license = 'GPLv3'
s.has_rdoc = true
s.extra_rdoc_files = ["README.md"]
s.add_dependency 'json', '~> 1.8'
s.add_dependency 'rack', '~> 1.5'
s.add_dependency 'sinatra', '~> 1.4'
s.rubyforge_project = 'rake'
s.add_dependency 'json'
s.add_dependency 'rack', '>= 1.1', '< 1.6' # ruby 1.8.7 support is broken in rack 1.6 versions < 1.6.4
s.add_dependency 'sinatra'
s.description = <<EOF
Foreman Proxy is used via The Foreman Project, it allows Foreman to manage
Remote DHCP, DNS, TFTP and Puppet servers via a REST API
EOF
end

0 comments on commit bf8936e

Please sign in to comment.