Skip to content

Generating techmd from preservation storage

Justin Littman edited this page Sep 15, 2022 · 2 revisions

The technical metadata service supports generating technical metadata from files on preservation storage. This is useful for retroactive technical metadata generation (i.e., generating technical metadata outside the accessioning workflow).

For retroactive technical metadata generation see the techmd:generate_for_moab and techmd:generate_for_moab_list rake tasks.

For significant technical metadata generation, it is recommended to utilize a separate worker server because:

  • It allows separating the retro generation from the current generation. This minimizes the impact on other production technical metadata generation.
  • It can be run as the pres user, which avoids some permissions problems encountered with preservation storage.

Following are some example configuration files for a separate worker server:

config/deploy/retro.rb

# frozen_string_literal: true

# Note that running this as pres user due to read file permissions issues as techmd user.
server 'dor-techmd-worker-prod-b.stanford.edu', user: 'pres', roles: %w[app worker]

Capistrano::OneTimeKey.generate_one_time_key!
set :rails_env, 'production'
set :deploy_to, '/opt/app/pres/dor_techmd'

config/retro_sidekiq.yml

:concurrency: 1
:queues:
  - retro

For puppet configuration, see https://github.com/sul-dlss/puppet/blob/9ed5921ad8e9a39147c1789c038b11cfdb885ee9/hieradata/node/dor-techmd-worker-prod-b.stanford.edu.eyaml

Clone this wiki locally