Skip to content

nayeem-17/Core-Dumped

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Core Dumped

Introduction

A simple question-answering website with blog posting feature, inspired by stackoverflow and Quora(Quora X stackoverflow). Extensively uses the rich text editor Quill and ReactQuill.

Submitted for CSE216-Database Sessional.

Development Stack

How to run this project on your local machine

  • Connecting to Oracle Database

    If you're connecting to a remote database, you'll need to install the instant client to your local machine. Here is HOW

    1. Create a user
      Log in as sysdba in sqlplus. Then run this following command in sqlplus:
      create user c##coredumped identified by password
    
    1. Grant the user the role of DBA or appropriate role.
      grant all privileges to c##coredumped
    
  • Clone this repository and create env file

    You can import the sql dump file and skip the first 3 steps.

    1. First clone this repository to your local machine.
    2. Change your directory to schema. Then login to sqlplus
    sqlplus c##coredumped/password
    
    1. Now run the tables,triggers,procedures and required_initial_data SQL files.
     @DDL_tables.sql;
     @DDL_triggers.sql;
     @DML_procedures.sql;
     @required_initial_data.sql;
    
    1. Create a .env file in the backend directory of this repository. Now put these lines in the file:
    PORT=8000
    NODE_ENV=development
    JWT_SECRET=U~A^O8vk510OZs
    SECRET_TOKEN='abc'
    DB_USER=c##coredumped
    DB_PASSWORD=password
    DB_CONNECTION_STRING=localhost:1521/ORCLCDB # or run SELECT * FROM GLOBAL_NAME; and give appropriate connection string 
    MAIN_URL=http://0.0.0.0:8000
    1. Now, create a .env file in the frontend directory of this repository. Now put these lines in the file:
    REACT_APP_SERVER_URL=http://0.0.0.0:8000
  • Install all dependencies

    1. Install npm & node
    2. Go to the backend directory and run the following command:
    npm install
    1. Go to the frontend directory and run the following command:
    npm install
  • Now start the backend server

    Go to the backend directory and run the following command:

    npm start
  • Now start the frontend

    Go to the frontend directory and run the following command:

    npm start
    • You have to run the above commands in a new terminal window.

Documentation

Backend

We have created API documentation for the backend of this project. After running this project, you can access the documentation by visiting the following link:

http://localhost:8000/api-docs

Here is the pdf version of the documentation: Here

Frontend

Typescript template of create-react-app is used for displaying data.

  1. Components: Code for all the components.

  2. Pages Describes how the components will be displayed.

  3. Utilities Used for fetching and sending data to the backend, uses axios.

  4. App.tsx Primarily contains all the route declarations.




Supervisor

Contributors

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published