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.
Before we begin, make sure that you have the following prerequisites:
If you are missing any of these prerequisites, please install them before continuing.
Update your system packages:
$ sudo pkg_add -Uu
Install nodejs:
$ sudo pkg_add -i node
Install the yarn package manager:
$ sudo pkg_add -i yarn
Create a new directory for your Hyrax instance:
$ mkdir my_hyrax_instance
$ cd my_hyrax_instance
Clone the Hyrax repository:
$ git clone https://github.com/samvera/hyrax.git .
Install the required gems using Bundler:
$ bundle install --without development test
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
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)
Run the database migration:
$ bin/rake db:migrate RAILS_ENV=production
Seed the database:
$ bin/rake hyrax:default_admin_set:create hyrax:default_collection_types:create hyrax:workflow:load
Start the web server:
$ bin/rails server -e production
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!