/platform

FundRequest platform code (core)

Primary LanguageJavaMIT LicenseMIT

FundRequest Platform

Decentralized marketplace for Open Source software developement

Version

BrowserStack Status

Maintainability

To report a bug or request a feature or change please open a new issue

Other useful links

Setup guide

  1. Install git
  2. Install Node
  3. Install java
  4. Clone repository
  5. Run dependencies
  6. Configure application properties
  7. Start application
  8. Use application

Install Git

If you don't have Git installed, you will need to this in order to build: https://git-scm.com/book/en/v2/Getting-Started-Installing-Git

Make sure the git binary is on $PATH.

Install Node

If you do not have Node installed, please install the latest LTS release: https://nodejs.org/en/

Install java

You need Java 8 to run the platform. Please download and install from here: http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html

Make sure you set the JAVA_HOME environment variable: http://www.baeldung.com/java-home-on-windows-7-8-10-mac-os-x-linux

Fork and Clone the repository

Fork the repository, to afterwards clone it to a local directory

Run dependencies

To run the dependencies, you need to have Docker installed: You can run these dependencies using Docker: https://www.docker.com/community-edition

FundRequest has several dependencies to run locally:

  • Database (MariaDB)
  • Message broker (RabbitMQ)
  • Azrael (Solution from FundRequest to abstract blockchain related transactions)

Azrael

Azrael needs an ethereum account to execute its transactions (e.g. claim, refund). This account needs to have Kovan ETH on it to cover the transaction fees. To acquire this, just post your address in this Gitter channel: https://gitter.im/kovan-testnet/faucet

To link your account to Azrael, create the following file core/.env with contents:

AZRAEL_SIGN_ACCOUNT=d243cfdc9801e6720104f0f675e15d31f582d045ccbef9586d2d78d8e6f84ce7
AZRAEL_EXECUTE_ACCOUNT=<private_key_of_your_account>

To be able to use the refund functionality, your execute account needs to be whitelisted in our contract. You can send it to us via Telegram (https://t.me/FundRequestDevs) and we will whitelist it for you.

Running the dependencies

To start the dependencies, go inside the cloned repository and execute runDependencies.sh

Configure application properties

Copy tweb/src/main/resources/application-credentials.properties.template to tweb/src/main/resources/application-credentials.properties and edit properties

Copy admin-web/src/main/resources/application-credentials.properties.template to admin-web/src/main/resources/application-credentials.properties and edit properties

feign.client.github.username=<your github username>

#create a developer access token on github: https://github.com/settings/tokens
feign.client.github.password=<your github token>

local.ethereum.kovan.address=<your ethereum address>

Start application

You have 2 options to start the application. If you didn't work with maven/spring boot in the past, you can use the quick setup. If you have experience, please go to the import guide below.

Quick

To run the application, execute:

  1. build.sh on Linux/Mac and build.bat on Windows. This script will build the entire project, if you make any changes, rerun this script. Building the first time will take a bit longer.
  2. runPlatform.sh on Linux/Mac and runPlatform.bat. This will run the platform, when rebuilding stop this script first.
  3. runAdmin.sh on Linux/Mac and runAdmin.bat. This will run the admin panel, when rebuilding stop this script first.

Import - better for development

The application is a standard maven / spring boot setup. For local development you have to start the application with the spring profile local. You can import the entire project using your favourite IDE.

To start the platform, you can run the java class:

io.fundrequest.platform.tweb.WebApplication.java

To start the admin panel, you can run the java class:

io.fundrequest.platform.admin.AdminApplication.java
Developer notes

For changes in the frontend parts (scss, ts, vue, ...) there are some node scripts to rebuild/recompile changes on the fly during development.

  • Go to /tweb/src/main/frontend
  • Run npm install (installs all node dependencies)
  • Run npm run watch to rebuild all styles on change. (Changes will be directly visible on a browser refresh.)
  • Run npm run webpack-watch to rebuild all .ts and .vue on change. (Changes will be directly visible on a browser refresh.)

Use application

The platform is available on http://localhost:8080

Login using

User: johndoe
Password: test

The admin panel is available on http://localhost:8181

User: admin
Password: test