hyrax 3.0.0.pre.rc2 → 3.0.0.pre.rc3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.circleci/config.yml +5 -5
- data/.dassie/.env +4 -0
- data/.dassie/.gitignore +27 -0
- data/.dassie/Gemfile +57 -0
- data/.dassie/README.md +3 -0
- data/.dassie/Rakefile +6 -0
- data/.dassie/app/actors/hyrax/actors/generic_work_actor.rb +8 -0
- data/.dassie/app/actors/hyrax/actors/namespaced_works/nested_work_actor.rb +8 -0
- data/.dassie/app/assets/config/manifest.js +3 -0
- data/.dassie/app/assets/images/.keep +0 -0
- data/.dassie/app/assets/images/unauthorized.png +0 -0
- data/.dassie/app/assets/images/us_404.svg +91 -0
- data/.dassie/app/assets/javascripts/application.js +26 -0
- data/.dassie/app/assets/javascripts/blacklight_gallery.js +1 -0
- data/.dassie/app/assets/javascripts/cable.js +13 -0
- data/.dassie/app/assets/javascripts/channels/.keep +0 -0
- data/.dassie/app/assets/javascripts/openseadragon.js +2 -0
- data/.dassie/app/assets/stylesheets/application.css +16 -0
- data/.dassie/app/assets/stylesheets/hyrax.scss +17 -0
- data/.dassie/app/assets/stylesheets/openseadragon.css +3 -0
- data/.dassie/app/channels/application_cable/channel.rb +4 -0
- data/.dassie/app/channels/application_cable/connection.rb +4 -0
- data/.dassie/app/controllers/application_controller.rb +14 -0
- data/.dassie/app/controllers/catalog_controller.rb +300 -0
- data/.dassie/app/controllers/concerns/.keep +0 -0
- data/.dassie/app/controllers/hyrax/generic_works_controller.rb +14 -0
- data/.dassie/app/controllers/hyrax/monographs_controller.rb +17 -0
- data/.dassie/app/controllers/hyrax/namespaced_works/nested_works_controller.rb +14 -0
- data/.dassie/app/forms/hyrax/generic_work_form.rb +9 -0
- data/.dassie/app/forms/hyrax/namespaced_works/nested_work_form.rb +9 -0
- data/.dassie/app/forms/monograph_form.rb +20 -0
- data/.dassie/app/helpers/application_helper.rb +2 -0
- data/.dassie/app/helpers/hyrax_helper.rb +6 -0
- data/.dassie/app/indexers/generic_work_indexer.rb +18 -0
- data/.dassie/app/indexers/monograph_indexer.rb +16 -0
- data/.dassie/app/indexers/namespaced_works/nested_work_indexer.rb +18 -0
- data/.dassie/app/jobs/application_job.rb +2 -0
- data/.dassie/app/mailers/application_mailer.rb +4 -0
- data/.dassie/app/models/ability.rb +21 -0
- data/.dassie/app/models/application_record.rb +3 -0
- data/.dassie/app/models/collection.rb +8 -0
- data/.dassie/app/models/concerns/.keep +0 -0
- data/.dassie/app/models/file_set.rb +5 -0
- data/.dassie/app/models/generic_work.rb +14 -0
- data/.dassie/app/models/monograph.rb +8 -0
- data/.dassie/app/models/namespaced_works/nested_work.rb +16 -0
- data/.dassie/app/models/qa.rb +5 -0
- data/.dassie/app/models/qa/local_authority.rb +2 -0
- data/.dassie/app/models/qa/local_authority_entry.rb +3 -0
- data/.dassie/app/models/search_builder.rb +16 -0
- data/.dassie/app/models/solr_document.rb +28 -0
- data/.dassie/app/models/time_span.rb +22 -0
- data/.dassie/app/models/user.rb +26 -0
- data/.dassie/app/presenters/hyrax/generic_work_presenter.rb +6 -0
- data/.dassie/app/presenters/hyrax/namespaced_works/nested_work_presenter.rb +6 -0
- data/.dassie/app/views/hyrax/generic_works/_generic_work.html.erb +2 -0
- data/.dassie/app/views/hyrax/monographs/_monograph.html.erb +2 -0
- data/.dassie/app/views/hyrax/namespaced_works/nested_works/_nested_work.html.erb +2 -0
- data/.dassie/app/views/layouts/application.html.erb +15 -0
- data/.dassie/app/views/layouts/mailer.html.erb +13 -0
- data/.dassie/app/views/layouts/mailer.text.erb +1 -0
- data/.dassie/bin/bundle +3 -0
- data/.dassie/bin/rails +9 -0
- data/.dassie/bin/rake +9 -0
- data/.dassie/bin/setup +36 -0
- data/.dassie/bin/spring +17 -0
- data/.dassie/bin/update +31 -0
- data/.dassie/bin/yarn +11 -0
- data/.dassie/config.ru +5 -0
- data/.dassie/config/analytics.yml +6 -0
- data/.dassie/config/application.rb +22 -0
- data/.dassie/config/arkivo.yml +6 -0
- data/.dassie/config/authorities/licenses.yml +46 -0
- data/.dassie/config/authorities/resource_types.yml +41 -0
- data/.dassie/config/authorities/rights_statements.yml +37 -0
- data/.dassie/config/blacklight.yml +9 -0
- data/.dassie/config/boot.rb +4 -0
- data/.dassie/config/browse_everything_providers.yml +2 -0
- data/.dassie/config/cable.yml +10 -0
- data/.dassie/config/credentials.yml.enc +1 -0
- data/.dassie/config/environment.rb +5 -0
- data/.dassie/config/environments/development.rb +69 -0
- data/.dassie/config/environments/production.rb +94 -0
- data/.dassie/config/environments/test.rb +51 -0
- data/.dassie/config/fedora.yml +15 -0
- data/.dassie/config/initializers/arkivo_constraint.rb +12 -0
- data/.dassie/config/initializers/assets.rb +2 -0
- data/.dassie/config/initializers/clamav.rb +2 -0
- data/.dassie/config/initializers/cookies_serializer.rb +1 -0
- data/.dassie/config/initializers/devise.rb +13 -0
- data/.dassie/config/initializers/filter_parameter_logging.rb +1 -0
- data/.dassie/config/initializers/hydra_config.rb +6 -0
- data/.dassie/config/initializers/hyrax.rb +48 -0
- data/.dassie/config/initializers/mailboxer.rb +21 -0
- data/.dassie/config/initializers/mime_types.rb +4 -0
- data/.dassie/config/initializers/mini_magick.rb +6 -0
- data/.dassie/config/initializers/redis_config.rb +4 -0
- data/.dassie/config/initializers/riiif.rb +27 -0
- data/.dassie/config/initializers/simple_form.rb +28 -0
- data/.dassie/config/initializers/simple_form_bootstrap.rb +143 -0
- data/.dassie/config/initializers/wrap_parameters.rb +3 -0
- data/.dassie/config/locales/blacklight.en.yml +3 -0
- data/.dassie/config/locales/devise.en.yml +65 -0
- data/.dassie/config/locales/generic_work.de.yml +8 -0
- data/.dassie/config/locales/generic_work.en.yml +8 -0
- data/.dassie/config/locales/generic_work.es.yml +10 -0
- data/.dassie/config/locales/generic_work.fr.yml +8 -0
- data/.dassie/config/locales/generic_work.it.yml +8 -0
- data/.dassie/config/locales/generic_work.pt-BR.yml +8 -0
- data/.dassie/config/locales/generic_work.zh.yml +10 -0
- data/.dassie/config/locales/hyrax.de.yml +58 -0
- data/.dassie/config/locales/hyrax.en.yml +58 -0
- data/.dassie/config/locales/hyrax.es.yml +58 -0
- data/.dassie/config/locales/hyrax.fr.yml +58 -0
- data/.dassie/config/locales/hyrax.it.yml +58 -0
- data/.dassie/config/locales/hyrax.pt-BR.yml +58 -0
- data/.dassie/config/locales/hyrax.zh.yml +58 -0
- data/.dassie/config/locales/namespaced_works/nested_work.de.yml +8 -0
- data/.dassie/config/locales/namespaced_works/nested_work.en.yml +8 -0
- data/.dassie/config/locales/namespaced_works/nested_work.es.yml +10 -0
- data/.dassie/config/locales/namespaced_works/nested_work.fr.yml +8 -0
- data/.dassie/config/locales/namespaced_works/nested_work.it.yml +8 -0
- data/.dassie/config/locales/namespaced_works/nested_work.pt-BR.yml +8 -0
- data/.dassie/config/locales/namespaced_works/nested_work.zh.yml +10 -0
- data/.dassie/config/metadata/monograph.yaml +55 -0
- data/.dassie/config/metadata/sample_metadata.yaml +3 -0
- data/.dassie/config/puma.rb +6 -0
- data/.dassie/config/redis.yml +9 -0
- data/.dassie/config/role_map.yml +24 -0
- data/.dassie/config/routes.rb +35 -0
- data/.dassie/config/solr.yml +7 -0
- data/.dassie/config/spring.rb +6 -0
- data/.dassie/config/storage.yml +7 -0
- data/.dassie/config/tinymce.yml +12 -0
- data/.dassie/config/uv/uv-config.json +3 -0
- data/.dassie/config/uv/uv.html +87 -0
- data/.dassie/config/valkyrie_index.yml +12 -0
- data/.dassie/config/workflows/default_workflow.json +21 -0
- data/.dassie/config/workflows/mediated_deposit_workflow.json +76 -0
- data/.dassie/config/zotero.yml +6 -0
- data/.dassie/db/migrate/20200821212749_create_searches.blacklight.rb +17 -0
- data/.dassie/db/migrate/20200821212750_create_bookmarks.blacklight.rb +19 -0
- data/.dassie/db/migrate/20200821212751_add_polymorphic_type_to_bookmarks.blacklight.rb +9 -0
- data/.dassie/db/migrate/20200821212803_devise_create_users.rb +44 -0
- data/.dassie/db/migrate/20200821212806_add_devise_guests_to_users.rb +15 -0
- data/.dassie/db/migrate/20200821212828_create_version_committers.hyrax.rb +15 -0
- data/.dassie/db/migrate/20200821212829_create_checksum_audit_logs.hyrax.rb +19 -0
- data/.dassie/db/migrate/20200821212830_create_single_use_links.hyrax.rb +12 -0
- data/.dassie/db/migrate/20200821212831_add_social_to_users.hyrax.rb +13 -0
- data/.dassie/db/migrate/20200821212832_add_ldap_attrs_to_user.hyrax.rb +27 -0
- data/.dassie/db/migrate/20200821212833_add_avatars_to_users.hyrax.rb +15 -0
- data/.dassie/db/migrate/20200821212834_create_trophies.hyrax.rb +10 -0
- data/.dassie/db/migrate/20200821212835_add_linkedin_to_users.hyrax.rb +5 -0
- data/.dassie/db/migrate/20200821212836_create_tinymce_assets.hyrax.rb +8 -0
- data/.dassie/db/migrate/20200821212837_create_content_blocks.hyrax.rb +10 -0
- data/.dassie/db/migrate/20200821212838_create_featured_works.hyrax.rb +12 -0
- data/.dassie/db/migrate/20200821212839_add_external_key_to_content_blocks.hyrax.rb +6 -0
- data/.dassie/db/migrate/20200821212840_create_proxy_deposit_rights.hyrax.rb +10 -0
- data/.dassie/db/migrate/20200821212841_create_proxy_deposit_requests.hyrax.rb +15 -0
- data/.dassie/db/migrate/20200821212842_create_file_view_stats.hyrax.rb +12 -0
- data/.dassie/db/migrate/20200821212843_create_file_download_stats.hyrax.rb +12 -0
- data/.dassie/db/migrate/20200821212844_add_orcid_to_users.hyrax.rb +5 -0
- data/.dassie/db/migrate/20200821212845_create_user_stats.hyrax.rb +19 -0
- data/.dassie/db/migrate/20200821212846_create_work_view_stats.hyrax.rb +12 -0
- data/.dassie/db/migrate/20200821212847_add_works_to_user_stats.hyrax.rb +13 -0
- data/.dassie/db/migrate/20200821212848_change_trophy_generic_file_id_to_work_id.hyrax.rb +5 -0
- data/.dassie/db/migrate/20200821212849_change_proxy_deposit_generic_file_id_to_work_id.hyrax.rb +5 -0
- data/.dassie/db/migrate/20200821212850_change_audit_log_generic_file_id_to_file_set_id.hyrax.rb +5 -0
- data/.dassie/db/migrate/20200821212851_change_proxy_deposit_request_generic_file_id_to_work_id.hyrax.rb +5 -0
- data/.dassie/db/migrate/20200821212852_create_uploaded_files.hyrax.rb +10 -0
- data/.dassie/db/migrate/20200821212853_create_features.hyrax.rb +10 -0
- data/.dassie/db/migrate/20200821212854_create_operations.hyrax.rb +23 -0
- data/.dassie/db/migrate/20200821212855_change_featured_work_generic_file_id_to_work_id.hyrax.rb +6 -0
- data/.dassie/db/migrate/20200821212856_add_arkivo_to_users.hyrax.rb +8 -0
- data/.dassie/db/migrate/20200821212857_create_sipity.hyrax.rb +163 -0
- data/.dassie/db/migrate/20200821212858_create_sipity_workflow_methods.hyrax.rb +10 -0
- data/.dassie/db/migrate/20200821212859_create_permission_template.hyrax.rb +11 -0
- data/.dassie/db/migrate/20200821212860_create_permission_template_access.hyrax.rb +11 -0
- data/.dassie/db/migrate/20200821212861_add_release_to_permission_templates.hyrax.rb +6 -0
- data/.dassie/db/migrate/20200821212862_add_permission_template_to_sipity_workflow.hyrax.rb +26 -0
- data/.dassie/db/migrate/20200821212863_tidy_up_because_of_bad_exception.hyrax.rb +13 -0
- data/.dassie/db/migrate/20200821212864_add_allows_access_grant_to_workflow.hyrax.rb +5 -0
- data/.dassie/db/migrate/20200821212865_change_checksum_audit_log.hyrax.rb +18 -0
- data/.dassie/db/migrate/20200821212866_create_job_io_wrappers.hyrax.rb +15 -0
- data/.dassie/db/migrate/20200821212867_create_collection_types.hyrax.rb +17 -0
- data/.dassie/db/migrate/20200821212868_update_collection_type_column_names.hyrax.rb +9 -0
- data/.dassie/db/migrate/20200821212869_update_collection_type_column_options.hyrax.rb +17 -0
- data/.dassie/db/migrate/20200821212870_create_collection_branding_infos.hyrax.rb +15 -0
- data/.dassie/db/migrate/20200821212871_create_collection_type_participants.hyrax.rb +11 -0
- data/.dassie/db/migrate/20200821212872_rename_admin_set_id_to_source_id.hyrax.rb +5 -0
- data/.dassie/db/migrate/20200821212873_add_preferred_locale_to_users.hyrax.rb +5 -0
- data/.dassie/db/migrate/20200821212874_add_collection_type_sharing_options.hyrax.rb +5 -0
- data/.dassie/db/migrate/20200821212875_add_unique_constraint_to_permission_template_accesses.hyrax.rb +8 -0
- data/.dassie/db/migrate/20200821212876_add_branding_to_collection_type.hyrax.rb +5 -0
- data/.dassie/db/migrate/20200821212877_add_badge_color_to_collection_types.hyrax.rb +5 -0
- data/.dassie/db/migrate/20200821212878_update_single_use_links_column_names.hyrax.rb +6 -0
- data/.dassie/db/migrate/20200821212879_change_sipity_entity_specific_responsibility.hyrax.rb +9 -0
- data/.dassie/db/migrate/20200821212880_create_mailboxer.mailboxer_engine.rb +65 -0
- data/.dassie/db/migrate/20200821212881_add_conversation_optout.mailboxer_engine.rb +15 -0
- data/.dassie/db/migrate/20200821212882_add_missing_indices.mailboxer_engine.rb +20 -0
- data/.dassie/db/migrate/20200821212883_add_delivery_tracking_info_to_mailboxer_receipts.mailboxer_engine.rb +8 -0
- data/.dassie/db/migrate/20200821212884_create_qa_local_authorities.rb +10 -0
- data/.dassie/db/migrate/20200821212885_create_qa_local_authority_entries.rb +12 -0
- data/.dassie/db/migrate/20200821212902_create_minter_states.noid_rails_engine.rb +17 -0
- data/.dassie/db/migrate/20200821212903_rename_minter_state_random_to_rand.noid_rails_engine.rb +8 -0
- data/.dassie/db/schema.rb +563 -0
- data/.dassie/db/seeds.rb +14 -0
- data/.dassie/lib/assets/.keep +0 -0
- data/.dassie/lib/tasks/.keep +0 -0
- data/.dassie/log/.keep +0 -0
- data/.dassie/package.json +17 -0
- data/.dassie/public/404.html +67 -0
- data/.dassie/public/422.html +67 -0
- data/.dassie/public/500.html +66 -0
- data/.dassie/public/apple-touch-icon-precomposed.png +0 -0
- data/.dassie/public/apple-touch-icon.png +0 -0
- data/.dassie/public/favicon.ico +0 -0
- data/.dassie/public/robots.txt +1 -0
- data/.dassie/solr/conf/_rest_managed.json +3 -0
- data/.dassie/solr/conf/mapping-ISOLatin1Accent.txt +246 -0
- data/.dassie/solr/conf/schema.xml +367 -0
- data/.dassie/solr/conf/scripts.conf +24 -0
- data/.dassie/solr/conf/solrconfig.xml +208 -0
- data/.dassie/solr/conf/stopwords.txt +58 -0
- data/.dassie/solr/conf/stopwords_en.txt +58 -0
- data/.dassie/solr/conf/xslt/example.xsl +132 -0
- data/.dassie/solr/conf/xslt/example_atom.xsl +67 -0
- data/.dassie/solr/conf/xslt/example_rss.xsl +66 -0
- data/.dassie/solr/conf/xslt/luke.xsl +337 -0
- data/.dassie/solr/sample_solr_documents.yml +2692 -0
- data/.dassie/storage/.keep +0 -0
- data/.dassie/values.stage.yaml +7 -0
- data/.dassie/values.yaml +15 -0
- data/.dassie/vendor/.keep +0 -0
- data/.dockerignore +11 -0
- data/.env +26 -0
- data/.github/CODE_OF_CONDUCT.md +4 -4
- data/.github/CONTRIBUTING.md +1 -1
- data/.github/SUPPORT.md +13 -1
- data/.gitignore +1 -1
- data/.regen +1 -1
- data/.rubocop.yml +1 -0
- data/.rubocop_fixme.yml +4 -0
- data/CODE_OF_CONDUCT.md +4 -4
- data/CONTAINERS.md +148 -0
- data/CONTRIBUTING.md +1 -1
- data/Dockerfile +75 -0
- data/Gemfile +26 -35
- data/README.md +61 -288
- data/app/actors/hyrax/actors/attach_members_actor.rb +7 -5
- data/app/actors/hyrax/actors/base_actor.rb +0 -1
- data/app/actors/hyrax/actors/create_with_files_ordered_members_actor.rb +28 -28
- data/app/actors/hyrax/actors/create_with_remote_files_actor.rb +2 -3
- data/app/actors/hyrax/actors/create_with_remote_files_ordered_members_actor.rb +23 -28
- data/app/actors/hyrax/actors/default_admin_set_actor.rb +20 -21
- data/app/actors/hyrax/actors/file_actor.rb +32 -32
- data/app/actors/hyrax/actors/file_set_actor.rb +4 -15
- data/app/actors/hyrax/actors/initialize_workflow_actor.rb +8 -0
- data/app/actors/hyrax/actors/transfer_request_actor.rb +5 -0
- data/app/assets/javascripts/hyrax.js +1 -0
- data/app/assets/javascripts/hyrax/skip_to_content.js +15 -0
- data/app/assets/stylesheets/hyrax/_usage-stats.scss +1 -1
- data/app/authorities/qa/authorities/collections.rb +18 -8
- data/app/authorities/qa/authorities/find_works.rb +20 -5
- data/app/controllers/concerns/hyrax/collections_controller_behavior.rb +15 -6
- data/app/controllers/concerns/hyrax/works_controller_behavior.rb +62 -31
- data/app/controllers/hyrax/dashboard/collections_controller.rb +22 -12
- data/app/controllers/hyrax/dashboard/works_controller.rb +3 -4
- data/app/controllers/hyrax/file_sets_controller.rb +19 -10
- data/app/controllers/hyrax/homepage_controller.rb +11 -11
- data/app/controllers/hyrax/my/collections_controller.rb +5 -6
- data/app/controllers/hyrax/my/highlights_controller.rb +2 -3
- data/app/controllers/hyrax/my/shares_controller.rb +2 -3
- data/app/controllers/hyrax/my/works_controller.rb +1 -6
- data/app/controllers/hyrax/my_controller.rb +10 -2
- data/app/controllers/hyrax/permissions_controller.rb +1 -0
- data/app/controllers/hyrax/single_use_links_viewer_controller.rb +11 -5
- data/app/controllers/hyrax/users_controller.rb +5 -10
- data/app/forms/hyrax/forms/failed_submission_form_wrapper.rb +136 -0
- data/app/forms/hyrax/forms/resource_form.rb +8 -4
- data/app/helpers/hyrax/collections_helper.rb +1 -1
- data/app/helpers/hyrax/dashboard_helper_behavior.rb +7 -2
- data/app/helpers/hyrax/embargo_helper.rb +5 -1
- data/app/helpers/hyrax/hyrax_helper_behavior.rb +10 -5
- data/app/helpers/hyrax/lease_helper.rb +5 -1
- data/app/indexers/hyrax/pcdm_collection_indexer.rb +21 -0
- data/app/indexers/hyrax/resource_indexer.rb +3 -1
- data/app/indexers/hyrax/valkyrie_collection_indexer.rb +3 -12
- data/app/indexers/hyrax/valkyrie_indexer.rb +45 -17
- data/app/indexers/hyrax/valkyrie_work_indexer.rb +16 -0
- data/app/jobs/attach_files_to_work_job.rb +3 -41
- data/app/jobs/embargo_expiry_job.rb +15 -0
- data/app/jobs/event_job.rb +14 -7
- data/app/jobs/hyrax/application_job.rb +6 -1
- data/app/jobs/import_url_job.rb +11 -5
- data/app/jobs/inherit_permissions_job.rb +6 -25
- data/app/jobs/lease_expiry_job.rb +15 -0
- data/app/models/admin_set.rb +1 -1
- data/app/models/concerns/hyrax/ability.rb +192 -21
- data/app/models/concerns/hyrax/ability/admin_set_ability.rb +0 -5
- data/app/models/concerns/hyrax/collection_behavior.rb +7 -13
- data/app/models/concerns/hyrax/permissions/writable.rb +2 -2
- data/app/models/concerns/hyrax/solr_document/characterization.rb +35 -2
- data/app/models/concerns/hyrax/solr_document_behavior.rb +37 -5
- data/app/models/hyrax/change_set.rb +5 -1
- data/app/models/hyrax/collection_type.rb +59 -22
- data/app/models/hyrax/event.rb +5 -7
- data/app/models/hyrax/file_metadata.rb +15 -4
- data/app/models/hyrax/pcdm_collection.rb +13 -0
- data/app/models/hyrax/uploaded_file.rb +9 -2
- data/app/models/hyrax/{active_job_proxy.rb → valkyrie_global_id_proxy.rb} +6 -5
- data/app/models/hyrax/virus_scanner.rb +2 -1
- data/app/models/hyrax/work.rb +1 -1
- data/app/models/sipity.rb +6 -0
- data/app/models/sipity/entity.rb +1 -1
- data/app/models/sipity/workflow.rb +23 -3
- data/app/presenters/hyrax/admin/repository_object_presenter.rb +7 -2
- data/app/presenters/hyrax/collection_presenter.rb +1 -1
- data/app/presenters/hyrax/file_set_presenter.rb +3 -0
- data/app/presenters/hyrax/iiif_manifest_presenter.rb +3 -3
- data/app/presenters/hyrax/permission_badge.rb +1 -1
- data/app/presenters/hyrax/presenter_factory.rb +0 -2
- data/app/presenters/hyrax/select_collection_type_presenter.rb +16 -3
- data/app/presenters/hyrax/select_type_presenter.rb +3 -2
- data/app/presenters/hyrax/stats_usage_presenter.rb +0 -1
- data/app/presenters/hyrax/work_show_presenter.rb +1 -1
- data/app/renderers/hyrax/renderers/attribute_renderer.rb +16 -6
- data/app/search_builders/hyrax/README.md +3 -3
- data/app/search_builders/hyrax/admin_admin_set_member_search_builder.rb +8 -2
- data/app/search_builders/hyrax/collection_member_search_builder.rb +21 -7
- data/app/search_builders/hyrax/dashboard/managed_search_filters.rb +1 -1
- data/app/search_builders/hyrax/dashboard/nested_collections_search_builder.rb +1 -1
- data/app/search_builders/hyrax/embargo_search_builder.rb +0 -1
- data/app/search_builders/hyrax/filter_by_type.rb +3 -1
- data/app/search_builders/hyrax/lease_search_builder.rb +0 -1
- data/app/search_builders/hyrax/nested_collections_parent_search_builder.rb +12 -2
- data/app/search_builders/hyrax/search_builder.rb +1 -4
- data/app/search_builders/hyrax/search_filters.rb +0 -2
- data/app/services/hyrax/access_control_list.rb +33 -2
- data/app/services/hyrax/adapters/nesting_index_adapter.rb +26 -7
- data/app/services/hyrax/admin_set_member_service.rb +18 -4
- data/{lib/hyrax/callbacks/registry.rb → app/services/hyrax/callbacks.rb} +23 -0
- data/app/services/hyrax/change_content_depositor_service.rb +4 -1
- data/app/services/hyrax/collection_member_service.rb +5 -1
- data/app/services/hyrax/collection_types/permissions_service.rb +0 -2
- data/app/services/hyrax/collections/collection_member_service.rb +44 -64
- data/app/services/hyrax/collections/managed_collections_service.rb +15 -2
- data/app/services/hyrax/collections/migration_service.rb +9 -3
- data/app/services/hyrax/collections/nested_collection_persistence_service.rb +1 -1
- data/app/services/hyrax/collections/nested_collection_query_service.rb +39 -19
- data/app/services/hyrax/collections/permissions_service.rb +0 -1
- data/app/services/hyrax/collections_service.rb +12 -12
- data/app/services/hyrax/custom_queries/find_collections_by_type.rb +1 -1
- data/app/services/hyrax/custom_queries/navigators/child_collections_navigator.rb +14 -3
- data/app/services/hyrax/custom_queries/navigators/child_filesets_navigator.rb +14 -3
- data/app/services/hyrax/custom_queries/navigators/child_works_navigator.rb +10 -3
- data/app/services/hyrax/custom_queries/navigators/collection_members.rb +1 -0
- data/app/services/hyrax/custom_queries/navigators/find_files.rb +3 -0
- data/app/services/hyrax/database_migrator.rb +13 -10
- data/app/services/hyrax/default_middleware_stack.rb +0 -6
- data/app/services/hyrax/ensure_well_formed_admin_set_service.rb +27 -0
- data/app/services/hyrax/file_set_fixity_check_service.rb +16 -17
- data/app/services/hyrax/file_set_type_service.rb +55 -0
- data/app/services/hyrax/graph_exporter.rb +64 -8
- data/app/services/hyrax/list_source_exporter.rb +16 -34
- data/app/services/hyrax/listeners.rb +22 -0
- data/app/services/hyrax/listeners/proxy_deposit_listener.rb +20 -0
- data/app/services/hyrax/listeners/workflow_listener.rb +36 -0
- data/app/services/hyrax/multiple_membership_checker.rb +2 -1
- data/app/services/hyrax/quick_classification_query.rb +2 -3
- data/app/services/hyrax/resource_visibility_propagator.rb +1 -1
- data/app/services/hyrax/search_service.rb +108 -0
- data/app/services/hyrax/simple_schema_loader.rb +3 -1
- data/app/services/hyrax/statistics/depositors/summary.rb +0 -1
- data/app/services/hyrax/statistics/system_stats.rb +0 -1
- data/app/services/hyrax/thumbnail_path_service.rb +6 -1
- data/app/services/hyrax/time_service.rb +10 -0
- data/app/services/hyrax/versioning_service.rb +4 -28
- data/app/services/hyrax/work_uploads_handler.rb +166 -0
- data/app/services/hyrax/workflow/action_taken_service.rb +14 -1
- data/app/services/hyrax/workflow/grant_edit_to_depositor.rb +3 -1
- data/app/services/hyrax/workflow/permission_generator.rb +14 -9
- data/app/services/hyrax/workflow/workflow_action_service.rb +1 -1
- data/app/services/hyrax/workflow/workflow_factory.rb +12 -10
- data/app/services/hyrax/working_directory.rb +0 -1
- data/app/services/hyrax/works/managed_works_service.rb +14 -2
- data/app/views/_controls.html.erb +1 -1
- data/app/views/hyrax/admin/collection_types/index.html.erb +1 -1
- data/app/views/hyrax/base/_member.html.erb +1 -1
- data/app/views/hyrax/base/_representative_media.html.erb +1 -1
- data/app/views/hyrax/base/iiif_viewers/_universal_viewer.html.erb +1 -1
- data/app/views/hyrax/base/show.html.erb +2 -2
- data/app/views/hyrax/batch_select/_add_button.html.erb +1 -1
- data/app/views/hyrax/collections/_default_group.html.erb +2 -0
- data/app/views/hyrax/collections/show.html.erb +1 -1
- data/app/views/hyrax/dashboard/works/_default_group.html.erb +2 -0
- data/app/views/hyrax/embargoes/_list_expired_active_embargoes.html.erb +1 -1
- data/app/views/hyrax/leases/_list_expired_active_leases.html.erb +2 -1
- data/app/views/hyrax/my/works/_default_group.html.erb +2 -0
- data/app/views/layouts/hyrax.html.erb +0 -15
- data/bin/db-migrate-seed.sh +9 -0
- data/bin/db-wait.sh +14 -0
- data/bin/hyrax-entrypoint.sh +15 -0
- data/chart/fcrepo/.gitignore +2 -0
- data/chart/fcrepo/.helmignore +23 -0
- data/chart/fcrepo/Chart.yaml +11 -0
- data/chart/fcrepo/README.md +50 -0
- data/chart/fcrepo/templates/NOTES.txt +21 -0
- data/chart/fcrepo/templates/_helpers.tpl +68 -0
- data/chart/fcrepo/templates/configmap-env.yaml +19 -0
- data/chart/fcrepo/templates/deployment.yaml +109 -0
- data/chart/fcrepo/templates/ingress.yaml +41 -0
- data/chart/fcrepo/templates/pvc.yaml +20 -0
- data/chart/fcrepo/templates/secret.yaml +12 -0
- data/chart/fcrepo/templates/service.yaml +15 -0
- data/chart/fcrepo/templates/serviceaccount.yaml +12 -0
- data/chart/fcrepo/templates/tests/test-connection.yaml +15 -0
- data/chart/fcrepo/values.yaml +79 -0
- data/chart/hyrax/.gitignore +2 -0
- data/chart/hyrax/.helmignore +23 -0
- data/chart/hyrax/Chart.yaml +27 -0
- data/chart/hyrax/README.md +69 -0
- data/chart/hyrax/templates/NOTES.txt +21 -0
- data/chart/hyrax/templates/_helpers.tpl +92 -0
- data/chart/hyrax/templates/configmap-env.yaml +32 -0
- data/chart/hyrax/templates/deployment.yaml +79 -0
- data/chart/hyrax/templates/fcrepo-secret.yaml +13 -0
- data/chart/hyrax/templates/hpa.yaml +28 -0
- data/chart/hyrax/templates/ingress.yaml +41 -0
- data/chart/hyrax/templates/secrets.yaml +12 -0
- data/chart/hyrax/templates/service.yaml +15 -0
- data/chart/hyrax/templates/serviceaccount.yaml +12 -0
- data/chart/hyrax/templates/tests/test-connection.yaml +15 -0
- data/chart/hyrax/values.yaml +97 -0
- data/config/initializers/indexing_adapter_initializer.rb +7 -12
- data/config/initializers/listeners.rb +2 -0
- data/config/locales/hyrax.en.yml +1 -1
- data/config/metadata/basic_metadata.yaml +13 -0
- data/db/seeds.rb +20 -0
- data/docker-compose.yml +132 -0
- data/documentation/developing-your-hyrax-based-app.md +271 -0
- data/documentation/legacyREADME.md +336 -0
- data/documentation/note-about-versions.md +15 -0
- data/hyrax.gemspec +7 -8
- data/lib/generators/hyrax/templates/config/initializers/hyrax.rb +4 -6
- data/lib/generators/hyrax/templates/config/locales/hyrax.es.yml +1 -1
- data/lib/generators/hyrax/templates/db/seeds.rb +16 -14
- data/lib/generators/hyrax/templates/uv.html +1 -1
- data/lib/generators/hyrax/work_resource/templates/controller.rb.erb +0 -5
- data/lib/generators/hyrax/work_resource/templates/form.rb.erb +1 -1
- data/lib/generators/hyrax/work_resource/templates/work.html.erb_spec.rb.erb +3 -2
- data/lib/hyrax.rb +17 -0
- data/lib/hyrax/configuration.rb +340 -200
- data/lib/hyrax/event_store.rb +5 -0
- data/lib/hyrax/form_fields.rb +1 -1
- data/lib/hyrax/indexer.rb +19 -3
- data/lib/hyrax/publisher.rb +71 -2
- data/lib/hyrax/resource_sync/change_list_writer.rb +1 -1
- data/lib/hyrax/resource_sync/resource_list_writer.rb +1 -1
- data/lib/hyrax/schema.rb +2 -2
- data/lib/hyrax/specs/capybara.rb +98 -0
- data/lib/hyrax/specs/clamav.rb +15 -0
- data/lib/hyrax/specs/disable_animations_in_test_environment.rb +53 -0
- data/lib/hyrax/specs/engine_routes.rb +11 -0
- data/lib/hyrax/specs/shared_specs/change_set.rb +11 -0
- data/lib/hyrax/specs/shared_specs/factories/strategies/json_strategy.rb +13 -0
- data/lib/hyrax/specs/shared_specs/factories/strategies/valkyrie_resource.rb +0 -11
- data/lib/hyrax/specs/shared_specs/hydra_works.rb +6 -0
- data/lib/hyrax/specs/shared_specs/indexers.rb +22 -5
- data/lib/hyrax/specs/shared_specs/metadata.rb +64 -0
- data/lib/hyrax/specs/spy_listener.rb +52 -26
- data/lib/hyrax/transactions/container.rb +13 -1
- data/lib/hyrax/transactions/steps/add_file_sets.rb +35 -0
- data/lib/hyrax/transactions/steps/save.rb +10 -4
- data/lib/hyrax/transactions/steps/save_access_control.rb +29 -0
- data/lib/hyrax/transactions/steps/set_default_admin_set.rb +1 -1
- data/lib/hyrax/transactions/update_work.rb +3 -1
- data/lib/hyrax/transactions/work_create.rb +3 -1
- data/lib/hyrax/version.rb +1 -1
- data/lib/tasks/collection_type_global_id.rake +22 -0
- data/lib/tasks/default_admin_set.rake +5 -0
- data/lib/wings.rb +1 -1
- data/lib/wings/active_fedora_converter.rb +71 -123
- data/lib/wings/active_fedora_converter/default_work.rb +129 -0
- data/lib/wings/active_fedora_converter/nested_resource.rb +25 -0
- data/lib/wings/attribute_transformer.rb +28 -1
- data/lib/wings/converter_value_mapper.rb +70 -3
- data/lib/wings/model_registry.rb +4 -3
- data/lib/wings/model_transformer.rb +25 -7
- data/lib/wings/orm_converter.rb +19 -23
- data/lib/wings/services/custom_queries/find_collections_by_type.rb +1 -1
- data/lib/wings/services/custom_queries/find_file_metadata.rb +65 -38
- data/lib/wings/services/file_converter_service.rb +6 -55
- data/lib/wings/services/file_metadata_builder.rb +12 -8
- data/lib/wings/setup.rb +56 -9
- data/lib/wings/transformer_value_mapper.rb +1 -0
- data/lib/wings/valkyrie/metadata_adapter.rb +2 -2
- data/lib/wings/valkyrie/persister.rb +13 -14
- data/lib/wings/valkyrie/storage.rb +94 -0
- data/tasks/benchmark.rake +56 -0
- data/template.rb +1 -3
- metadata +346 -54
- data/lib/hyrax/callbacks.rb +0 -27
- data/lib/wings/hydra/pcdm/models/concerns/collection_valkyrie_behavior.rb +0 -28
- data/lib/wings/hydra/pcdm/models/concerns/object_valkyrie_behavior.rb +0 -28
- data/lib/wings/hydra/pcdm/models/concerns/pcdm_valkyrie_behavior.rb +0 -171
- data/lib/wings/hydra/works/models/concerns/collection_valkyrie_behavior.rb +0 -31
- data/lib/wings/hydra/works/models/concerns/file_set_valkyrie_behavior.rb +0 -31
- data/lib/wings/hydra/works/models/concerns/work_valkyrie_behavior.rb +0 -60
- data/lib/wings/models/concerns/collection_behavior.rb +0 -39
- data/lib/wings/models/multi_checksum.rb +0 -18
- data/lib/wings/services/id_converter_service.rb +0 -15
- data/lib/wings/valkyrie/storage/active_fedora.rb +0 -27
@@ -0,0 +1,336 @@
|
|
1
|
+
# Legacy README
|
2
|
+
|
3
|
+
This is a deprecated document that might have some useful information.
|
4
|
+
|
5
|
+
# Table of Contents
|
6
|
+
|
7
|
+
* [What is Hyrax?](#what-is-hyrax)
|
8
|
+
* [Feature Documentation](#feature-documentation)
|
9
|
+
* [Help](#help)
|
10
|
+
* [Getting started](#getting-started)
|
11
|
+
* [Note about Versions](#note-about-versions)
|
12
|
+
* [Prerequisites](#prerequisites)
|
13
|
+
* [Characterization](#characterization)
|
14
|
+
* [Derivatives](#derivatives)
|
15
|
+
* [Transcoding](#transcoding)
|
16
|
+
* [Environments](#environments)
|
17
|
+
* [Ruby](#ruby)
|
18
|
+
* [Redis](#redis)
|
19
|
+
* [Rails](#rails)
|
20
|
+
* [JavaScript runtime](#javascript-runtime)
|
21
|
+
* [Creating a Hyrax\-based app](#creating-a-hyrax-based-app)
|
22
|
+
* [Start servers](#start-servers)
|
23
|
+
* [Start background workers](#start-background-workers)
|
24
|
+
* [Create default administrative set](#create-default-administrative-set)
|
25
|
+
* [Generate a work type](#generate-a-work-type)
|
26
|
+
* [Enable notifications](#enable-notifications)
|
27
|
+
* [Managing a Hyrax\-based app](#managing-a-hyrax-based-app)
|
28
|
+
* [Toggling Features](#toggling-features)
|
29
|
+
* [Contributing](#contributing)
|
30
|
+
* [Development](#development)
|
31
|
+
* [Reporting Security Issues](#reporting-security-issues)
|
32
|
+
* [Workflow Relationship Diagram](#workflow-relationship-diagram)
|
33
|
+
* [Acknowledgments](#acknowledgments)
|
34
|
+
|
35
|
+
# What is Hyrax?
|
36
|
+
|
37
|
+
Hyrax is a front-end based on the robust [Samvera](http://samvera.org) framework, providing a user interface for common repository features. Hyrax offers the ability to create repository object types on demand, to deposit content via multiple configurable workflows, and to describe content with flexible metadata. Numerous optional features may be turned on in the administrative dashboard or added through plugins. It is implemented as a Rails engine, so it may be the base of, or added to, a Rails application. Hyrax is the consolidation of Sufia and the CurationConcerns gems and behaves in much the same way.
|
38
|
+
|
39
|
+
# Feature Documentation
|
40
|
+
|
41
|
+
* List of features: [Feature Matrix](https://github.com/samvera/hyrax/wiki/Feature-matrix)
|
42
|
+
* Configuration and enabling features: [Hyrax Management Guide](https://github.com/samvera/hyrax/wiki/Hyrax-Management-Guide)
|
43
|
+
* Walk-through on using features: [Hyrax Feature Guides](https://samvera.github.io/intro-to.html)
|
44
|
+
* For general information about Hyrax: [Hyrax Site](https://hyrax.samvera.org/)
|
45
|
+
|
46
|
+
# Help
|
47
|
+
|
48
|
+
The Samvera community is here to help. Please see our [support guide](./.github/SUPPORT.md).
|
49
|
+
|
50
|
+
# Getting started
|
51
|
+
|
52
|
+
This document contains instructions specific to setting up an app with __Hyrax
|
53
|
+
v3.0.0-rc3__. If you are looking for instructions on installing a different
|
54
|
+
version, be sure to select the appropriate branch or tag from the drop-down
|
55
|
+
menu above.
|
56
|
+
|
57
|
+
## Note about Versions
|
58
|
+
|
59
|
+
Hyrax has far more tags than released versions. This section provides context and wayfinding on navigating that reality.
|
60
|
+
|
61
|
+
The history of Hyrax involves the merging of [Sufia](https://github.com/samvera-deprecated/sufia) and [Curation Concerns](https://github.com/samvera-deprecated/curation_concerns). Each of those projects had their own releases and tags. In preserving commit history of the work, we collectively brought along those past tags (for better or for worse).
|
62
|
+
|
63
|
+
This means that we have a mix of Hyrax releases and associated tags as well as tags for those other gems' releases. Which can be confusing.
|
64
|
+
|
65
|
+
When you include Hyrax in your Gemfile, and reference a version (eg. `gem "hyrax", "~> 2.7"`), you are getting that version from Rubygems. When you reference a tag (eg. `gem "hyrax", github: "samvera/hyrax", ref: "v2.7.0"`) you are getting that information from Github. Both are reasonable and dependent on your situation. In the case of the former, you're likely wanting stable releases. In the case of the latter, you may be looking to use specific commits that include unreleased bug fixes.
|
66
|
+
|
67
|
+
The place to find the canonical Hyrax releases is at https://rubygems.org/gems/hyrax, there you can find a list of versions. Those versions map to tags in Hyrax (e.g. you can expect that the version in Rubygems and the tag in Hyrax have the same code). The release notes for those versions will be further described in [Hyrax's releases](https://github.com/samvera/hyrax/releases/). However, within the Hyrax releases, you'll also see other non-released Hyrax versions. These are likely the tags from the preceding gems (`sufia` and `curation_concern`).
|
68
|
+
|
69
|
+
_**NOTE**: In our [2020-07-29 Samvera Tech call](https://wiki.lyrasis.org/display/samvera/Samvera+Tech+Call+2020-07-29), some of the contributors discussed how to proceed with our current state. This section is our effort to provide wayfinding around the confusing tag proliferation in our repository._
|
70
|
+
|
71
|
+
## Prerequisites
|
72
|
+
|
73
|
+
Prerequisites are required for both creating a Hyrax\-based app and contributing new features to Hyrax. After installing the prerequisites...
|
74
|
+
|
75
|
+
* If you would like to create a new application using Hyrax follow the instructions for [Creating a Hyrax\-based app](#creating-a-hyrax-based-app).
|
76
|
+
* If you would like to create new features for Hyrax follow the instructions for [Contributing](#contributing) and [Development](#development).
|
77
|
+
|
78
|
+
Hyrax requires the following software to work:
|
79
|
+
|
80
|
+
1. [Solr](http://lucene.apache.org/solr/) version >= 5.x (tested up to 8.7.0)
|
81
|
+
1. [Fedora Commons](http://www.fedora-commons.org/) digital repository version >= 4.5.1 (tested up to 4.7.5)
|
82
|
+
1. A SQL RDBMS (MySQL, PostgreSQL), though **note** that SQLite will be used by default if you're looking to get up and running quickly
|
83
|
+
1. [Redis](http://redis.io/), a key-value store
|
84
|
+
1. [ImageMagick](http://www.imagemagick.org/) with JPEG-2000 support
|
85
|
+
1. [FITS](#characterization) version 1.0.x (1.0.5 is known to be good, 1.1.0 is known to be bad: https://github.com/harvard-lts/fits/issues/140)
|
86
|
+
1. [LibreOffice](#derivatives)
|
87
|
+
1. [ffmpeg](#transcoding)
|
88
|
+
|
89
|
+
**NOTE: The [Hyrax Development Guide](https://github.com/samvera/hyrax/wiki/Hyrax-Development-Guide) has instructions for installing Solr and Fedora in a development environment.**
|
90
|
+
|
91
|
+
### Characterization
|
92
|
+
|
93
|
+
FITS can be installed on OSX using Homebrew by running the command: `brew install fits`
|
94
|
+
|
95
|
+
**OR**
|
96
|
+
|
97
|
+
1. Go to http://projects.iq.harvard.edu/fits/downloads and download a copy of FITS (see above to pick a known working version) & unpack it somewhere on your machine.
|
98
|
+
1. Mark fits.sh as executable: `chmod a+x fits.sh`
|
99
|
+
1. Run `fits.sh -h` from the command line and see a help message to ensure FITS is properly installed
|
100
|
+
1. Give your Hyrax app access to FITS by:
|
101
|
+
1. Adding the full fits.sh path to your PATH (e.g., in your .bash\_profile), **OR**
|
102
|
+
1. Changing `config/initializers/hyrax.rb` to point to your FITS location: `config.fits_path = "/<your full path>/fits.sh"`
|
103
|
+
|
104
|
+
### Derivatives
|
105
|
+
|
106
|
+
Install [LibreOffice](https://www.libreoffice.org/). If `which soffice` returns a path, you're done. Otherwise, add the full path to soffice to your PATH (in your `.bash_profile`, for instance). On OSX, soffice is **inside** LibreOffice.app. Your path may look like "/path/to/LibreOffice.app/Contents/MacOS/"
|
107
|
+
|
108
|
+
You may also require [ghostscript](http://www.ghostscript.com/) if it does not come with your compiled version LibreOffice. `brew install ghostscript` should resolve the dependency on an OSX-based machine with Homebrew installed.
|
109
|
+
|
110
|
+
**NOTE**: Derivatives are served from the filesystem in Hyrax.
|
111
|
+
|
112
|
+
### Transcoding
|
113
|
+
|
114
|
+
Hyrax includes support for transcoding audio and video files with ffmpeg > 1.0 installed.
|
115
|
+
|
116
|
+
On OSX, you can use Homebrew to install ffmpeg:
|
117
|
+
|
118
|
+
`brew install libvpx ffmpeg`
|
119
|
+
|
120
|
+
Otherwise, to compile ffmpeg yourself, see the [ffmpeg compilation guide](https://trac.ffmpeg.org/wiki/CompilationGuide).
|
121
|
+
|
122
|
+
Once ffmpeg has been installed, enable transcoding by setting `config.enable_ffmpeg = true` in `config/initializers/hyrax.rb`. You may also configure the location of ffmpeg using `config.ffmpeg_path`.
|
123
|
+
|
124
|
+
## Environments
|
125
|
+
|
126
|
+
Note here that the following commands assume you're setting up Hyrax in a development environment (using the Rails built-in development environment). If you're setting up a production or production-like environment, you may wish to tell Rails that by prepending `RAILS_ENV=production` to the commands that follow, e.g., `rails`, `rake`, `bundle`, and so on.
|
127
|
+
|
128
|
+
## Ruby
|
129
|
+
|
130
|
+
First, you'll need a working Ruby installation. You can install this via your operating system's package manager -- you are likely to get farther with OSX, Linux, or UNIX than Windows but your mileage may vary -- but we recommend using a Ruby version manager such as [RVM](https://rvm.io/) or [rbenv](https://github.com/sstephenson/rbenv).
|
131
|
+
|
132
|
+
Hyrax supports Ruby 2.5, 2.6, and 2.7. When starting a new project, we recommend using the latest Ruby 2.7 version.
|
133
|
+
|
134
|
+
## Redis
|
135
|
+
|
136
|
+
[Redis](http://redis.io/) is a key-value store that Hyrax uses to provide activity streams on repository objects and users, and to prevent race conditions as a global mutex when modifying order-persisting objects.
|
137
|
+
|
138
|
+
Starting up Redis will depend on your operating system, and may in fact already be started on your system. You may want to consult the [Redis documentation](http://redis.io/documentation) for help doing this.
|
139
|
+
|
140
|
+
## Rails
|
141
|
+
|
142
|
+
Hyrax requires Rails 5. We recommend the latest Rails 5.2 release.
|
143
|
+
|
144
|
+
```
|
145
|
+
# If you don't already have Rails at your disposal...
|
146
|
+
gem install rails -v 5.2.4.4
|
147
|
+
```
|
148
|
+
|
149
|
+
### JavaScript runtime
|
150
|
+
|
151
|
+
Rails requires that you have a JavaScript runtime installed (e.g. nodejs or rubyracer). Either install nodejs or uncomment the `rubyracer` line in your Gemfile and run `bundle install` before running Hyrax's install generator.
|
152
|
+
|
153
|
+
NOTE: nodejs is preinstalled on most Mac computers and doesn't require a gem. To test if nodejs is already installed, execute `node -v` in the terminal and the version of nodejs will be displayed if it is installed.
|
154
|
+
|
155
|
+
# Creating a Hyrax-based app
|
156
|
+
|
157
|
+
NOTE: The steps need to be done in order to create a new Hyrax based app.
|
158
|
+
|
159
|
+
Generate a new Rails application using the template.
|
160
|
+
|
161
|
+
```
|
162
|
+
rails _5.2.4.4_ new my_app -m https://raw.githubusercontent.com/samvera/hyrax/v3.0.0-rc3/template.rb
|
163
|
+
```
|
164
|
+
|
165
|
+
Generating a new Rails application using Hyrax's template above takes cares of a number of steps for you, including:
|
166
|
+
|
167
|
+
* Adding Hyrax (and any of its dependencies) to your application `Gemfile`, to declare that Hyrax is a dependency of your application
|
168
|
+
* Running `bundle install`, to install Hyrax and its dependencies
|
169
|
+
* Running Hyrax's install generator, to add a number of files that Hyrax requires within your Rails app, including e.g. database migrations
|
170
|
+
* Loading all of Hyrax's database migrations into your application's database
|
171
|
+
* Loading Hyrax's default workflows into your application's database
|
172
|
+
* Create default collection types (e.g. Admin Set, User Collection)
|
173
|
+
|
174
|
+
## Start servers
|
175
|
+
|
176
|
+
To test-drive your new Hyrax application in development mode, spin up the servers that Hyrax needs (Solr, Fedora, and Rails):
|
177
|
+
|
178
|
+
```
|
179
|
+
bin/rails hydra:server
|
180
|
+
```
|
181
|
+
|
182
|
+
And now you should be able to browse to [localhost:3000](http://localhost:3000/) and see the application.
|
183
|
+
|
184
|
+
Notes:
|
185
|
+
* This web server is purely for development purposes. You will want to use a more fully featured [web server](https://github.com/samvera/hyrax/wiki/Hyrax-Management-Guide#web-server) for production-like environments.
|
186
|
+
* You have the option to start each of these services individually. More information on [solr_wrapper](https://github.com/cbeer/solr_wrapper) and [fcrepo_wrapper](https://github.com/cbeer/fcrepo_wrapper) will help you set this up. Start rails with `rails s`.
|
187
|
+
|
188
|
+
## Start background workers
|
189
|
+
|
190
|
+
Many of the services performed by Hyrax are resource intensive, and therefore are well suited to running as background jobs that can be managed and executed by a message queuing system. Examples include:
|
191
|
+
|
192
|
+
* File ingest
|
193
|
+
* Derivative generation
|
194
|
+
* Characterization
|
195
|
+
* Fixity
|
196
|
+
* Solr indexing
|
197
|
+
|
198
|
+
Hyrax implements these jobs using the Rails [ActiveJob](http://edgeguides.rubyonrails.org/active_job_basics.html) framework, allowing you to choose the message queue system of your choice.
|
199
|
+
|
200
|
+
For initial development, it is recommended that you change the default ActiveJob adapter from `:async` to `:inline`. This adapter will execute jobs immediately (in the foreground) as they are received. This can be accomplished by adding the following to your `config/environments/development.rb`
|
201
|
+
|
202
|
+
```
|
203
|
+
class Application < Rails::Application
|
204
|
+
# ...
|
205
|
+
config.active_job.queue_adapter = :inline
|
206
|
+
# ...
|
207
|
+
end
|
208
|
+
```
|
209
|
+
|
210
|
+
For testing, it is recommended that you use the [built-in `:test` adapter](http://api.rubyonrails.org/classes/ActiveJob/QueueAdapters/TestAdapter.html) which stores enqueued and performed jobs, running only those configured to run during test setup. To do this, add the following to `config/environments/test.rb`:
|
211
|
+
|
212
|
+
```ruby
|
213
|
+
Rails.application.configure do
|
214
|
+
# ...
|
215
|
+
config.active_job.queue_adapter = :test
|
216
|
+
# ...
|
217
|
+
end
|
218
|
+
```
|
219
|
+
|
220
|
+
**For production applications** you will want to use a more robust message queue system such as [Sidekiq](http://sidekiq.org/). The Hyrax Development Guide has a detailed walkthrough of [installing and configuring Sidekiq](https://github.com/samvera/hyrax/wiki/Using-Sidekiq-with-Hyrax).
|
221
|
+
|
222
|
+
## Create default administrative set
|
223
|
+
|
224
|
+
**After** Fedora and Solr are running, create the default administrative set -- into which all works will be deposited unless assigned to other administrative sets -- by running the following command:
|
225
|
+
|
226
|
+
```
|
227
|
+
bin/rails hyrax:default_admin_set:create
|
228
|
+
```
|
229
|
+
|
230
|
+
This command also makes sure that Hyrax's built-in workflows are loaded for your application and available for the default administrative set.
|
231
|
+
|
232
|
+
**NOTE**: You will want to run this command the first time this code is deployed to a new environment as well.
|
233
|
+
|
234
|
+
## Generate a work type
|
235
|
+
|
236
|
+
Using Hyrax requires generating at least one type of repository object, or "work type." Hyrax allows you to generate the work types required in your application by using a Rails generator-based tool. You may generate one or more of these work types.
|
237
|
+
|
238
|
+
Pass a (CamelCased) model name to Hyrax's work generator to get started, e.g.:
|
239
|
+
|
240
|
+
```
|
241
|
+
rails generate hyrax:work Work
|
242
|
+
```
|
243
|
+
|
244
|
+
or
|
245
|
+
|
246
|
+
```
|
247
|
+
rails generate hyrax:work MovingImage
|
248
|
+
```
|
249
|
+
|
250
|
+
If your applications requires your work type to be namespaced, namespaces can be included in the by adding a slash to the model name which creates a new class called `MovingImage` within the `My` namespace:
|
251
|
+
|
252
|
+
```
|
253
|
+
rails generate hyrax:work My/MovingImage
|
254
|
+
```
|
255
|
+
|
256
|
+
You may wish to [customize your work type](https://github.com/samvera/hyrax/wiki/Customizing-your-work-types) now that it's been generated.
|
257
|
+
|
258
|
+
## Enable notifications
|
259
|
+
|
260
|
+
Hyrax 2 uses a WebSocket-based user notifications system, which requires Redis. To enable user notifications, make sure that you have configured ActionCable to use Redis as the adapter in your application's `config/cable.yml`. E.g., for the `development` Rails environment:
|
261
|
+
|
262
|
+
```yaml
|
263
|
+
development:
|
264
|
+
adapter: redis
|
265
|
+
url: redis://localhost:6379
|
266
|
+
```
|
267
|
+
|
268
|
+
Using Rails up to version 5.1.4, ActionCable will not work with the 4.x series of the `redis` gem, so you will also need to pin your application to a 3.x release by adding this to your `Gemfile`:
|
269
|
+
|
270
|
+
```ruby
|
271
|
+
gem 'redis', '~> 3.0'
|
272
|
+
```
|
273
|
+
|
274
|
+
And then run `bundle update redis`.
|
275
|
+
|
276
|
+
Note that the Hyrax Management Guide contains additional information on [how to configure ActionCable in production environments](https://github.com/samvera/hyrax/wiki/Hyrax-Management-Guide#notifications).
|
277
|
+
|
278
|
+
# Managing a Hyrax-based app
|
279
|
+
|
280
|
+
The [Hyrax Management Guide](https://github.com/samvera/hyrax/wiki/Hyrax-Management-Guide) provides tips for how to manage, customize, and enhance your Hyrax application, including guidance specific to:
|
281
|
+
|
282
|
+
* Production implementations
|
283
|
+
* Configuration of background workers
|
284
|
+
* Integration with e.g., Dropbox, Google Analytics, and Zotero
|
285
|
+
* Audiovisual transcoding with `ffmpeg`
|
286
|
+
* Setting up administrative users
|
287
|
+
* Metadata customization
|
288
|
+
* Virus checking
|
289
|
+
* Workflows
|
290
|
+
|
291
|
+
## Toggling Features
|
292
|
+
|
293
|
+
Some features in Hyrax can be flipped on and off from either the Administrative
|
294
|
+
Dashboard or via a YAML configuration file at `config/features.yml`. An example
|
295
|
+
of the YAML file is below:
|
296
|
+
|
297
|
+
```yaml
|
298
|
+
assign_admin_set:
|
299
|
+
enabled: "false"
|
300
|
+
proxy_deposit:
|
301
|
+
enabled: "false"
|
302
|
+
```
|
303
|
+
|
304
|
+
If both options exist, whichever option is set from the Administrative Dashboard
|
305
|
+
will take precedence.
|
306
|
+
|
307
|
+
# Contributing
|
308
|
+
|
309
|
+
We'd love to accept your contributions. Please see our guide to [contributing to Hyrax](./.github/CONTRIBUTING.md).
|
310
|
+
|
311
|
+
If you'd like to help the development effort and you're not sure where to get started, you can always grab a ticket in the "Ready" column from our [Waffle board](https://waffle.io/samvera/hyrax). There are other ways to help, too.
|
312
|
+
|
313
|
+
* The Hyrax user interface is translated into a number of languages, and many of these translations come from Google Translate. If you are a native or fluent speaker of a non-English language, your help improving these translations are most welcome. (Hyrax currently supports English, Spanish, Chinese, Italian, German, French, and Portuguese.)
|
314
|
+
* Do you see English in the application where you would expect to see one of the languages above? If so, [file an issue](https://github.com/samvera/hyrax/issues/new) and suggest a translation, please.
|
315
|
+
* [Contribute a user story](https://github.com/samvera/hyrax/issues/new).
|
316
|
+
* Help us improve [Hyrax's test coverage](https://coveralls.io/r/samvera/hyrax) or [documentation coverage](https://inch-ci.org/github/samvera/hyrax).
|
317
|
+
* Refactor away [code smells](https://codeclimate.com/github/samvera/hyrax).
|
318
|
+
|
319
|
+
# Development
|
320
|
+
|
321
|
+
The [Hyrax Development Guide](https://github.com/samvera/hyrax/wiki/Hyrax-Development-Guide) is for people who want to modify Hyrax itself, not an application that uses Hyrax. See especially the [Quick Start](https://github.com/samvera/hyrax/wiki/Hyrax-Development-Guide#quick-start-for-hyrax-development) guide and instructions for running the [Hyrax test suite](https://github.com/samvera/hyrax/wiki/Hyrax-Development-Guide#run-the-test-suite).
|
322
|
+
|
323
|
+
## Reporting Security Issues
|
324
|
+
|
325
|
+
To report a security vulnerability, email [samvera-steering@googlegroups.com](mailto:samvera-steering@googlegroups.com) and the Steering Group will coordinate the community response. In your message, please document to the best of your ability cases (relevant software versions, conditions, etc.) where the vulnerability is applicable, the potential negative effects, and any known workarounds or fixes to mitigate the risk. Steering will communicate this to the Partners and the rest of the community in a timely fashion.
|
326
|
+
|
327
|
+
## Workflow Relationship Diagram
|
328
|
+
|
329
|
+
* [Entity Relationship Diagram](./artifacts/entity-relationship-diagram.pdf)
|
330
|
+
|
331
|
+
# Acknowledgments
|
332
|
+
|
333
|
+
This software has been developed by and is brought to you by the Samvera community. Learn more at the
|
334
|
+
[Samvera website](http://samvera.org/).
|
335
|
+
|
336
|
+
![Samvera Logo](https://wiki.duraspace.org/download/thumbnails/87459292/samvera-fall-font2-200w.png?version=1&modificationDate=1498550535816&api=v2)
|
@@ -0,0 +1,15 @@
|
|
1
|
+
# Note about Versions
|
2
|
+
|
3
|
+
Hyrax has far more tags than released versions. This section provides context and wayfinding on navigating that reality.
|
4
|
+
|
5
|
+
The history of Hyrax involves the merging of [Sufia](https://github.com/samvera-deprecated/sufia) and [Curation Concerns](https://github.com/samvera-deprecated/curation_concerns). Each of those projects had their own releases and tags. In preserving commit history of the work, we collectively brought along those past tags (for better or for worse).
|
6
|
+
|
7
|
+
This means that we have a mix of Hyrax releases and associated tags as well as tags for those other gems' releases. Which can be confusing.
|
8
|
+
|
9
|
+
When you include Hyrax in your Gemfile, and reference a version (eg. `gem "hyrax", "~> 2.7"`), you are getting that version from Rubygems. When you reference a tag (eg. `gem "hyrax", github: "samvera/hyrax", ref: "v2.7.0"`) you are getting that information from Github. Both are reasonable and dependent on your situation. In the case of the former, you're likely wanting stable releases. In the case of the latter, you may be looking to use specific commits that include unreleased bug fixes.
|
10
|
+
|
11
|
+
The place to find the canonical Hyrax releases is at https://rubygems.org/gems/hyrax, there you can find a list of versions. Those versions map to tags in Hyrax (e.g. you can expect that the version in Rubygems and the tag in Hyrax have the same code). The release notes for those versions will be further described in [Hyrax's releases](https://github.com/samvera/hyrax/releases/). However, within the Hyrax releases, you'll also see other non-released Hyrax versions. These are likely the tags from the preceding gems (`sufia` and `curation_concern`).
|
12
|
+
|
13
|
+
_**NOTE**: In our [2020-07-29 Samvera Tech call](https://wiki.lyrasis.org/display/samvera/Samvera+Tech+Call+2020-07-29), some of the contributors discussed how to proceed with our current state. This section is our effort to provide wayfinding around the confusing tag proliferation in our repository._
|
14
|
+
|
15
|
+
[Go back to the top-level documentation.](/README.md)
|
data/hyrax.gemspec
CHANGED
@@ -31,7 +31,7 @@ SUMMARY
|
|
31
31
|
# http://guides.rubyonrails.org/maintenance_policy.html
|
32
32
|
spec.add_dependency 'rails', '~> 5.0'
|
33
33
|
|
34
|
-
spec.add_dependency 'active-fedora', '~> 13.1.2'
|
34
|
+
spec.add_dependency 'active-fedora', '~> 13.1', '>= 13.1.2'
|
35
35
|
spec.add_dependency 'almond-rails', '~> 0.1'
|
36
36
|
spec.add_dependency 'awesome_nested_set', '~> 3.1'
|
37
37
|
spec.add_dependency 'blacklight', '~> 6.14'
|
@@ -52,7 +52,7 @@ SUMMARY
|
|
52
52
|
spec.add_dependency 'font-awesome-rails', '~> 4.2'
|
53
53
|
spec.add_dependency 'hydra-derivatives', '~> 3.3'
|
54
54
|
spec.add_dependency 'hydra-editor', '~> 5.0'
|
55
|
-
spec.add_dependency 'hydra-head', '~> 11.0'
|
55
|
+
spec.add_dependency 'hydra-head', '~> 11.0', ">= 11.0.1"
|
56
56
|
spec.add_dependency 'hydra-works', '>= 0.16', '< 2.0'
|
57
57
|
spec.add_dependency 'iiif_manifest', '>= 0.3', '< 2.0'
|
58
58
|
spec.add_dependency 'jquery-datatables-rails', '~> 3.4'
|
@@ -69,10 +69,10 @@ SUMMARY
|
|
69
69
|
spec.add_dependency 'oauth2', '~> 1.2'
|
70
70
|
spec.add_dependency 'posix-spawn'
|
71
71
|
spec.add_dependency 'power_converter', '~> 0.1', '>= 0.1.2'
|
72
|
-
spec.add_dependency 'qa', '
|
72
|
+
spec.add_dependency 'qa', '~> 5.5', '>= 5.5.1' # questioning_authority
|
73
73
|
spec.add_dependency 'rails_autolink', '~> 1.1'
|
74
74
|
spec.add_dependency 'rdf-rdfxml' # controlled vocabulary importer
|
75
|
-
spec.add_dependency 'rdf-vocab', '
|
75
|
+
spec.add_dependency 'rdf-vocab', '~> 3.0'
|
76
76
|
spec.add_dependency 'redis-namespace', '~> 1.5'
|
77
77
|
spec.add_dependency 'redlock', '>= 0.1.2'
|
78
78
|
spec.add_dependency 'reform', '~> 2.3'
|
@@ -85,7 +85,7 @@ SUMMARY
|
|
85
85
|
spec.add_dependency 'valkyrie', '>= 2.1.1', "< 3.0"
|
86
86
|
|
87
87
|
spec.add_development_dependency "capybara", '~> 3.29'
|
88
|
-
spec.add_development_dependency '
|
88
|
+
spec.add_development_dependency 'capybara-screenshot', '~> 1.0'
|
89
89
|
spec.add_development_dependency 'database_cleaner', '~> 1.3'
|
90
90
|
spec.add_development_dependency 'engine_cart', '~> 2.2'
|
91
91
|
spec.add_development_dependency "equivalent-xml", '~> 0.5'
|
@@ -100,15 +100,14 @@ SUMMARY
|
|
100
100
|
spec.add_development_dependency 'rspec-rails', '~> 3.1'
|
101
101
|
spec.add_development_dependency 'rspec_junit_formatter'
|
102
102
|
spec.add_development_dependency "selenium-webdriver"
|
103
|
-
spec.add_development_dependency 'solr_wrapper', '>= 1.1', '< 3.0'
|
104
103
|
spec.add_development_dependency 'i18n-debug'
|
105
104
|
spec.add_development_dependency 'i18n_yaml_sorter'
|
106
105
|
spec.add_development_dependency 'rails-controller-testing', '~> 1'
|
107
106
|
# the hyrax style guide is based on `bixby`. see `.rubocop.yml`
|
108
|
-
spec.add_development_dependency 'bixby', '~> 3.0'
|
107
|
+
spec.add_development_dependency 'bixby', '~> 3.0', ">= 3.0.2"
|
109
108
|
spec.add_development_dependency 'shoulda-callback-matchers', '~> 1.1.1'
|
110
109
|
spec.add_development_dependency 'shoulda-matchers', '~> 3.1'
|
111
|
-
spec.add_development_dependency 'webdrivers', '~>
|
110
|
+
spec.add_development_dependency 'webdrivers', '~> 4.4'
|
112
111
|
spec.add_development_dependency 'webmock'
|
113
112
|
|
114
113
|
########################################################
|
@@ -187,7 +187,7 @@ Hyrax.config do |config|
|
|
187
187
|
# Location on local file system where uploaded files will be staged
|
188
188
|
# prior to being ingested into the repository or having derivatives generated.
|
189
189
|
# If you use a multi-server architecture, this MUST be a shared volume.
|
190
|
-
# config.working_path = Rails.root.join(
|
190
|
+
# config.working_path = Rails.root.join('tmp', 'uploads')
|
191
191
|
|
192
192
|
# Should the media display partial render a download link?
|
193
193
|
# config.display_media_download_link = true
|
@@ -232,17 +232,15 @@ Hyrax.config do |config|
|
|
232
232
|
# config.translate_uri_to_id = lambda do |id|
|
233
233
|
# "#{ActiveFedora.fedora.host}#{ActiveFedora.fedora.base_path}/#{Noid::Rails.treeify(id)}"
|
234
234
|
# end
|
235
|
-
# config.resource_id_to_uri_transformer = lambda do |resource, base_url|
|
236
|
-
# file_id = CGI.escape(resource.file_identifiers.first.to_s)
|
237
|
-
# fs_id = CGI.escape(resource.file_set_id.to_s)
|
238
|
-
# "#{base_url}#{::Noid::Rails.treeify(fs_id)}/files/#{file_id}"
|
239
|
-
# end
|
240
235
|
|
241
236
|
# When your application is ready to use the valkyrie index instead of the one
|
242
237
|
# maintained by active fedora, you will need to set this to true. You will
|
243
238
|
# also need to update your Blacklight configuration.
|
244
239
|
# config.query_index_from_valkyrie = false
|
245
240
|
|
241
|
+
## Configure index adapter for Valkyrie::Resources to use solr readonly indexer
|
242
|
+
# config.index_adapter = :solr_index
|
243
|
+
|
246
244
|
## Fedora import/export tool
|
247
245
|
#
|
248
246
|
# Path to the Fedora import export tool jar file
|
@@ -51,7 +51,7 @@ es:
|
|
51
51
|
suffix: "@example.org"
|
52
52
|
footer:
|
53
53
|
copyright_html: "<strong>Copyright © 2018 Samvera</strong> bajo licencia de Apache, Version 2.0"
|
54
|
-
service_html: Un servicio de <a href="http://samvera.org/" class="navbar-link" target="_blank">Samvera
|
54
|
+
service_html: Un servicio de <a href="http://samvera.org/" class="navbar-link" target="_blank">Samvera</a>.
|
55
55
|
institution_name: institución
|
56
56
|
institution_name_full: El nombre de la institución
|
57
57
|
product_name: Hyrax
|
@@ -16,9 +16,10 @@
|
|
16
16
|
# ActiveFedora::Cleaner.clean!
|
17
17
|
# exit
|
18
18
|
# rake db:drop db:create db:migrate
|
19
|
-
# bin/rails hyrax:default_admin_set:create
|
20
19
|
# rake db:seed
|
21
20
|
|
21
|
+
Hyrax::Engine.load_seed
|
22
|
+
|
22
23
|
# ---------------------------------
|
23
24
|
# methods to create various objects
|
24
25
|
# ---------------------------------
|
@@ -113,14 +114,15 @@ create_user('vw2@example.com', 'pppppp')
|
|
113
114
|
genuser = create_user('general_user@example.com', 'pppppp')
|
114
115
|
|
115
116
|
puts 'Create collection types for QA'
|
116
|
-
_discoverable_gid = create_collection_type('discoverable_collection_type', title: 'Discoverable', description: 'Sample collection type allowing collections to be discovered.', discoverable: true)
|
117
|
-
|
117
|
+
_discoverable_gid = create_collection_type('discoverable_collection_type', title: 'Discoverable', description: 'Sample collection type allowing collections to be discovered.', discoverable: true)
|
118
|
+
.to_global_id
|
119
|
+
_sharable_gid = create_collection_type('sharable_collection_type', title: 'Sharable', description: 'Sample collection type allowing collections to be shared.', sharable: true).to_global_id
|
118
120
|
options = { title: 'Multi-membership', description: 'Sample collection type allowing works to belong to multiple collections.', allow_multiple_membership: true }
|
119
121
|
_multi_membership_gid = create_collection_type('multi_membership_collection_type', options)
|
120
|
-
_nestable_1_gid = create_collection_type('nestable_1_collection_type', title: 'Nestable 1', description: 'A sample collection type allowing nesting.', nestable: true).
|
121
|
-
_nestable_2_gid = create_collection_type('nestable_2_collection_type', title: 'Nestable 2', description: 'Another sample collection type allowing nesting.', nestable: true).
|
122
|
-
_empty_gid = create_collection_type('empty_collection_type', title: 'Test Empty Collection Type', description: 'A collection type with 0 collections of this type').
|
123
|
-
inuse_gid = create_collection_type('inuse_collection_type', title: 'Test In-Use Collection Type', description: 'A collection type with at least one collection of this type').
|
122
|
+
_nestable_1_gid = create_collection_type('nestable_1_collection_type', title: 'Nestable 1', description: 'A sample collection type allowing nesting.', nestable: true).to_global_id
|
123
|
+
_nestable_2_gid = create_collection_type('nestable_2_collection_type', title: 'Nestable 2', description: 'Another sample collection type allowing nesting.', nestable: true).to_global_id
|
124
|
+
_empty_gid = create_collection_type('empty_collection_type', title: 'Test Empty Collection Type', description: 'A collection type with 0 collections of this type').to_global_id
|
125
|
+
inuse_gid = create_collection_type('inuse_collection_type', title: 'Test In-Use Collection Type', description: 'A collection type with at least one collection of this type').to_global_id
|
124
126
|
|
125
127
|
puts 'Create collections for QA'
|
126
128
|
inuse_col = create_public_collection(genuser, inuse_gid, 'inuse_col1', title: ['Public Collection of type In-Use'], description: ['Public collection of the type Test In-Use Collection Type.'])
|
@@ -157,11 +159,11 @@ user = create_user('foo@example.com', 'foobarbaz')
|
|
157
159
|
puts 'Create collection types for collection nesting ad hoc testing'
|
158
160
|
options = { title: 'Nestable Collection', description: 'Sample collection type that allows nesting of collections.',
|
159
161
|
nestable: true, discoverable: true, sharable: true, allow_multiple_membership: true }
|
160
|
-
nestable_gid = create_collection_type('nestable_collection', options).
|
162
|
+
nestable_gid = create_collection_type('nestable_collection', options).to_global_id
|
161
163
|
|
162
164
|
options = { title: 'Non-Nestable Collection', description: 'Sample collection type that DOES NOT allow nesting of collections.',
|
163
165
|
nestable: false, discoverable: true, sharable: true, allow_multiple_membership: true }
|
164
|
-
_nonnestable_gid = create_collection_type('nonnestable_collection', options).
|
166
|
+
_nonnestable_gid = create_collection_type('nonnestable_collection', options).to_global_id
|
165
167
|
|
166
168
|
puts 'Create collections for collection nesting ad hoc testing'
|
167
169
|
pnc = create_public_collection(user, nestable_gid, 'public_nestable', title: ['Public Nestable Collection'], description: ['Public nestable collection for use in ad hoc tests.'])
|
@@ -252,7 +254,7 @@ end
|
|
252
254
|
|
253
255
|
puts 'Create Expired, Authenticated Embargo works'
|
254
256
|
1.times do |i|
|
255
|
-
GenericWork.create(title: ["Expired Authenticated #{i}"], read_groups: [
|
257
|
+
GenericWork.create(title: ["Expired Authenticated #{i}"], read_groups: [Hyrax.config.registered_user_group_name]) do |work|
|
256
258
|
work.apply_depositor_metadata(user)
|
257
259
|
work.apply_embargo(Date.yesterday.to_s, Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_PRIVATE, Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_AUTHENTICATED)
|
258
260
|
end
|
@@ -260,7 +262,7 @@ end
|
|
260
262
|
|
261
263
|
puts 'Create Expired, Public Embargo works'
|
262
264
|
3.times do |i|
|
263
|
-
GenericWork.create(title: ["Expired Public #{i}"], read_groups: [
|
265
|
+
GenericWork.create(title: ["Expired Public #{i}"], read_groups: [Hyrax.config.public_user_group_name]) do |work|
|
264
266
|
work.apply_depositor_metadata(user)
|
265
267
|
work.apply_embargo(Date.yesterday.to_s, Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_PRIVATE, Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_PUBLIC)
|
266
268
|
end
|
@@ -268,7 +270,7 @@ end
|
|
268
270
|
|
269
271
|
puts 'Create Active, Public Lease works'
|
270
272
|
3.times do |i|
|
271
|
-
GenericWork.create(title: ["Active Public #{i}"], read_groups: [
|
273
|
+
GenericWork.create(title: ["Active Public #{i}"], read_groups: [Hyrax.config.public_user_group_name]) do |work|
|
272
274
|
work.apply_depositor_metadata(user)
|
273
275
|
work.apply_lease(Date.tomorrow.to_s, Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_PUBLIC, Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_PRIVATE)
|
274
276
|
end
|
@@ -276,7 +278,7 @@ end
|
|
276
278
|
|
277
279
|
puts 'Create Active, Authenticated Lease works'
|
278
280
|
2.times do |i|
|
279
|
-
GenericWork.create(title: ["Active Authenticated #{i}"], read_groups: [
|
281
|
+
GenericWork.create(title: ["Active Authenticated #{i}"], read_groups: [Hyrax.config.registered_user_group_name]) do |work|
|
280
282
|
work.apply_depositor_metadata(user)
|
281
283
|
work.apply_lease(Date.tomorrow.to_s, Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_AUTHENTICATED, Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_PRIVATE)
|
282
284
|
end
|
@@ -284,7 +286,7 @@ end
|
|
284
286
|
|
285
287
|
puts 'Create Expired, Authenticated Lease works'
|
286
288
|
1.times do |i|
|
287
|
-
GenericWork.create(title: ["Expired Authenticated #{i}"], read_groups: [
|
289
|
+
GenericWork.create(title: ["Expired Authenticated #{i}"], read_groups: [Hyrax.config.registered_user_group_name]) do |work|
|
288
290
|
work.apply_depositor_metadata(user)
|
289
291
|
work.apply_lease(Date.yesterday.to_s, Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_PUBLIC, Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_AUTHENTICATED)
|
290
292
|
end
|