The project is in its very early stages, there is nothing to see here yet.
Tobira consists of two parts:
frontend
contains the web interface written in TypeScript/React.backend
contains the video portal backend written in Rust which takes care of data persistence and communication to Opencast.
Make sure you have the following tools installed:
- backend:
rustc
andcargo
- frontend:
node
andnpm
- (optional) build helper:
floof
Tobira needs a PostgreSQL database.
The scripts
directory contains a container compose file to easily spin one up.
cd scripts/
# using docker
docker-compose up -d
# using podman
podman-compose up -d
Find more information in the docker compose docs.
Export the current API's GraphQL schema to be used by the frontend. You need to do this whenever the API changes.
cd backend/
cargo run --bin export-schema -- ../frontend/src/schema.graphql
Use npm to build the TypeScript/React based frontend.
cd frontend/
npm ci
npx relay-compiler
npm run build:dev
Use cargo to build and run the Rust based backend.
cd backend/
# build only
cargo build
# build and start backend server
cargo run -- serve
Make sure to manually build once before trying this!
You can use floof
to make builds easier.
This will watch all files, recompile/build changes and provide a development server that automatically reloads Tobira.
# run floof
floof
# run with configuration file
floof -c floofy.yaml
To locally modify the workflow:
- Copy the configuration:
cp floof.yaml floofy.yaml
- Tell git to ignore your copy:
echo /floofy.yaml >> .git/info/exclude