hyrax 3.0.0.pre.rc4 → 3.1.0
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 +41 -8
- data/.dassie/Gemfile +10 -5
- data/.dassie/config/cable.yml +1 -1
- data/.dassie/config/environments/development.rb +2 -0
- data/.dassie/config/environments/production.rb +1 -1
- data/.dassie/config/initializers/hyrax.rb +5 -0
- data/.dassie/config/initializers/riiif.rb +22 -20
- data/.dassie/config/redis.yml +1 -0
- data/.dassie/config/role_map.yml +2 -0
- data/.dassie/db/seeds.rb +9 -1
- data/.dassie/package.json +3 -5
- data/.dockerignore +4 -0
- data/.env +1 -2
- data/.rubocop.yml +4 -0
- data/CONTAINERS.md +21 -1
- data/Dockerfile +46 -17
- data/Gemfile +21 -27
- data/app/actors/hyrax/actors/base_actor.rb +1 -1
- data/app/actors/hyrax/actors/create_with_remote_files_actor.rb +89 -41
- data/app/actors/hyrax/actors/create_with_remote_files_ordered_members_actor.rb +7 -42
- data/app/actors/hyrax/actors/file_actor.rb +4 -2
- data/app/actors/hyrax/actors/file_set_actor.rb +18 -11
- data/app/controllers/concerns/hyrax/collections_controller_behavior.rb +20 -8
- data/app/controllers/concerns/hyrax/embargoes_controller_behavior.rb +21 -9
- data/app/controllers/concerns/hyrax/leases_controller_behavior.rb +14 -5
- data/app/controllers/concerns/hyrax/works_controller_behavior.rb +38 -8
- data/app/controllers/hyrax/admin/permission_template_accesses_controller.rb +0 -4
- data/app/controllers/hyrax/admin/workflows_controller.rb +8 -2
- data/app/controllers/hyrax/dashboard/collection_members_controller.rb +13 -9
- data/app/controllers/hyrax/dashboard/collections_controller.rb +14 -14
- data/app/controllers/hyrax/file_sets_controller.rb +49 -13
- data/app/controllers/hyrax/permissions_controller.rb +3 -4
- data/app/controllers/hyrax/workflow_actions_controller.rb +3 -1
- data/app/forms/hyrax/forms/collection_form.rb +12 -6
- data/app/forms/hyrax/forms/dashboard/nest_collection_form.rb +24 -2
- data/app/forms/hyrax/forms/file_set_form.rb +46 -0
- data/app/forms/hyrax/forms/permission.rb +23 -0
- data/app/forms/hyrax/forms/permission_template_form.rb +8 -2
- data/app/forms/hyrax/forms/resource_form.rb +31 -13
- data/app/forms/hyrax/forms/work_form.rb +5 -2
- data/app/helpers/hyrax/batch_edits_helper.rb +3 -1
- data/app/helpers/hyrax/collections_helper.rb +88 -2
- data/app/helpers/hyrax/dashboard_helper_behavior.rb +16 -5
- data/app/helpers/hyrax/embargo_helper.rb +4 -0
- data/app/helpers/hyrax/file_set_helper.rb +25 -6
- data/app/helpers/hyrax/hyrax_helper_behavior.rb +8 -0
- data/app/helpers/hyrax/lease_helper.rb +4 -0
- data/app/helpers/hyrax/url_helper.rb +4 -1
- data/app/helpers/hyrax/work_form_helper.rb +53 -0
- data/app/indexers/hyrax/administrative_set_indexer.rb +18 -0
- data/app/indexers/hyrax/valkyrie_file_set_indexer.rb +118 -0
- data/app/indexers/hyrax/valkyrie_indexer.rb +10 -4
- data/app/indexers/hyrax/valkyrie_work_indexer.rb +3 -1
- data/app/inputs/controlled_vocabulary_input.rb +2 -5
- data/app/jobs/attach_files_to_work_job.rb +19 -10
- data/app/jobs/attach_files_to_work_with_ordered_members_job.rb +6 -5
- data/app/jobs/embargo_expiry_job.rb +7 -5
- data/app/jobs/file_set_attached_event_job.rb +6 -1
- data/app/jobs/ingest_local_file_job.rb +18 -2
- data/app/jobs/inherit_permissions_job.rb +9 -5
- data/app/jobs/lease_expiry_job.rb +6 -4
- data/app/models/admin_set.rb +6 -25
- data/app/models/collection_branding_info.rb +25 -9
- data/app/models/concerns/hyrax/ability.rb +14 -1
- data/app/models/concerns/hyrax/collection_behavior.rb +17 -44
- data/app/models/concerns/hyrax/embargoable.rb +24 -0
- data/app/models/concerns/hyrax/file_set/characterization.rb +18 -12
- data/app/models/concerns/hyrax/solr_document_behavior.rb +9 -46
- data/app/models/concerns/hyrax/suppressible.rb +5 -0
- data/app/models/concerns/hyrax/user.rb +9 -3
- data/app/models/concerns/hyrax/work_behavior.rb +1 -1
- data/app/models/hyrax/file_set.rb +7 -0
- data/app/models/hyrax/pcdm_collection.rb +1 -0
- data/app/models/hyrax/permission_template.rb +98 -12
- data/app/models/hyrax/virus_scanner.rb +27 -18
- data/app/models/hyrax/work.rb +2 -0
- data/app/models/job_io_wrapper.rb +1 -1
- data/app/models/sipity/agent.rb +1 -0
- data/app/models/sipity/entity.rb +30 -8
- data/app/models/sipity/workflow.rb +1 -0
- data/app/models/sipity.rb +42 -0
- data/app/presenters/hyrax/admin_set_options_presenter.rb +12 -8
- data/app/presenters/hyrax/admin_set_presenter.rb +5 -1
- data/app/presenters/hyrax/admin_set_selection_presenter.rb +116 -0
- data/app/presenters/hyrax/collection_presenter.rb +41 -20
- data/app/presenters/hyrax/file_set_presenter.rb +6 -1
- data/app/presenters/hyrax/file_usage.rb +3 -2
- data/app/presenters/hyrax/pcdm_member_presenter_factory.rb +119 -0
- data/app/presenters/hyrax/stats_usage_presenter.rb +2 -1
- data/app/presenters/hyrax/trophy_presenter.rb +33 -4
- data/app/presenters/hyrax/user_profile_presenter.rb +11 -1
- data/app/presenters/hyrax/version_list_presenter.rb +19 -0
- data/app/presenters/hyrax/version_presenter.rb +3 -2
- data/app/presenters/hyrax/work_show_presenter.rb +30 -5
- data/app/presenters/hyrax/work_usage.rb +5 -3
- data/app/renderers/hyrax/renderers/attribute_renderer.rb +10 -2
- data/app/search_builders/hyrax/admin_set_search_builder.rb +1 -1
- data/app/search_builders/hyrax/collection_member_search_builder.rb +6 -1
- data/app/search_builders/hyrax/my/collections_search_builder.rb +2 -2
- data/app/search_builders/hyrax/nested_collections_parent_search_builder.rb +1 -1
- data/app/search_builders/hyrax/single_collection_search_builder.rb +1 -1
- data/app/services/hyrax/access_control_list.rb +1 -1
- data/app/services/hyrax/adapters/nesting_index_adapter.rb +1 -1
- data/app/services/hyrax/admin_set_create_service.rb +3 -1
- data/app/services/hyrax/collections/collection_member_search_service.rb +72 -0
- data/app/services/hyrax/collections/collection_member_service.rb +112 -27
- data/app/services/hyrax/collections/migration_service.rb +4 -2
- data/app/services/hyrax/collections/nested_collection_persistence_service.rb +12 -13
- data/app/services/hyrax/collections/nested_collection_query_service.rb +2 -0
- data/app/services/hyrax/collections/permissions_create_service.rb +6 -4
- data/app/services/hyrax/contextual_path.rb +24 -1
- data/app/services/hyrax/custom_queries/find_file_metadata.rb +7 -5
- data/app/services/hyrax/custom_queries/navigators/parent_collections_navigator.rb +46 -0
- data/app/services/hyrax/edit_permissions_service.rb +74 -41
- data/app/services/hyrax/embargo_manager.rb +1 -1
- data/app/services/hyrax/find_objects_via_solr_service.rb +31 -0
- data/app/services/hyrax/graph_exporter.rb +1 -1
- data/app/services/hyrax/listeners/member_cleanup_listener.rb +26 -0
- data/app/services/hyrax/listeners/metadata_index_listener.rb +18 -1
- data/app/services/hyrax/listeners/object_lifecycle_listener.rb +1 -1
- data/app/services/hyrax/listeners/trophy_cleanup_listener.rb +17 -0
- data/app/services/hyrax/listeners.rb +2 -0
- data/app/services/hyrax/multiple_membership_checker.rb +53 -29
- data/app/services/hyrax/persist_derivatives.rb +3 -1
- data/app/services/hyrax/resource_status.rb +7 -0
- data/app/services/hyrax/search_service.rb +4 -2
- data/app/services/hyrax/solr_query_builder_service.rb +45 -8
- data/app/services/hyrax/solr_query_service.rb +224 -0
- data/app/services/hyrax/solr_service.rb +8 -1
- data/app/services/hyrax/statistics/depositors/summary.rb +2 -1
- data/app/services/hyrax/thumbnail_path_service.rb +1 -1
- data/app/services/hyrax/versioning_service.rb +1 -1
- data/app/services/hyrax/visibility_intention.rb +20 -2
- data/app/services/hyrax/visibility_propagator.rb +30 -1
- data/app/services/hyrax/work_uploads_handler.rb +22 -4
- data/app/services/hyrax/workflow/actionable_objects.rb +70 -0
- data/app/services/hyrax/workflow/object_in_workflow_decorator.rb +31 -0
- data/app/services/hyrax/workflow/status_list_service.rb +43 -13
- data/app/views/hyrax/admin/admin_sets/_show_document_list_row.html.erb +1 -1
- data/app/views/hyrax/base/_form_child_work_relationships.html.erb +1 -1
- data/app/views/hyrax/base/_form_relationships.html.erb +1 -2
- data/app/views/hyrax/base/_form_rendering.html.erb +1 -1
- data/app/views/hyrax/base/_form_representative.html.erb +1 -1
- data/app/views/hyrax/base/_form_share.html.erb +1 -5
- data/app/views/hyrax/base/_form_thumbnail.html.erb +1 -1
- data/app/views/hyrax/base/_form_visibility_error.html.erb +2 -0
- data/app/views/hyrax/base/_guts4form.html.erb +3 -3
- data/app/views/hyrax/base/_representative_media.html.erb +1 -1
- data/app/views/hyrax/base/_show_actions.html.erb +2 -2
- data/app/views/hyrax/base/_work_button_row.html.erb +1 -1
- data/app/views/hyrax/base/_workflow_actions.html.erb +1 -1
- data/app/views/hyrax/batch_edits/edit.html.erb +2 -2
- data/app/views/hyrax/batch_uploads/_form.html.erb +1 -1
- data/app/views/hyrax/collections/_list_collections.html.erb +1 -1
- data/app/views/hyrax/collections/_search_form.html.erb +1 -1
- data/app/views/hyrax/collections/show.html.erb +1 -1
- data/app/views/hyrax/dashboard/collections/_form.html.erb +3 -3
- data/app/views/hyrax/dashboard/collections/_form_branding.html.erb +1 -1
- data/app/views/hyrax/dashboard/collections/_list_collections.html.erb +1 -1
- data/app/views/hyrax/dashboard/collections/edit.html.erb +4 -2
- data/app/views/hyrax/dashboard/collections/new.html.erb +4 -2
- data/app/views/hyrax/dashboard/collections/show.html.erb +1 -1
- data/app/views/hyrax/file_sets/_actions.html.erb +10 -0
- data/app/views/hyrax/file_sets/edit.html.erb +1 -1
- data/app/views/hyrax/file_sets/media_display/_audio.html.erb +1 -1
- data/app/views/hyrax/file_sets/media_display/_default.html.erb +1 -1
- data/app/views/hyrax/file_sets/media_display/_image.html.erb +1 -1
- data/app/views/hyrax/file_sets/media_display/_office_document.html.erb +1 -1
- data/app/views/hyrax/file_sets/media_display/_pdf.html.erb +1 -1
- data/app/views/hyrax/file_sets/media_display/_video.html.erb +1 -1
- data/app/views/hyrax/file_sets/show.html.erb +1 -1
- data/app/views/hyrax/my/_admin_set_action_menu.html.erb +0 -11
- data/app/views/hyrax/my/_collection_action_menu.html.erb +1 -2
- data/app/views/hyrax/my/collections/_list_collections.html.erb +1 -1
- data/app/views/hyrax/my/collections/_modal_add_subcollection.html.erb +3 -5
- data/app/views/hyrax/stats/file.html.erb +1 -1
- data/app/views/hyrax/stats/work.html.erb +1 -1
- data/app/views/hyrax/uploads/_js_templates.html.erb +4 -4
- data/app/views/hyrax/uploads/_js_templates_versioning.html.erb +4 -4
- data/app/views/hyrax/users/_contributions.html.erb +1 -1
- data/app/views/hyrax/users/_profile_tabs.html.erb +2 -2
- data/app/views/hyrax/users/_search_form.html.erb +1 -1
- data/app/views/hyrax/users/_user.html.erb +1 -1
- data/app/views/hyrax/users/_user_info.html.erb +9 -9
- data/bin/db-migrate-seed.sh +6 -2
- data/bin/hyrax-entrypoint.sh +0 -14
- data/bin/solrcloud-assign-configset.sh +35 -0
- data/bin/solrcloud-upload-configset.sh +42 -0
- data/chart/hyrax/Chart.yaml +12 -8
- data/chart/hyrax/README.md +94 -11
- data/chart/hyrax/templates/NOTES.txt +1 -1
- data/chart/hyrax/templates/_helpers.tpl +98 -0
- data/chart/hyrax/templates/branding-pvc.yaml +14 -0
- data/chart/hyrax/templates/configmap-env.yaml +21 -11
- data/chart/hyrax/templates/cron-embargo.yaml +24 -0
- data/chart/hyrax/templates/cron-lease.yaml +24 -0
- data/chart/hyrax/templates/deployment-worker.yaml +129 -0
- data/chart/hyrax/templates/deployment.yaml +125 -4
- data/chart/hyrax/templates/derivatives-pvc.yaml +14 -0
- data/chart/hyrax/templates/ingress.yaml +13 -4
- data/chart/hyrax/templates/secrets.yaml +12 -2
- data/chart/hyrax/templates/uploads-pvc.yaml +14 -0
- data/chart/hyrax/values.yaml +186 -2
- data/config/brakeman.ignore +2 -2
- data/config/features.rb +47 -43
- data/config/initializers/listeners.rb +4 -0
- data/config/initializers/valkryrie_storage.rb +7 -0
- data/config/locales/hyrax.de.yml +1 -1
- data/config/locales/hyrax.en.yml +1 -1
- data/config/locales/hyrax.es.yml +1 -1
- data/config/locales/hyrax.fr.yml +1 -1
- data/config/locales/hyrax.it.yml +1 -1
- data/config/locales/hyrax.pt-BR.yml +1 -1
- data/config/locales/hyrax.zh.yml +1 -1
- data/docker-compose.yml +39 -8
- data/documentation/developing-your-hyrax-based-app.md +4 -4
- data/documentation/legacyREADME.md +3 -3
- data/lib/generators/hyrax/templates/config/initializers/hyrax.rb +5 -0
- data/lib/generators/hyrax/templates/config/initializers/riiif.rb +22 -20
- data/lib/hyrax/active_fedora_dummy_model.rb +62 -0
- data/lib/hyrax/configuration.rb +28 -0
- data/lib/hyrax/engine.rb +3 -1
- data/lib/hyrax/errors.rb +2 -0
- data/lib/hyrax/resource_name.rb +1 -0
- data/lib/hyrax/specs/capybara.rb +5 -3
- data/lib/hyrax/specs/shared_specs/valkyrie_storage_versions.rb +9 -0
- data/lib/hyrax/transactions/container.rb +32 -1
- data/lib/hyrax/transactions/file_set_destroy.rb +21 -0
- data/lib/hyrax/transactions/steps/add_file_sets.rb +3 -2
- data/lib/hyrax/transactions/steps/add_to_parent.rb +36 -0
- data/lib/hyrax/transactions/steps/delete_resource.rb +38 -0
- data/lib/hyrax/transactions/steps/destroy_work.rb +1 -0
- data/lib/hyrax/transactions/steps/remove_file_set_from_work.rb +47 -0
- data/lib/hyrax/transactions/work_create.rb +2 -1
- data/lib/hyrax/transactions/work_destroy.rb +20 -0
- data/lib/hyrax/valkyrie_can_can_adapter.rb +3 -0
- data/lib/hyrax/valkyrie_simple_path_generator.rb +20 -0
- data/lib/hyrax/version.rb +1 -1
- data/lib/hyrax.rb +9 -0
- data/lib/tasks/collection_type_global_id.rake +1 -1
- data/lib/tasks/embargo_lease.rake +27 -0
- data/lib/tasks/regenerate_derivatives.rake +12 -0
- data/lib/wings/active_fedora_converter/default_work.rb +19 -0
- data/lib/wings/attribute_transformer.rb +29 -19
- data/lib/wings/converter_value_mapper.rb +2 -2
- data/lib/wings/model_transformer.rb +21 -20
- data/lib/wings/orm_converter.rb +42 -23
- data/lib/wings/setup.rb +2 -0
- data/lib/wings/valkyrie/persister.rb +8 -5
- data/lib/wings/valkyrie/query_service.rb +96 -41
- data/lib/wings/valkyrie/storage.rb +56 -1
- data/lib/wings.rb +0 -21
- data/template.rb +1 -1
- metadata +41 -21
- data/chart/fcrepo/.gitignore +0 -2
- data/chart/fcrepo/.helmignore +0 -23
- data/chart/fcrepo/Chart.yaml +0 -11
- data/chart/fcrepo/README.md +0 -50
- data/chart/fcrepo/templates/NOTES.txt +0 -21
- data/chart/fcrepo/templates/_helpers.tpl +0 -68
- data/chart/fcrepo/templates/configmap-env.yaml +0 -19
- data/chart/fcrepo/templates/deployment.yaml +0 -109
- data/chart/fcrepo/templates/ingress.yaml +0 -41
- data/chart/fcrepo/templates/pvc.yaml +0 -20
- data/chart/fcrepo/templates/secret.yaml +0 -12
- data/chart/fcrepo/templates/service.yaml +0 -15
- data/chart/fcrepo/templates/serviceaccount.yaml +0 -12
- data/chart/fcrepo/templates/tests/test-connection.yaml +0 -15
- data/chart/fcrepo/values.yaml +0 -79
- data/chart/hyrax/templates/fcrepo-secret.yaml +0 -13
@@ -0,0 +1,14 @@
|
|
1
|
+
{{- if and .Values.brandingVolume.enabled (not .Values.brandingVolume.existingClaim) }}
|
2
|
+
apiVersion: v1
|
3
|
+
kind: PersistentVolumeClaim
|
4
|
+
metadata:
|
5
|
+
name: {{ template "hyrax.fullname" . }}-branding
|
6
|
+
labels:
|
7
|
+
{{- include "hyrax.labels" . | nindent 4 }}
|
8
|
+
spec:
|
9
|
+
{{ include "hyrax.sharedPvcAccessModes" . | nindent 2 }}
|
10
|
+
resources:
|
11
|
+
requests:
|
12
|
+
storage: {{ .Values.brandingVolume.size }}
|
13
|
+
storageClassName: {{ .Values.brandingVolume.storageClass }}
|
14
|
+
{{- end }}
|
@@ -8,25 +8,35 @@ metadata:
|
|
8
8
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
9
9
|
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
10
10
|
data:
|
11
|
-
{{
|
12
|
-
DB_HOST: {{ template "hyrax.postgresql.fullname" . }}
|
11
|
+
DB_HOST: {{ template "hyrax.postgresql.host" . }}
|
13
12
|
DB_PORT: "5432"
|
14
|
-
{{
|
13
|
+
DB_USERNAME: {{ template "hyrax.postgresql.database" . }}
|
15
14
|
{{- if .Values.memcached.enabled }}
|
16
15
|
MEMCACHED_HOST: {{ template "hyrax.memcached.fullname" . }}
|
17
16
|
{{- end }}
|
17
|
+
{{- if .Values.derivativesVolume.enabled }}
|
18
|
+
HYRAX_BRANDING_PATH: "/app/samvera/branding"
|
19
|
+
HYRAX_DERIVATIVES_PATH: "/app/samvera/derivatives"
|
20
|
+
HYRAX_CACHE_PATH: "/app/samvera/file_cache"
|
21
|
+
HYRAX_UPLOAD_PATH: "/app/samvera/uploads"
|
22
|
+
{{- end }}
|
18
23
|
RACK_ENV: production
|
19
24
|
RAILS_ENV: production
|
20
25
|
{{- if .Values.redis.enabled }}
|
21
|
-
REDIS_HOST: {{ template "hyrax.redis.
|
26
|
+
REDIS_HOST: {{ template "hyrax.redis.host" . }}
|
22
27
|
{{- end }}
|
23
|
-
{{
|
28
|
+
FCREPO_HOST: {{ template "hyrax.fcrepo.host" . }}
|
29
|
+
FCREPO_BASE_PATH: {{ .Values.fcrepoBasePathOverride | default (printf "/%s" (include "hyrax.fullname" .)) | quote }}
|
24
30
|
FCREPO_PORT: {{ .Values.fcrepo.servicePort | default 8080 | quote }}
|
25
|
-
|
26
|
-
|
31
|
+
FCREPO_REST_PATH: {{ .Values.fcrepo.restPath | default "rest" }}
|
32
|
+
REDIS_PROVIDER: SIDEKIQ_REDIS_URL
|
33
|
+
{{- if .Values.minio.enabled }}
|
34
|
+
MINIO_ENDPOINT: {{ template "hyrax.minio.fullname" . }}
|
27
35
|
{{- end }}
|
28
|
-
{{
|
29
|
-
|
36
|
+
SKIP_HYRAX_ENGINE_SEED: {{ .Values.skipHyraxEngineSeed | default 0 | quote }}
|
37
|
+
SOLR_ADMIN_USER: {{ template "hyrax.solr.username" . }}
|
38
|
+
SOLR_COLLECTION_NAME: {{ template "hyrax.solr.collectionName" . }}
|
39
|
+
SOLR_CONFIGSET_NAME: {{ template "hyrax.fullname" . }}
|
40
|
+
SOLR_HOST: {{ template "hyrax.solr.host" . }}
|
30
41
|
SOLR_PORT: "8983"
|
31
|
-
SOLR_URL:
|
32
|
-
{{- end }}
|
42
|
+
SOLR_URL: {{ template "hyrax.solr.url" . }}
|
@@ -0,0 +1,24 @@
|
|
1
|
+
{{- if .Values.embargoRelease.enabled }}
|
2
|
+
apiVersion: batch/v1beta1
|
3
|
+
kind: CronJob
|
4
|
+
metadata:
|
5
|
+
metadata:
|
6
|
+
name: {{ include "hyrax.fullname" . }}-embargo-task
|
7
|
+
labels:
|
8
|
+
{{- include "hyrax.labels" . | nindent 4 }}
|
9
|
+
spec:
|
10
|
+
schedule: {{ .Values.embargoRelease.schedule | default "*0 0 * * *" | quote }}
|
11
|
+
jobTemplate:
|
12
|
+
spec:
|
13
|
+
template:
|
14
|
+
spec:
|
15
|
+
containers:
|
16
|
+
- name: embargo-release
|
17
|
+
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
|
18
|
+
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
19
|
+
command:
|
20
|
+
- /bin/sh
|
21
|
+
- -c
|
22
|
+
- bundle exec rake hyrax:embargo:deactivate_expired
|
23
|
+
restartPolicy: OnFailure
|
24
|
+
{{- end }}
|
@@ -0,0 +1,24 @@
|
|
1
|
+
{{- if .Values.leaseRelease.enabled }}
|
2
|
+
apiVersion: batch/v1beta1
|
3
|
+
kind: CronJob
|
4
|
+
metadata:
|
5
|
+
metadata:
|
6
|
+
name: {{ include "hyrax.fullname" . }}-lease-task
|
7
|
+
labels:
|
8
|
+
{{- include "hyrax.labels" . | nindent 4 }}
|
9
|
+
spec:
|
10
|
+
schedule: {{ .Values.leaseRelease.schedule | default "0 0 * * *" | quote }}
|
11
|
+
jobTemplate:
|
12
|
+
spec:
|
13
|
+
template:
|
14
|
+
spec:
|
15
|
+
containers:
|
16
|
+
- name: lease-release
|
17
|
+
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
|
18
|
+
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
19
|
+
command:
|
20
|
+
- /bin/sh
|
21
|
+
- -c
|
22
|
+
- bundle exec rake hyrax:lease:deactivate_expired
|
23
|
+
restartPolicy: OnFailure
|
24
|
+
{{- end }}
|
@@ -0,0 +1,129 @@
|
|
1
|
+
{{- if .Values.worker.enabled }}
|
2
|
+
apiVersion: apps/v1
|
3
|
+
kind: Deployment
|
4
|
+
metadata:
|
5
|
+
name: {{ include "hyrax.fullname" . }}-worker
|
6
|
+
labels:
|
7
|
+
{{- include "hyrax.labels" . | nindent 4 }}
|
8
|
+
spec:
|
9
|
+
replicas: {{ .Values.worker.replicaCount }}
|
10
|
+
selector:
|
11
|
+
matchLabels:
|
12
|
+
{{- include "hyrax.selectorLabels" . | nindent 6 }}
|
13
|
+
template:
|
14
|
+
metadata:
|
15
|
+
{{- with .Values.podAnnotations }}
|
16
|
+
annotations:
|
17
|
+
{{- toYaml . | nindent 8 }}
|
18
|
+
{{- end }}
|
19
|
+
labels:
|
20
|
+
{{- include "hyrax.selectorLabels" . | nindent 8 }}
|
21
|
+
spec:
|
22
|
+
initContainers:
|
23
|
+
- name: db-wait
|
24
|
+
image: "{{ .Values.worker.image.repository }}:{{ .Values.worker.image.tag | default .Chart.AppVersion }}"
|
25
|
+
imagePullPolicy: {{ .Values.worker.image.pullPolicy }}
|
26
|
+
envFrom:
|
27
|
+
- configMapRef:
|
28
|
+
name: {{ include "hyrax.fullname" . }}-env
|
29
|
+
- secretRef:
|
30
|
+
name: {{ template "hyrax.fullname" . }}
|
31
|
+
env:
|
32
|
+
{{- toYaml .Values.worker.extraEnvVars | nindent 12 }}
|
33
|
+
command:
|
34
|
+
- sh
|
35
|
+
- -c
|
36
|
+
- db-wait.sh "$REDIS_HOST:6379"
|
37
|
+
{{- if .Values.worker.extraInitContainers }}
|
38
|
+
{{- toYaml .Values.worker.extraInitContainers | nindent 8 }}
|
39
|
+
{{- end }}
|
40
|
+
{{- with .Values.imagePullSecrets }}
|
41
|
+
imagePullSecrets:
|
42
|
+
{{- toYaml . | nindent 8 }}
|
43
|
+
{{- end }}
|
44
|
+
serviceAccountName: {{ include "hyrax.serviceAccountName" . }}
|
45
|
+
securityContext:
|
46
|
+
{{- toYaml .Values.worker.podSecurityContext | nindent 8 }}
|
47
|
+
containers:
|
48
|
+
- name: {{ .Chart.Name }}-worker
|
49
|
+
securityContext:
|
50
|
+
{{- toYaml .Values.worker.securityContext | nindent 12 }}
|
51
|
+
image: "{{ .Values.worker.image.repository }}:{{ .Values.worker.image.tag | default .Chart.AppVersion }}"
|
52
|
+
imagePullPolicy: {{ .Values.worker.image.pullPolicy }}
|
53
|
+
envFrom:
|
54
|
+
- configMapRef:
|
55
|
+
name: {{ include "hyrax.fullname" . }}-env
|
56
|
+
- secretRef:
|
57
|
+
name: {{ template "hyrax.fullname" . }}
|
58
|
+
{{- if .Values.solrExistingSecret }}
|
59
|
+
- secretRef:
|
60
|
+
name: {{ .Values.solrExistingSecret }}
|
61
|
+
{{- end }}
|
62
|
+
{{- with .Values.worker.extraEnvFrom }}
|
63
|
+
{{- toYaml . | nindent 12 }}
|
64
|
+
{{- end }}
|
65
|
+
env:
|
66
|
+
{{- toYaml .Values.worker.extraEnvVars | nindent 12 }}
|
67
|
+
volumeMounts:
|
68
|
+
- name: derivatives
|
69
|
+
mountPath: /app/samvera/derivatives
|
70
|
+
- name: uploads
|
71
|
+
subPath: file_cache
|
72
|
+
mountPath: /app/samvera/file_cache
|
73
|
+
- name: uploads
|
74
|
+
subPath: uploads
|
75
|
+
mountPath: /app/samvera/uploads
|
76
|
+
{{- if .Values.applicationExistingClaim }}
|
77
|
+
- name: application
|
78
|
+
mountPath: /app/samvera/hyrax-webapp
|
79
|
+
{{- end }}
|
80
|
+
{{- with .Values.worker.extraVolumeMounts }}
|
81
|
+
{{- toYaml . | nindent 12 }}
|
82
|
+
{{- end }}
|
83
|
+
resources:
|
84
|
+
{{- toYaml .Values.worker.resources | nindent 12 }}
|
85
|
+
{{- with .Values.extraContainerConfiguration }}
|
86
|
+
{{- toYaml . | nindent 10 }}
|
87
|
+
{{- end }}
|
88
|
+
volumes:
|
89
|
+
- name: "derivatives"
|
90
|
+
{{- if and .Values.derivativesVolume.enabled .Values.derivativesVolume.existingClaim }}
|
91
|
+
persistentVolumeClaim:
|
92
|
+
claimName: {{ .Values.derivativesVolume.existingClaim }}
|
93
|
+
{{- else if .Values.derivativesVolume.enabled }}
|
94
|
+
persistentVolumeClaim:
|
95
|
+
claimName: {{ template "hyrax.fullname" . }}-derivatives
|
96
|
+
{{ else }}
|
97
|
+
emptyDir: {}
|
98
|
+
{{ end }}
|
99
|
+
- name: "uploads"
|
100
|
+
{{- if and .Values.uploadsVolume.enabled .Values.uploadsVolume.existingClaim }}
|
101
|
+
persistentVolumeClaim:
|
102
|
+
claimName: {{ .Values.uploadsVolume.existingClaim }}
|
103
|
+
{{- else if .Values.uploadsVolume.enabled }}
|
104
|
+
persistentVolumeClaim:
|
105
|
+
claimName: {{ template "hyrax.fullname" . }}-uploads
|
106
|
+
{{ else }}
|
107
|
+
emptyDir: {}
|
108
|
+
{{ end }}
|
109
|
+
{{- if .Values.applicationExistingClaim }}
|
110
|
+
- name: "application"
|
111
|
+
persistentVolumeClaim:
|
112
|
+
claimName: {{ .Values.applicationExistingClaim }}
|
113
|
+
{{- end }}
|
114
|
+
{{- with .Values.worker.extraVolumes }}
|
115
|
+
{{- toYaml . | nindent 8 }}
|
116
|
+
{{- end }}
|
117
|
+
{{- with .Values.worker.nodeSelector }}
|
118
|
+
nodeSelector:
|
119
|
+
{{- toYaml . | nindent 8 }}
|
120
|
+
{{- end }}
|
121
|
+
{{- with .Values.worker.affinity }}
|
122
|
+
affinity:
|
123
|
+
{{- toYaml . | nindent 8 }}
|
124
|
+
{{- end }}
|
125
|
+
{{- with .Values.worker.tolerations }}
|
126
|
+
tolerations:
|
127
|
+
{{- toYaml . | nindent 8 }}
|
128
|
+
{{- end }}
|
129
|
+
{{- end }}
|
@@ -21,6 +21,29 @@ spec:
|
|
21
21
|
{{- include "hyrax.selectorLabels" . | nindent 8 }}
|
22
22
|
spec:
|
23
23
|
initContainers:
|
24
|
+
{{- if .Values.loadSolrConfigSet }}
|
25
|
+
- name: load-solr-config
|
26
|
+
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
|
27
|
+
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
28
|
+
envFrom:
|
29
|
+
- configMapRef:
|
30
|
+
name: {{ include "hyrax.fullname" . }}-env
|
31
|
+
- secretRef:
|
32
|
+
name: {{ include "hyrax.fullname" . }}
|
33
|
+
{{- if .Values.solrExistingSecret }}
|
34
|
+
- secretRef:
|
35
|
+
name: {{ .Values.solrExistingSecret }}
|
36
|
+
{{- end }}
|
37
|
+
env:
|
38
|
+
{{- toYaml .Values.extraEnvVars | nindent 12 }}
|
39
|
+
command:
|
40
|
+
- sh
|
41
|
+
- -c
|
42
|
+
- >
|
43
|
+
solrcloud-upload-configset.sh /app/samvera/hyrax-webapp/solr/conf &&
|
44
|
+
solrcloud-assign-configset.sh
|
45
|
+
{{- end }}
|
46
|
+
{{- if not .Values.skipDbMigrateSeed }}
|
24
47
|
- name: db-setup
|
25
48
|
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
|
26
49
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
@@ -29,10 +52,23 @@ spec:
|
|
29
52
|
name: {{ include "hyrax.fullname" . }}-env
|
30
53
|
- secretRef:
|
31
54
|
name: {{ template "hyrax.fullname" . }}
|
55
|
+
{{- if .Values.solrExistingSecret }}
|
56
|
+
- secretRef:
|
57
|
+
name: {{ .Values.solrExistingSecret }}
|
58
|
+
{{- end }}
|
59
|
+
{{- with .Values.extraEnvFrom }}
|
60
|
+
{{- toYaml . | nindent 12 }}
|
61
|
+
{{- end }}
|
62
|
+
env:
|
63
|
+
{{- toYaml .Values.extraEnvVars | nindent 12 }}
|
32
64
|
command:
|
33
65
|
- sh
|
34
66
|
- -c
|
35
67
|
- db-migrate-seed.sh
|
68
|
+
{{- end }}
|
69
|
+
{{- if .Values.extraInitContainers }}
|
70
|
+
{{- toYaml .Values.extraInitContainers | nindent 8 }}
|
71
|
+
{{- end }}
|
36
72
|
{{- with .Values.imagePullSecrets }}
|
37
73
|
imagePullSecrets:
|
38
74
|
{{- toYaml . | nindent 8 }}
|
@@ -51,20 +87,105 @@ spec:
|
|
51
87
|
name: {{ include "hyrax.fullname" . }}-env
|
52
88
|
- secretRef:
|
53
89
|
name: {{ template "hyrax.fullname" . }}
|
90
|
+
{{- if .Values.solrExistingSecret }}
|
91
|
+
- secretRef:
|
92
|
+
name: {{ .Values.solrExistingSecret }}
|
93
|
+
{{- end }}
|
94
|
+
{{- with .Values.extraEnvFrom }}
|
95
|
+
{{- toYaml . | nindent 12 }}
|
96
|
+
{{- end }}
|
97
|
+
env:
|
98
|
+
{{- toYaml .Values.extraEnvVars | nindent 12 }}
|
54
99
|
ports:
|
55
100
|
- name: http
|
56
101
|
containerPort: 3000
|
57
102
|
protocol: TCP
|
103
|
+
{{- if .Values.livenessProbe.enabled }}
|
58
104
|
livenessProbe:
|
105
|
+
initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds | default 5 }}
|
106
|
+
timeoutSeconds: {{ .Values.livenessProbe.timeoutSeconds | default 5 }}
|
107
|
+
failureThreshold: {{ .Values.livenessProbe.failureThreshold | default 3 }}
|
108
|
+
periodSeconds: {{ .Values.livenessProbe.periodSeconds | default 10}}
|
109
|
+
successThreshold: {{ .Values.livenessProbe.successThreshold | default 1 }}
|
59
110
|
httpGet:
|
60
|
-
|
61
|
-
|
111
|
+
scheme: "HTTP"
|
112
|
+
path: {{ .Values.livenessProbe.path | default "/" }}
|
113
|
+
port: 3000
|
114
|
+
{{- end }}
|
115
|
+
{{- if .Values.readinessProbe.enabled }}
|
62
116
|
readinessProbe:
|
117
|
+
initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds | default 5 }}
|
118
|
+
timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds | default 5 }}
|
119
|
+
failureThreshold: {{ .Values.readinessProbe.failureThreshold | default 3 }}
|
120
|
+
periodSeconds: {{ .Values.readinessProbe.periodSeconds | default 10 }}
|
121
|
+
successThreshold: {{ .Values.readinessProbe.successThreshold | default 1 }}
|
63
122
|
httpGet:
|
64
|
-
|
65
|
-
|
123
|
+
scheme: "HTTP"
|
124
|
+
path: {{ .Values.readinessProbe.path | default "/" }}
|
125
|
+
port: 3000
|
126
|
+
{{- end }}
|
127
|
+
volumeMounts:
|
128
|
+
- name: branding
|
129
|
+
mountPath: /app/samvera/branding
|
130
|
+
- name: derivatives
|
131
|
+
mountPath: /app/samvera/derivatives
|
132
|
+
- name: uploads
|
133
|
+
subPath: file_cache
|
134
|
+
mountPath: /app/samvera/file_cache
|
135
|
+
- name: uploads
|
136
|
+
subPath: uploads
|
137
|
+
mountPath: /app/samvera/uploads
|
138
|
+
{{- if .Values.applicationExistingClaim }}
|
139
|
+
- name: application
|
140
|
+
mountPath: /app/samvera/hyrax-webapp
|
141
|
+
{{- end }}
|
142
|
+
{{- with .Values.extraVolumeMounts }}
|
143
|
+
{{- toYaml . | nindent 12 }}
|
144
|
+
{{- end }}
|
66
145
|
resources:
|
67
146
|
{{- toYaml .Values.resources | nindent 12 }}
|
147
|
+
{{- with .Values.extraContainerConfiguration }}
|
148
|
+
{{- toYaml . | nindent 10 }}
|
149
|
+
{{- end }}
|
150
|
+
volumes:
|
151
|
+
- name: "branding"
|
152
|
+
{{- if and .Values.brandingVolume.enabled .Values.brandingVolume.existingClaim }}
|
153
|
+
persistentVolumeClaim:
|
154
|
+
claimName: {{ .Values.brandingVolume.existingClaim }}
|
155
|
+
{{- else if .Values.brandingVolume.enabled }}
|
156
|
+
persistentVolumeClaim:
|
157
|
+
claimName: {{ template "hyrax.fullname" . }}-branding
|
158
|
+
{{ else }}
|
159
|
+
emptyDir: {}
|
160
|
+
{{ end }}
|
161
|
+
- name: "derivatives"
|
162
|
+
{{- if and .Values.derivativesVolume.enabled .Values.derivativesVolume.existingClaim }}
|
163
|
+
persistentVolumeClaim:
|
164
|
+
claimName: {{ .Values.derivativesVolume.existingClaim }}
|
165
|
+
{{- else if .Values.derivativesVolume.enabled }}
|
166
|
+
persistentVolumeClaim:
|
167
|
+
claimName: {{ template "hyrax.fullname" . }}-derivatives
|
168
|
+
{{ else }}
|
169
|
+
emptyDir: {}
|
170
|
+
{{ end }}
|
171
|
+
- name: "uploads"
|
172
|
+
{{- if and .Values.uploadsVolume.enabled .Values.uploadsVolume.existingClaim }}
|
173
|
+
persistentVolumeClaim:
|
174
|
+
claimName: {{ .Values.uploadsVolume.existingClaim }}
|
175
|
+
{{- else if .Values.uploadsVolume.enabled }}
|
176
|
+
persistentVolumeClaim:
|
177
|
+
claimName: {{ template "hyrax.fullname" . }}-uploads
|
178
|
+
{{ else }}
|
179
|
+
emptyDir: {}
|
180
|
+
{{ end }}
|
181
|
+
{{- if .Values.applicationExistingClaim }}
|
182
|
+
- name: "application"
|
183
|
+
persistentVolumeClaim:
|
184
|
+
claimName: {{ .Values.applicationExistingClaim }}
|
185
|
+
{{- end }}
|
186
|
+
{{- with .Values.extraVolumes }}
|
187
|
+
{{- toYaml . | nindent 8 }}
|
188
|
+
{{- end }}
|
68
189
|
{{- with .Values.nodeSelector }}
|
69
190
|
nodeSelector:
|
70
191
|
{{- toYaml . | nindent 8 }}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
{{- if and .Values.derivativesVolume.enabled (not .Values.derivativesVolume.existingClaim) }}
|
2
|
+
apiVersion: v1
|
3
|
+
kind: PersistentVolumeClaim
|
4
|
+
metadata:
|
5
|
+
name: {{ template "hyrax.fullname" . }}-derivatives
|
6
|
+
labels:
|
7
|
+
{{- include "hyrax.labels" . | nindent 4 }}
|
8
|
+
spec:
|
9
|
+
{{ include "hyrax.sharedPvcAccessModes" . | nindent 2 }}
|
10
|
+
resources:
|
11
|
+
requests:
|
12
|
+
storage: {{ .Values.derivativesVolume.size }}
|
13
|
+
storageClassName: {{ .Values.derivativesVolume.storageClass }}
|
14
|
+
{{- end }}
|
@@ -1,10 +1,11 @@
|
|
1
1
|
{{- if .Values.ingress.enabled -}}
|
2
2
|
{{- $fullName := include "hyrax.fullname" . -}}
|
3
3
|
{{- $svcPort := .Values.service.port -}}
|
4
|
-
{{-
|
4
|
+
{{- $beta := semverCompare "<1.19-0" (default .Capabilities.KubeVersion.Version .Values.kubeVersion) -}}
|
5
|
+
{{- if $beta }}
|
5
6
|
apiVersion: networking.k8s.io/v1beta1
|
6
|
-
{{- else
|
7
|
-
apiVersion:
|
7
|
+
{{- else }}
|
8
|
+
apiVersion: networking.k8s.io/v1
|
8
9
|
{{- end }}
|
9
10
|
kind: Ingress
|
10
11
|
metadata:
|
@@ -32,10 +33,18 @@ spec:
|
|
32
33
|
http:
|
33
34
|
paths:
|
34
35
|
{{- range .paths }}
|
35
|
-
- path: {{ .
|
36
|
+
- path: {{ .path }}
|
37
|
+
pathType: {{ .pathType | default "ImplementationSpecific" }}
|
36
38
|
backend:
|
39
|
+
{{- if $beta }}
|
37
40
|
serviceName: {{ $fullName }}
|
38
41
|
servicePort: {{ $svcPort }}
|
42
|
+
{{- else }}
|
43
|
+
service:
|
44
|
+
name: {{ $fullName }}
|
45
|
+
port:
|
46
|
+
number: {{ $svcPort }}
|
47
|
+
{{- end }}
|
39
48
|
{{- end }}
|
40
49
|
{{- end }}
|
41
50
|
{{- end }}
|