-
Notifications
You must be signed in to change notification settings - Fork 0
Initial Hyku Setup
This guide walks you through the steps to get a docker-based development environment running locally. We've condensed the instructions for Hyku and HykuKnapsack to get you going quickly with a base development environment we can use to explore Hyku and experiment with new features.
- Start the Hyku admin application
- Create the first Administrator account
- Create the first Tenant site
- Rails 3.x installed on your local system
- Docker Desktop v4.x
- Git command line tools (e.g.
git clone)
-
Get a local copy of the application.
git clone --recurse https://github.com/RepoCamp/pitt2025.git -
Change your working directory to the new project directory
cd pitt2025 -
Add the main HykuKnapsack repo as an alternate git remote
git remote add prime https://github.com/samvera-labs/hyku_knapsack -
Make sure we have a local copy of the magic branch for HykuKnapsack to run bundle install correctly
git branch required_for_knapsack_instances 5a7c54c -
Enable the [flexible metadata] feature
echo "HYRAX_FLEXIBLE=true" >> .env.development -
Install the StackCar gem to help manage your containers and create a private development network.
gem install stack_car -
Set up a local network and TLS certificate (so we can use HTTPS locally).
During this step, you'll be prompted for an unzip password - uselocalhost, then you'll be prompted for your local system password to add the certificate to your local keychain.sc proxy cert sc proxy up -
Start up Hyku
This will download docker images and create containers for all of your application components. The first time you runbuildandup, they can take up to 15 minutes on a 100Mbit connection. Please be patient, especially if you are on a slower connection. After the initial load, starting and stopping the application takes under a minute.sc build sc up -
Open the Hyku admin application in your browser.
*Watch for the messageweb-1 | * Listening on 0.0.0.0:3000. Once you see this message, you can access the admin app in your browser. -
Create a new super-admin user from the command line. From a new terminal session in the pitt2025 directory, run: Enter the e-mail and password for your new administrator when prompted.
sc exec rake hyku:superadmin:create -
Log-in to the admin app in your browser.
Use the e-mail and password you just supplied to loginClick on the "Administrator login" link at the bottom of the Hyku homepage.
-OR-
Visit https://admin-pitt2025.localhost.direct/users/sign_in. -
Create your first Hyku Tenant.
A tenant is an isolated repository that can be managed and searched independently from other tenants running on the same Hyku host.- Click on the "Accounts" link in the upper right navigation bar
- Click on the "Create new account" button
- Enter a name for your first repository; we've used "sandbox" for the following lessons
- Click on the "Save" button to create your repository site
- Click on the "Cancel" link to return to the Account overview
- Copy the Tenant UUID and CName values. We will need these in future lessons
-
Disable HTTP authentication for the repository.
- On the "Accounts" page for your new repository, click the "Edit" link
- On the "Editing Account" page, check the "Is Public" button. This just disables HTTP Basic authentication on the site; it does not make the site publicly available.
- Note the "Primary Domain Name" field: this should match the CName from the previous step.
- Scroll down, and click on the "Save Changes" at the bottom of the page
-
Log-in to the new repository.
- Visit the address from the previous step in your browser. e.g https://sandbox-pitt2025.localhost.direct
- Login using your super-admin credentials.
- You should now see the administrator dashboard for your repository.
Congratulations! You have successfully set up a local Hyku application using Docker and HykuKnapsack. In this lesson, we
- Cloned a local copy of the Hyku codebase
- Started the Hyku Tenant (aka Account) administration app
- Created a super-admin user that can create and manage tenants
- Created our first Hyku repository (aka Tenant)
- Logged into our tenant using the super-admin credentials