Installing Samvera Hyrax on OpenBSD

In this tutorial, we will guide you step-by-step through the process of installing Samvera Hyrax on OpenBSD. Samvera Hyrax is an open-source digital repository that is built on top of several other technologies, including Fedora, Solr, and Blacklight.

Prerequisites

Before we begin, make sure that you have the following prerequisites:

If you are missing any of these prerequisites, please install them before continuing.

Installation

  1. Update your system packages:

    $ sudo pkg_add -Uu
    
  2. Install nodejs:

    $ sudo pkg_add -i node
    
  3. Install the yarn package manager:

    $ sudo pkg_add -i yarn
    
  4. Create a new directory for your Hyrax instance:

    $ mkdir my_hyrax_instance
    $ cd my_hyrax_instance
    
  5. Clone the Hyrax repository:

    $ git clone https://github.com/samvera/hyrax.git .
    
  6. Install the required gems using Bundler:

    $ bundle install --without development test
    
  7. Create a new PostgreSQL user and database:

    $ sudo su - postgres
    $ createdb hyrax_production
    $ psql
    # CREATE USER hyrax WITH PASSWORD 'password';
    # ALTER DATABASE hyrax_production OWNER TO hyrax;
    # \q
    $ exit
    
  8. Configure your environment variables:

    $ export HYRAX_HOST='localhost:3000'
    $ export HYRAX_BASE_PATH='/'
    $ export DATABASE_URL='postgres://hyrax:password@localhost/hyrax_production'
    $ export SECRET_KEY_BASE=$(bin/rake secret)
    
  9. Run the database migration:

    $ bin/rake db:migrate RAILS_ENV=production
    
  10. Seed the database:

    $ bin/rake hyrax:default_admin_set:create hyrax:default_collection_types:create hyrax:workflow:load
    
  11. Start the web server:

    $ bin/rails server -e production
    
  12. Visit your Hyrax instance in your web browser by navigating to http://localhost:3000.

Congratulations! You have successfully installed Samvera Hyrax on OpenBSD.

If you want to self-host in an easy, hands free way, need an external IP address, or simply want your data in your own hands, give IPv6.rs a try!

Alternatively, for the best virtual desktop, try Shells!