Java-A-60-Forum-System-by-D-D / forum_system

Web project creatinga
0 stars 0 forks source link

ForumProject

Overview

ForumProject is a web application built using Java, Spring Boot, and Thymeleaf. It allows users to create, view, and manage posts and comments. The application also includes an admin portal for managing users and their posts.

Features

Technologies Used

Getting Started

Prerequisites

Installation

Clone the repository:

git clone https://github.com/your-username/ForumProject.git
cd ForumProject
  1. Environment Variables You need to set up the following environment variables for database and Cloudinary configuration:

    • mySQLuser: Database URL

    • mySQLuser: your database username

    • mySQLpassword: your database password

    • API_KEY: Cloudinary API key

    • API_SECRET: Cloudinary API secret

    • CLOUD_NAME: Cloudinary cloud name

    • MAILUSER: Email address for sending emails

    • MAILPASS: Email password for sending emails

  2. Database Setup 2.1 Hibernate Configuration In the HibernateConfig class:

    • Change the hibernate.hbm2ddl.auto property to create to create the database schema.
    • Change the hibernate.hbm2ddl.auto property to update to update the database schema. 2.2 Initial Data Population To auto-populate the database with initial data: In application.properties, set the spring.jpa.hibernate.ddl-auto property to create or update. Once the application is running, the database will be populated with initial data and the property should be set back to never.
  3. Running SQL Scripts Manually (Optional) SQL scripts are located in the src/main/resources folder. You can run these scripts manually if needed. Note: Ensure that the password is hashed in the user table if you are manually inserting data.

  4. Build the project:

    gradle build
  5. Run the application:

    gradle bootRun

Usage

Project Structure

Contributing

  1. Fork the repository.
  2. Create a new branch (git checkout -b feature-branch).
  3. Make your changes.
  4. Commit your changes (git commit -m 'Add some feature').
  5. Push to the branch (git push origin feature-branch).
  6. Open a pull request.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Contact

For any inquiries or issues, please contact deszafirova@gmail.com or hadzhiev96@gmail.com