Installation
[!TIP] This explains all options in detail. To just get started with a working setup, use the compose file.
We offer three way to run ShopiTerm.
The easiest to get started is using our provided containers via compose.
When using NixOS, there is the option to use preconfigured NixOS modules.
[!NOTE] For the instructions in this documentation we are using Podman as the container tool, but you can use the same commands for Docker.
Containers
Each of our services is containerized and available at Quay.io. The following images are available:
| Service | Image |
|---|---|
| catalogue | quay.io/asefs26-shopiterm/catalogue |
| notificator | quay.io/asefs26-shopiterm/notificator |
| orders | quay.io/asefs26-shopiterm/orders |
| payment | quay.io/asefs26-shopiterm/payment |
| recommendations | quay.io/asefs26-shopiterm/recommendations |
| ssh | quay.io/asefs26-shopiterm/ssh |
| warehouse | quay.io/asefs26-shopiterm/warehouse |
| krakend (Gateway) | quay.io/asefs26-shopiterm/krakend |
Tags are available per branch and cpu architecture.
Currently, we only provide images for the amd64 architecture.
As an example, to run the latest catalogue image built of the main branch for amd64 you can use:
podman run quay.io/asefs26-shopiterm/catalogue:main-amd64 --help
This will print all available options of the catalogue service.
[!CAUTION] To function properly, most services require external dependencies and also depend on each other. We therefore provide a compose file for a simple setup.
Compose
We provide a docker-compose.yaml file for container composition using Podman / Docker Compose.
It starts each service and the required dependencies, including a PostgreSQL database for each service that uses it.
To start it, simply run the following in the root of the repository:
podman compose up
[!NOTE] The preconfigured port for SSH access is
2222.
NixOS Modules
We provide NixOS modules to configure ShopiTerm on a NixOS system.
Each service comes with its own module.
For usage with flakes, first import the project:
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.11";
shopiterm = {
url = "github:asefs26/team-6";
inputs.nixpkgs.follows = "nixpkgs";
};
};
}
Then import the modules to configure to your NixOS configuration.
The name of each service module is the same as the service itself.
For example, the module for the catalogue service is shopiterm.nixosModules.catalogue.
You can check the modules for configuration details. As an example, the catalogue service can be configured as follows:
{
services.shopiTerm.catalogue =
let
cataloguePort = 3001;
warehousePort = 3002;
in
{
enable = true;
host = "[::]";
port = cataloguePort;
# Create a local PostgreSQL DB automatically.
createDB = true;
warehouse = "http://localhost:${toString warehousePort}";
};
}
From Source
Lastly, there is the option to build the project directly from source. To do so, there are two options:
Nix
[!TIP] Installation instructions for Nix can be found on its website.
This project is developed using Nix. The project can be built by running the following:
nix build -L
The resulting binaries will be placed at result/bin.
Cargo
[!TIP] A Rust toolchain can be installed using rustup.
Alternatively, the Rust package manager Cargo can be used. Run the following for a build of all services:
cargo build --release