Skip to content

Common Tasks

Thomas Johnson edited this page May 1, 2018 · 14 revisions
  • Start Solr, Fedora, and web servers hydra:server

    1. Open a separate terminal where you can leave the servers running
    2. From the root of your Hyrax project, run rails hydra:server to start Solr, Fedora, and the Web server
  • Start Solr, Fedora servers for you test environment hydra:test_server

    1. Open a separate terminal where you can leave the servers running
    2. From the root of your Hyrax project, run rails hydra:test_server to start Solr, Fedora, and the Web server

      ALTERNATE Instead of leaving your test servers running using the command in 3. You can start your servers each time using rails ci and Solr and Fedora will start before running the tests and then shut down automatically after the test suite has run

  • Start a Rails console

    1. Use rails console to enter the console (or rails c for shorthand)
    2. Type exit when you're done to return to the command line
  • Fix Solr if you get an error like ERROR: Core 'hydra-test' already exists!

    1. Clear the test solr instance using rm -rf tmp/solr-test/server/solr/hydra-test
    2. ALTERNATE Try solr_wrapper --config config/solr_wrapper_test.yml clean
    3. Try rails ci again and things should work; if not, ask for help!

Clone this wiki locally