Skip to content

How to install project

Kristina edited this page Nov 23, 2021 · 2 revisions

To install Frontend (React)

git clone https://github.com/ita-social-projects/TeachUAClient.git in your target folder.

Your main branch will be develop > git checkout develop. Make sure you are in develop > git branch.

Install NodeJS.

After cloning the project do:

npm install

npm run start

Your frontend should be available on http://localhost:3000/dev

To install Backend (Java 8)

1. Install Intellij Ultimate edition (https://www.jetbrains.com/).

2. Clone project

git clone https://github.com/ita-social-projects/TeachUA.git in your target folder.

Your main branch will be rest > git checkout rest.

Make sure you are in rest > git branch.

3. Install pgAdmin.

  1. Create empty DB teachua.

  2. Get data.sql

  3. In application-dev.properties in your IntelliJ uncomment spring.datasource.initialization-mode=always.

4. Configure project in IntelliJ.

  1. Get your environment variables:

JWT_SECRET=teachuamain;UPLOAD_PATH=target/upload;PUBLIC_URL=/dev;STATIC_FOLDER=static;DEV2_DATASOURCE_URL=jdbc:postgresql://localhost:5432/teachua;DEV2_DATASOURCE_USER=postgre;DEV2_DATASOURCE_PASSWORD=postgre;[email protected];USER_PASSWORD=rNdkO345!CaBVN1;OAUTH2_GOOGLE_CLIENT_ID=719863407108-293ckbk2ecskrfnqb19ll156ks1rmtgs.apps.googleusercontent.com;OAUTH2_GOOGLE_CLIENT_SECRET=snQqRHMBhuTo0CB2cXjQHZaS;OAUTH2_FACEBOOK_CLIENT_ID=450991699280123;OAUTH2_FACEBOOK_CLIENT_SECRET=1bd675da37e5c1e8edbabbcc656f44ca;BASE_URL=https://speak-ukrainian.org.ua/dev;URL_LOGS=./target/logs/

and put them in Run/Debug Configuration in IntelliJ.

  1. Make sure your Main class is: com.softserve.teachua.Application.

  2. JRE should be 1.8.

  3. Use classpath of module: TeachUA.

5. Run project via Run button in IntelliJ.

mvn clean

mvn package or mvn package -DskipTests

Go to pgAdmin & refresh Tables, you should see new tables loaded.

More info here: https://www.youtube.com/watch?v=x0BedRI60D4&ab_channel=JaroslavGarasym