Skip to content
This repository has been archived by the owner on Jan 20, 2024. It is now read-only.

FHICT-S-Koen/Spaced

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Spaced

Prerequisites

In order to run Spaced in development the following must be installed.

Getting started

Install dependencies for web-frontend.

npm i

The project requires at least a PostgreSQL database to be run and uses RabbitMQ as message broker. Both can be started using docker compose.

docker compose up -d

Set the development database url and JWT secret.

echo DATABASE_URL=postgres://admin:password@localhost:5432/spaced > .env
echo JWT_SECRET=test >> .env

The services can be started with the following script.

npm run services

Another option is to use cargo watch.

Note: You may need to run cargo install cargo-watch.

The web-frontend can be started with the following script.

npm run dev

The web-frontend can also be displayed from a desktop application with the following command.

npm run tauri dev

Building

The web-frontend can be built using the following script.

npm run build

The docker images for each service can be built using the following command.

docker buildx bake

Use the following environment variable to change the image tag.

IMAGE_TAG=1.0 docker buildx bake # result = spaced/<service_name>:1.0

Use the following environment variable to change the distroless image tag. The default is nonroot to debug with a shell use debug or debug-nonroot.

DISTROLESS_TAG=debug docker buildx bake

The docker-compose.yaml file is used as build definition. docker buildx bake ignores profiles and builds the services anway.

Contributing

Please read the contributing guidelines.