diff --git a/Gemfile b/Gemfile index 2d1fe2de..d8452939 100644 --- a/Gemfile +++ b/Gemfile @@ -15,6 +15,7 @@ gem 'devise_invitable' gem 'dotenv-rails' gem 'font-awesome-rails' gem 'friendly_id' +gem 'irb' # Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder gem 'jbuilder', '~> 2.5' gem 'jquery-rails' @@ -87,5 +88,4 @@ end group :development, :integration, :test do gem 'byebug' # debugging - gem 'irb' end diff --git a/Gemfile.lock b/Gemfile.lock index 251b882f..b2fc5436 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -232,7 +232,7 @@ GEM railties (>= 4.1.0) responders warden (~> 1.2.3) - devise-guests (0.8.2) + devise-guests (0.8.3) devise devise_invitable (2.0.9) actionmailer (>= 5.0) @@ -307,7 +307,7 @@ GEM http-cookie (1.0.5) domain_name (~> 0.5) http-form_data (2.3.0) - i18n (1.14.5) + i18n (1.14.6) concurrent-ruby (~> 1.0) i18n-active_record (1.3.0) i18n (>= 0.5.0) @@ -628,7 +628,7 @@ GEM test_xml (0.1.8) diffy (~> 3.0) nokogiri (>= 1.3.2) - thor (1.3.1) + thor (1.3.2) tilt (2.4.0) timecop (0.9.8) timeout (0.4.1) @@ -679,7 +679,7 @@ GEM chronic (>= 0.6.3) xpath (3.2.0) nokogiri (~> 1.8) - zeitwerk (2.6.17) + zeitwerk (2.6.18) PLATFORMS aarch64-linux diff --git a/README.md b/README.md index 0cdd3482..6a9c9138 100644 --- a/README.md +++ b/README.md @@ -32,6 +32,14 @@ Web server: http://localhost:9292 Solr: http://localhost:8983 +Sidekiq: http://localhost:9292/sidekiq + +#### Set up initial data + +1. Set up admin user using the SITE_ADMINS email set in your dotenv file: `bundle exec rake spotlight:initialize` + +1. Set up initial exhibit: `bundle exec rake spotlight:exhibit` + #### Testing in Docker Run full test suite: diff --git a/compose.yaml b/compose.yaml index 030a27d4..2ae1c7f9 100644 --- a/compose.yaml +++ b/compose.yaml @@ -34,7 +34,7 @@ services: ports: - 3306:3306 volumes: - - db-data:/var/lib/mysql/data + - db-data:/var/lib/mysql solr: extends: diff --git a/config/schedule.rb b/config/schedule.rb index 32142f2a..8b75d71f 100644 --- a/config/schedule.rb +++ b/config/schedule.rb @@ -19,17 +19,22 @@ # Learn more: http://github.com/javan/whenever -# Clean up anonymous search records > 7 days +# Clean up tmp/network_files > 50GB every :day, at: '1:00am' do - rake 'blacklight:delete_old_searches[7]' + rake 'spotlight:riiif:clear_cache' end -# Clean up tmp/network_files > 50GB -every :day, at: '2:05am' do - rake 'spotlight:riiif:clear_cache' +# Clean up anonymous search records > 7 days +every :wednesday, at: '2:00am' do + rake 'blacklight:delete_old_searches[7]' end # Clean up PaperTrail versions > 365 days -every :day, at: '3:00am' do +every :wednesday, at: '3:00am' do rake 'spotlight:paper_trail:clear[365]' end + +# Clean up guest users > 2 days +every :wednesday, at: '4:00am' do + rake 'devise_guests:delete_old_guest_users[2]' +end