chef-solr 0.10.4 → 0.10.6.beta.1

Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile CHANGED
@@ -20,13 +20,23 @@ require File.dirname(__FILE__) + '/lib/chef/solr/version'
20
20
 
21
21
  require 'rubygems'
22
22
  require 'rake'
23
- require 'rake/gempackagetask'
23
+ #require 'rake/gempackagetask'
24
+ require 'rubygems/package_task'
24
25
 
25
26
  GEM_NAME = "chef-solr"
26
27
 
27
- spec = eval(File.read("chef-solr.gemspec"))
28
+ spec = eval(File.read(File.dirname(__FILE__) + "/chef-solr.gemspec"))
28
29
 
29
- Rake::GemPackageTask.new(spec) do |pkg|
30
+ desc "Create solr archives"
31
+ task :tar_solr do
32
+ %w{solr-home solr-jetty}.each do |tar|
33
+ Dir.chdir(File.dirname(__FILE__) + "/solr/#{tar}") { sh "tar cvzf ../#{tar}.tar.gz *" }
34
+ end
35
+ end
36
+
37
+ task :gem => :tar_solr
38
+
39
+ Gem::PackageTask.new(spec) do |pkg|
30
40
  pkg.gem_spec = spec
31
41
  end
32
42
 
@@ -1,6 +1,6 @@
1
1
  class Chef
2
2
  class Solr
3
- VERSION = '0.10.4'
3
+ VERSION = '0.10.6.beta.1'
4
4
 
5
5
  # Solr Schema. Used to detect incompatibilities between installed solr and
6
6
  # chef-solr versions.
Binary file
Binary file
metadata CHANGED
@@ -1,13 +1,8 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chef-solr
3
3
  version: !ruby/object:Gem::Version
4
- hash: 63
5
- prerelease:
6
- segments:
7
- - 0
8
- - 10
9
- - 4
10
- version: 0.10.4
4
+ prerelease: 7
5
+ version: 0.10.6.beta.1
11
6
  platform: ruby
12
7
  authors:
13
8
  - Adam Jacob
@@ -15,7 +10,8 @@ autorequire:
15
10
  bindir: bin
16
11
  cert_chain: []
17
12
 
18
- date: 2011-08-11 00:00:00 Z
13
+ date: 2011-10-31 00:00:00 -07:00
14
+ default_executable:
19
15
  dependencies:
20
16
  - !ruby/object:Gem::Dependency
21
17
  name: chef
@@ -25,12 +21,7 @@ dependencies:
25
21
  requirements:
26
22
  - - "="
27
23
  - !ruby/object:Gem::Version
28
- hash: 63
29
- segments:
30
- - 0
31
- - 10
32
- - 4
33
- version: 0.10.4
24
+ version: 0.10.6.beta.1
34
25
  type: :runtime
35
26
  version_requirements: *id001
36
27
  description:
@@ -38,7 +29,6 @@ email: adam@opscode.com
38
29
  executables:
39
30
  - chef-solr
40
31
  - chef-solr-installer
41
- - chef-solr-rebuild
42
32
  extensions: []
43
33
 
44
34
  extra_rdoc_files: []
@@ -48,15 +38,14 @@ files:
48
38
  - Rakefile
49
39
  - LICENSE
50
40
  - bin/chef-solr
51
- - bin/chef-solr-rebuild
52
41
  - bin/chef-solr-installer
42
+ - lib/chef/solr/application/solr.rb
53
43
  - lib/chef/solr/solr_installer.rb
54
44
  - lib/chef/solr/version.rb
55
- - lib/chef/solr/application/solr.rb
56
- - lib/chef/solr/application/rebuild.rb
57
45
  - lib/chef/solr.rb
58
- - solr/solr-jetty.tar.gz
59
46
  - solr/solr-home.tar.gz
47
+ - solr/solr-jetty.tar.gz
48
+ has_rdoc: true
60
49
  homepage: http://wiki.opscode.com/display/chef
61
50
  licenses: []
62
51
 
@@ -70,23 +59,17 @@ required_ruby_version: !ruby/object:Gem::Requirement
70
59
  requirements:
71
60
  - - ">="
72
61
  - !ruby/object:Gem::Version
73
- hash: 3
74
- segments:
75
- - 0
76
62
  version: "0"
77
63
  required_rubygems_version: !ruby/object:Gem::Requirement
78
64
  none: false
79
65
  requirements:
80
- - - ">="
66
+ - - ">"
81
67
  - !ruby/object:Gem::Version
82
- hash: 3
83
- segments:
84
- - 0
85
- version: "0"
68
+ version: 1.3.1
86
69
  requirements: []
87
70
 
88
71
  rubyforge_project:
89
- rubygems_version: 1.7.2
72
+ rubygems_version: 1.6.2
90
73
  signing_key:
