heyhellomila / project-mender

Project Mender: Home Renovation & Maintenance Application

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Project Mender

CircleCI Codacy Badge License: GPL v3 CompanyLogo

A home renovation & maintenance application for homeowners where users are will then be able to create work orders for corrective and preventive maintenance work aimed specifically for the Quebec markets. Every home purchase is required to be catalogued and pass under strict inspection standards that are set by provincial and regional requirements. However, the results of the inspection are too long-winded and are not easily translatable for the client. This application aims to condense, summarize and interpret the results in a visually appealing manner for the client to understand their home better. With this in mind, the homeowner will be able to create and track work orders for corrective and preventive maintenance.

Secondly, the application will include an additional feature for the client to be connected to network of local contractors in the area where they can request and access services directly with the application. The status of the work order can be easily retrieved, scheduled and updated.

This project is also hosted on the Concordia University Gina Cody School of Engineering showcase website.

This web application uses the following technologies:

  • Express, a Node.js back-end framework
  • MySQL, a cross-platform database
  • React Native, an application framework
  • Expo, a framework and platform for React applications.

Installing Dependencies

Before starting, make sure you have working versions of npm (6.12+), node (12.9.0+) and mySQL (5.7.22+).

npm --version
node --version
mysql --version

Package Set Up

Necessary dependencies must be installed for both parts of the application.

For the back-end, execute:

cd backend/
npm install

For the front-end, execute:

cd frontend/
npm install

For Mac OSX Systems ( Catalina - 10.15+ & above)

Update - With the latest release of Mac OSX Catalina (10.15+ and up) on October 19, 2019 and the replacement of bash with zsh, additional steps must be done to allow permissions for the app to run.

Do not use bash for OSX 10.15 & above.

  1. Select System Preferences from the Apple menu.

  2. Select Security & Privacy icon.

  3. Under the Privacy tab, and locate the Full Disk Access folder on the left side pane.

  4. Tick onto the checkbox for the Watchman application to grant full access.

Restart zsh and the Mender application should be running smoothly from here on.

Environment Variables

The /backend will require the following environment variables:

JWT_KEY=
RDS_HOSTNAME=
RDS_PORT=
RDS_USERNAME=
RDS_PASSWORD=
RDS_DATABASE=

The /frontend will require the following environment variables:

LOCAL_API_KEY=<ip-address>:3000

Running the Back-end Server

To start the back-end server, use the following command from backend/:

A. on NodeDemon:

npm start

or

B. on ts-node:

npm run dev

Running the Front-end Server

To start the front-end server, use the following command from frontend/:

npm start

Afterwards, scan the barcode or navigate to the link provided by Expo with your phone.

Note that both servers must be running as separate processes for the application to function.

Running Application with Docker

To create and start the container, use the following command from the project root:

docker-compose up --build

Ensure that port forwarding is enabled with the Docker technology installed, specifically for the following host and guest ports: 3000:3000, 19000:19000, 19001:19001 and 19002:19002. Additionally, add the following environment variable to /frontend:

REACT_NATIVE_PACKAGER_HOSTNAME=<ip-address>

Finally, once the application has been built, scan the QR displayed in the terminal.

Currently, for development purposes, polling/hot reloading is supported for the backend, but not for the frontend (see #195).

Team XENA

xena-banner

Jamal Ghamrouai Dania Kalomiris
Anamika Pancholy Daniel Privorotsky
Mila Roisin SĂ©bastien Ong Tone

About

Project Mender: Home Renovation & Maintenance Application

License:GNU General Public License v3.0


Languages

Language:TypeScript 49.3%Language:JavaScript 47.9%Language:HTML 1.9%Language:CSS 0.8%Language:Dockerfile 0.1%Language:TSQL 0.0%