Skip to content

MyBlog is a lightweight Node.js blogging platform with MongoDB integration for secure user authentication and seamless deployment on AWS Elastic Beanstalk. Users can effortlessly create accounts, log in securely, and share their thoughts through blog posts. Built with simplicity and scalability in mind.

Notifications You must be signed in to change notification settings

ashu6530/MyBlog---NodeJS

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MyBlog - A Simple Blogging Website

Description

MyBlog is a simple blogging website built using Node.js and MongoDB. It allows users to create an account, log in securely, add their blogs, and view them on the website. The authentication system employs password hashing with salt and HMAC, while user sessions are managed using JSON Web Tokens (JWT) with cookies. The application is deployed on AWS Elastic Beanstalk for easy scalability and management.

Features

  1. User Authentication:

    • Users can create an account with a username and password.
    • Passwords are securely hashed using salt and HMAC.
    • Authentication is handled using JWT with cookies for maintaining user sessions.
  2. Blog Management:

    • Authenticated users can add their blogs to the website.
    • Blogs are stored in a MongoDB database.
    • Added blogs are displayed on the website for other users to read.
  3. Deployment:

    • The application is deployed on AWS Elastic Beanstalk for scalability and reliability.
    • Elastic Beanstalk automates the deployment, scaling, and management of the application.

Technologies Used

  • Node.js: Backend JavaScript runtime environment.
  • Express.js: Web application framework for Node.js.
  • MongoDB: NoSQL database for storing user data and blogs.
  • JWT: JSON Web Tokens for secure authentication.
  • AWS Elastic Beanstalk: Cloud deployment and management service.
  • HTML/CSS: Frontend development for the website.

Getting Started

  1. Clone the repository:

  2. Install dependencies: cd myblog npm install

  3. Set up environment variables:

  • Create a .env file in the root directory.
  • Define the following variables:
    PORT=8000
    MONGODB_URI=your_mongodb_uri
    JWT_SECRET=your_jwt_secret
    
  1. Run the application: you can use npm and then name of the root file or install nodemon

  2. Access the application:

  • Open a web browser and navigate to http://localhost:8000.

Contributing

Contributions are welcome! If you'd like to contribute to the project, please follow these steps:

  1. Fork the repository.
  2. Create a new branch (git checkout -b feature/new-feature).
  3. Make your changes and commit them (git commit -am 'Add new feature').
  4. Push to the branch (git push origin feature/new-feature).
  5. Create a new Pull Request.

Contact

For any inquiries or support, please contact your-email@example.com.

Acknowledgments

  • Thanks to Node.js and MongoDB for providing powerful tools for building web applications.
  • Special thanks to the contributors and open-source community for their valuable contributions and support.

About

MyBlog is a lightweight Node.js blogging platform with MongoDB integration for secure user authentication and seamless deployment on AWS Elastic Beanstalk. Users can effortlessly create accounts, log in securely, and share their thoughts through blog posts. Built with simplicity and scalability in mind.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published