README ΒΆ
FilmWise
π Table of Contents
FilmWise
FilmWise: Your Ultimate Movie Hub. Experience movies like never before with FilmWise, the web application that lets you dive into detailed movie information, share your thoughts through comments and reviews, and connect with fellow cinephiles. Discover, discuss, and decide on your favorite films all in one place. if you want to see the front-end part, you can click here
π Built With
Tech Stack
Front End
- Nextjs
- React
- Redux
- JAVASCRIPT
- Html
- CSS
Back End
- Golang
- PostgreSQL
π Live Demo
- Project ScreenShot
Key Features
- Discover detailed movie information, from plots to cast.
- Engage in vibrant discussions by commenting on movies.
- Add your personal reviews to contribute to the community.
π» Getting Started
To get a local copy up and running, follow these steps.
Prerequisites
In order to run this project you need:
-
Then Make sure you have installed Go (golang) version 1.20.4 or the latest stable version.
-
Then make sure you have installed PostgreSQL on your local machine if you want to use this project locally.
-
Then Create a database called
filmwise
inside the database and create tables using thisproject>database
schema
SQL query. -
First of all to see this project's graphical interface make sure you run the front-end part
Setup
- Clone this repository to your desired folder:
cd your-folder
https://github.com/raihan2bd/filmwise.git
- Before running the project please make sure you create a
.env
file to your project root directory and addDATABASE_URI
, andJWT_SECRET_KEY
environment variables to the file. For example:
DATABASE_URI="host=localhost port=5432 dbname=filmwise user=postgres password=your password sslmode=disable"
JWT_SECRET="your jwt secret key"
CLD_URI="Secreat Key of cloudinary"
CLOUD_NAME="Name of cloudinary account"
Getting JWT Secret Key
To obtain the JWT secret key, please click here.
An open Go terminal is required. In the terminal, please copy the following code and paste it into your .env file.
Like this
JWT_SECRET="*******"
package main
import (
"crypto/rand"
"encoding/base64"
"fmt"
)
func main() {
// Define the desired length of the secret key in bytes
keyLength := 64 // Adjust the length as needed
// Create a byte slice to hold the random bytes
key := make([]byte, keyLength)
// Generate random bytes using crypto/rand
_, err := rand.Read(key)
if err != nil {
fmt.Println("Error generating random bytes:", err)
return
}
// Encode the random bytes in base64 to create a string
secretKey := base64.StdEncoding.EncodeToString(key)
fmt.Println("Generated JWT secret key:", secretKey)
}
Getting Cloudinary Serect key and Name
Cloudinary is a cloud-based media management platform that helps businesses and developers efficiently store, manage, and deliver images and videos for websites and applications. It provides features like image and video uploading, storage, transformation, optimization, and content delivery via a content delivery network (CDN), making it easier to handle media assets in web and mobile applications. Cloudinary's services can enhance website performance, user experience, and streamline media asset workflows.
For using this you need to Create an account Or if you have an Account you need to Sign In
After that go into the Dashborad
Copy the Cloud Name and API Environment variable
CLD_URI="cloudinary://******"
CLOUD_NAME="****"
Install
Install this project with:
- Install the required gems with:
go mod tidy
Database
- Create the databases properly, You need to open an SQL editor and run the
/database/schema.sql
file script. Make sure you run the script block by block.
Usage
- To run the development server, execute the following command:
go run ./cmd/api/ .
Build
- To build the project for production-ready run the following command:
go build -o main ./cmd/api/*.go
Deployment
To deploy your project online You can visit Render
π₯ Author
π€ Abu Raihan
- GitHub: @raihan2bd
- Twitter: @raihan2bd
- LinkedIn: raihan2bd
π€ Hassaan Baig
- GitHub: @Hassaanjbaig
- LinkedIn Hassan Baig
π Future Features
- Improve user experience
π€ Contributing
Contributions, issues, and feature requests are welcome!
Feel free to check the issues page.
βοΈ Show your support
If you like this project, please leave a βοΈ
π Acknowledgments
I would like to thank Trevor Sawler Who helped me a lot to learn Golang.
π License
This project is MIT licensed.