Class: MamaSearch::Generators::InstallGenerator
- Inherits:
-
Rails::Generators::Base
- Object
- Rails::Generators::Base
- MamaSearch::Generators::InstallGenerator
- Defined in:
- lib/mama_search/generators/install_generator.rb
Instance Method Summary collapse
Instance Method Details
#config ⇒ Object
16 17 18 19 20 21 22 23 |
# File 'lib/mama_search/generators/install_generator.rb', line 16 def config say 'Installing config...' template 'elasticsearch.app.yml', 'config/elasticsearch.yml' #copy_file 'elasticsearch.in.sh', 'config/elasticsearch/elasticsearch.in.sh' #copy_file 'logging.yml', 'config/elasticsearch/logging.yml' template 'elasticsearch.yml', 'elasticsearch/server/config/elasticsearch.yml' copy_file 'elasticsearch.rb', 'config/initializers/elasticsearch.rb' end |
#install ⇒ Object
8 9 10 11 12 13 14 |
# File 'lib/mama_search/generators/install_generator.rb', line 8 def install say 'Installing elasticsearch...' source = File.join File.dirname(__FILE__), '/../../../vendor/elasticsearch-0.16.0' destination = 'elasticsearch/server' directory source, destination chmod "#{destination}/bin/", 0755 end |