-
Notifications
You must be signed in to change notification settings - Fork 12
Installation
FasTnT EPCIS repository can be setup easily simply by following a few steps:
FasTnT EPCIS relies on .NET Core 3.1 and PostgreSQL 9.5 or newer. You'll need to create a new user/database for the EPCIS repository on your PostgreSQL server.
Setup FasTnT EPCIS repository is as easy as following these 4 steps:
- Clone the solution or download the latest release code, and open a terminal on the root folder;
- Update the connection string:
$dotnet user-secrets set ConnectionStrings:FasTnT.Database "{your connectionstring}" -p src\FasTnT.Host\FasTnT.Host.csproj
; - Start the repository with the command
$dotnet run -p src\FasTnT.Host\FasTnT.Host.csproj --urls "http://localhost:5102/"
; - Create the SQL schemas and tables:
$curl -X POST http://localhost:5102/EpcisServices/1.2/Database/Migrate
;
That's it! You have a properly working EPCIS 1.2 repository running locally.
To ensure the correct implementation of the EPCIS specification, the code base contains both unit and integration tests that you can run at any time.
To properly run integration tests, you need to setup a new database in PostgreSQL and configure the connection string in the user secrets: $dotnet user-secrets set ConnectionStrings:FasTnT.Database "{your test connectionstring}" -p test\FasTnT.IntegrationTests\FasTnT.IntegrationTests.csproj
;
If you don't setup this connection string, running the integration tests will end up with inconclusive result (not failed), and only unit tests will run.
Then you can run the tests using the command: $dotnet test FasTnT.sln