91
74
  specification_version: 3
92
75
  summary: Search indexing for Chef
@@ -1,27 +0,0 @@
1
- #!/usr/bin/env ruby
2
- #
3
- # Author:: Adam Jacob (<adam@opscode.com>)
4
- # Copyright:: Copyright (c) 2009 Opscode, Inc.
5
- # License:: Apache License, Version 2.0
6
- #
7
- # Licensed under the Apache License, Version 2.0 (the "License");
8
- # you may not use this file except in compliance with the License.
9
- # You may obtain a copy of the License at
10
- #
11
- # http://www.apache.org/licenses/LICENSE-2.0
12
- #
13
- # Unless required by applicable law or agreed to in writing, software
14
- # distributed under the License is distributed on an "AS IS" BASIS,
15
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16
- # See the License for the specific language governing permissions and
17
- # limitations under the License.
18
- #
19
-
20
- $:.unshift(File.expand_path(File.join(File.dirname(__FILE__), "..", "lib")))
21
- $:.unshift(File.expand_path(File.join(File.dirname(__FILE__), "..", "..", "chef", "lib")))
22
-
23
- require 'rubygems'
24
- require 'chef/solr/application/rebuild'
25
-
26
- Chef::Solr::Application::Rebuild.new.run
27
-
@@ -1,101 +0,0 @@
1
- #
2
- # Author:: AJ Christensen (<aj@opscode.com)
3
- # Copyright:: Copyright (c) 2008 Opscode, Inc.
4
- # License:: Apache License, Version 2.0
5
- #
6
- # Licensed under the Apache License, Version 2.0 (the "License");
7
- # you may not use this file except in compliance with the License.
8
- # You may obtain a copy of the License at
9
- #
10
- # http://www.apache.org/licenses/LICENSE-2.0
11
- #
12
- # Unless required by applicable law or agreed to in writing, software
13
- # distributed under the License is distributed on an "AS IS" BASIS,
14
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
- # See the License for the specific language governing permissions and
16
- # limitations under the License.
17
-
18
- require 'chef'
19
- require 'chef/log'
20
- require 'chef/config'
21
- require 'chef/application'
22
- require 'chef/solr'
23
- require 'chef/solr/index'
24
-
25
- class Chef
26
- class Solr
27
- class Application
28
- class Rebuild < Chef::Application
29
-
30
- option :config_file,
31
- :short => "-c CONFIG",
32
- :long => "--config CONFIG",
33
- :default => "/etc/chef/solr.rb",
34
- :description => "The configuration file to use"
35
-
36
- option :log_level,
37
- :short => "-l LEVEL",
38
- :long => "--log_level LEVEL",
39
- :description => "Set the log level (debug, info, warn, error, fatal)",
40
- :proc => lambda { |l| l.to_sym }
41
-
42
- option :log_location,
43
- :short => "-L LOGLOCATION",
44
- :long => "--logfile LOGLOCATION",
45
- :description => "Set the log file location, defaults to STDOUT - recommended for daemonizing",
46
- :proc => nil
47
-
48
- option :help,
49
- :short => "-h",
50
- :long => "--help",
51
- :description => "Show this message",
52
- :on => :tail,
53
- :boolean => true,
54
- :show_options => true,
55
- :exit => 0
56
-
57
- option :couchdb_database,
58
- :short => "-d DB",
59
- :long => "--couchdb-database DB",
60
- :description => "The CouchDB Database to re-index"
61
-
62
- option :couchdb_url,
63
- :short => "-u URL",
64
- :long => "--couchdb-url URL",
65
- :description => "The CouchDB URL"
66
-
67
- option :version,
68
- :short => "-v",
69
- :long => "--version",
70
- :description => "Show chef-solr-rebuild version",
71
- :boolean => true,
72
- :proc => lambda {|v| puts "chef-solr-rebuild: #{::Chef::Solr::VERSION}"},
73
- :exit => 0
74
-
75
- def initialize
76
- super
77
-
78
- @index = Chef::Solr::Index.new
79
- end
80
-
81
- def setup_application
82
- Chef::Log.level = Chef::Config[:log_level]
83
- Chef::Log.warn("This operation is destructive!")
84
- Chef::Log.warn("I'm going to count to 10, and then delete your Solr index and rebuild it.")
85
- Chef::Log.warn("CTRL-C will, of course, stop this disaster.")
86
- 0.upto(10) do |num|
87
- Chef::Log.warn("... #{num}")
88
- sleep 1
89
- end
90
- Chef::Log.warn("... Bombs away!")
91
- end
92
-
93
- def run_application
94
- s = Chef::Solr.new(Chef::Config[:solr_url])
95
- Chef::Log.info("Destroying the index")
96
- s.rebuild_index
97
- end
98
- end
99
- end
100
- end
101
- end