Sellifi Developer Installation Guide
This guide provides detailed installation steps for each component in the Sellifi project.
Table of Contents
- sellifi-api-1 Installation
- 1.1 Prerequisites
- 1.2 Installation Steps
- sellifi-api-2 Installation
- 2.1 Prerequisites
- 2.2 Installation Steps
- sellifi-mobile-app Installation
- 3.1 Prerequisites
- 3.2 Installation Steps
- sellifi-mobile-app-food Installation
- 4.1 Prerequisites
- 4.2 Installation Steps
- sellifi-alertfuze Installation
- 5.1 Prerequisites
- 5.2 Installation Steps
- sellifi-hyperledger-fabric-net Installation
- 6.1 Prerequisites
- 6.2 Installation Steps
1. sellifi-api-1 Installation
sellifi-api-1
is a Go Fiber application serving as the server for the web client.
1.1 Prerequisites
- Go (version 1.19 or above)
- Redis (for caching)
- PostgreSQL (for persistent storage)
1.2 Installation Steps
-
Clone the Repository:
git clone https://github.com/Forest-Economy-Alliance/sellifi-central.git cd sellifi-api-1
-
Set Up Environment Variables:
- Copy
.env.example
to.env
and fill in the required values:PORT=8080 DATABASE_URL=your_postgresql_database_url REDIS_URL=your_redis_url
- Copy
-
Install Dependencies:
go mod tidy
-
Run Database Migrations (if applicable):
go run migrate.go
-
Start the Application:
go run main.go
-
Verify API is Running:
- Go to
http://localhost:8080
to check.
- Go to
2. sellifi-api-2 Installation
sellifi-api-2
is a Go Fiber application handling green score services.
2.1 Prerequisites
- Go (version 1.19 or above)
- Redis (for caching)
- PostgreSQL (for persistent storage)
2.2 Installation Steps
-
Clone the Repository:
git clone https://github.com/Forest-Economy-Alliance/sellifi-central.git cd sellifi-api-2
-
Set Up Environment Variables:
- Copy
.env.example
to.env
and configure values.
- Copy
-
Install Dependencies:
go mod tidy
-
Start the Application:
go run main.go
-
Verify API is Running:
- Check
http://localhost:8080
.
- Check
3. sellifi-mobile-app Installation
sellifi-mobile-app
is a React Native application used for forest commodity services.
3.1 Prerequisites
- Node.js (version 14+)
- npm or yarn
- Android Studio (for Android)
- Xcode (for iOS on macOS)
3.2 Installation Steps
-
Clone the Repository:
git clone https://github.com/Forest-Economy-Alliance/sellifi-central.git cd sellifi-mobile-app
-
Install Dependencies:
npm install # OR yarn install
-
Set Up Environment Variables:
- Copy
.env.example
to.env
and set values.
- Copy
-
Start the App on Android/iOS:
- For Android:
npx react-native run-android
- For iOS (macOS only):
npx react-native run-ios
- For Android:
4. sellifi-mobile-app-food Installation
sellifi-mobile-app-food
is a React Native application designed to streamline requirements from schools to Farmer Producer Companies (FPCs).
4.1 Prerequisites
- Node.js (version 14+)
- npm or yarn
- Android Studio (for Android)
- Xcode (for iOS on macOS)
4.2 Installation Steps
-
Clone the Repository:
git clone https://github.com/Forest-Economy-Alliance/sellifi-central.git cd sellifi-mobile-app-food
-
Install Dependencies:
npm install # OR yarn install
-
Set Up Environment Variables:
- Copy
.env.example
to.env
and set values.
- Copy
-
Start the App on Android/iOS:
- For Android:
npx react-native run-android
- For iOS (macOS only):
npx react-native run-ios
- For Android:
5. sellifi-alertfuze Installation
sellifi-alertfuze
is a Serverless Application Model (SAM) project.
5.1 Prerequisites
- AWS CLI configured
- AWS SAM CLI
5.2 Installation Steps
-
Clone the Repository:
git clone https://github.com/Forest-Economy-Alliance/sellifi-central.git cd sellifi-alertfuze
-
Install Dependencies:
sam build
-
Deploy the Application:
- Use the following command to deploy:
sam deploy --guided
- Follow the guided prompts, providing AWS configurations.
- Use the following command to deploy:
-
Verify Deployment:
- Verify endpoints in the AWS Console.
6. sellifi-hyperledger-fabric-net Installation
sellifi-hyperledger-fabric-net
is a Hyperledger Fabric project managed with Fablo.
6.1 Prerequisites
- Docker and Docker Compose
- Fablo CLI
6.2 Installation Steps
-
Clone the Repository:
git clone https://github.com/Forest-Economy-Alliance/sellifi-central.git cd sellifi-hyperledger-fabric-net
-
Start the Fabric Network:
fablo up
-
Install Chaincode (Smart Contracts):
- Follow Fablo commands to install and approve chaincode on the network.
-
Interact with the Network:
- Use Fablo CLI or API endpoints to interact with the chaincode.
-
Shut Down the Network:
fablo down
Additional Notes
- For environment-specific configurations, ensure each
.env
file is set up correctly for production, development, or testing environments. - Refer to each folder’s
README.md
file for component-specific instructions or troubleshooting.
This guide should cover basic installations and setup processes for each component in the Sellifi project. If there are any further questions, refer to individual project documentation within the repository.