In order to run Spaced in development the following must be installed.
If you're using Nix, you can run nix-shell
, or configure direnv
to install
the required Tauri dependencies.
Install dependencies for web-frontend.
npm ci
Build JavaScript libraries used in web-frontend. Only required initially or when changes are made to packages referenced in srcs/app/tsconfig.json.
npx --workspaces tsc -b
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
Prepare the databases with migrations.
npm run sqlx:prepare
The services can be started with the following script.
npm run services
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
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 anyway.
Please read the contributing guidelines.