Skip to main content
Version: 3.2.0

Development Setup

This page explains how to set up the Storage Service project for local development and contribution.

Prerequisites

Ensure you have installed:

Clone and Install

git clone https://github.com/uncefact/project-storage-service.git
cd project-storage-service
yarn install

Copy the example environment file and configure it:

cp .env.example .env

Edit .env and set at minimum the API_KEY variable. See Configuration for the full list of environment variables.

Run in Development Mode

Start the service with hot reloading:

yarn dev

The service will be available at http://localhost:3333 and the Swagger UI at http://localhost:3333/api-docs.

Run Linter

Check code for linting errors:

yarn lint:check

Run Unit Tests

yarn test

Run E2E Tests

End-to-end tests require Docker to be installed and running:

yarn test:e2e

This command starts the required containers (including an S3-compatible storage backend), runs the E2E test suite, and tears down the containers afterwards.

Build for Production

yarn build
yarn start