Skip to content

Commit

Permalink
Use docker to run solr
Browse files Browse the repository at this point in the history
  • Loading branch information
cbeer committed May 17, 2017
1 parent 610310f commit ccb72c5
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 8 deletions.
10 changes: 9 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,17 @@
language: ruby
sudo: false
sudo: required

notifications:
email: false

services:
- docker

before_install:
- docker run --name my_solr -d -p 8983:8983 solr
- docker cp ./solr/conf my_solr:/opt/solr/blacklight-solr-conf
- docker exec -it --user=solr my_solr bin/solr create_core -c blacklight-core -d /opt/solr/blacklight-solr-conf

rvm:
- 2.4.1

Expand Down
11 changes: 4 additions & 7 deletions tasks/blacklight.rake
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,11 @@ EngineCart.fingerprint_proc = EngineCart.rails_fingerprint_proc

desc "Run test suite"
task :ci => ['blacklight:generate'] do
SolrWrapper.wrap do |solr|
solr.with_collection(name: 'blacklight-core', dir: File.join(File.expand_path("..", File.dirname(__FILE__)), "solr", "conf")) do
within_test_app do
system "RAILS_ENV=test rake blacklight:index:seed"
end
Rake::Task['blacklight:coverage'].invoke
end
within_test_app do
system "RAILS_ENV=test rake blacklight:index:seed"
end

Rake::Task['blacklight:coverage'].invoke
end

namespace :blacklight do
Expand Down

0 comments on commit ccb72c5

Please sign in to comment.