MusicVerse ๐ต๐
MusicVerse, a cross-platform Music App: Developed for my final year project using React Native Expo, TypeScript, NestJS, and PostgreSQL. Making music-sharing simple than ever. ๐ถโจ
Features
- ๐ Secure Authentication, Authorization, Session Management, Validation, Performance Concerned System
- ๐ง Listening to music
- โฌ๏ธ Uploading tracks, albums, and playlists
- ๐ Sharing your favorite music with friends
- ๐ฅ Offline listening and downloads
- ๐๏ธ Feature-rich music player
- ๐ต๏ธโโ๏ธ Follow other users and artists
- ๐ฅ Collaborative playlist creation
- ๐ป Background playback
- ๐ฎ Personalized song recommendations based on your listening history
- โค๏ธ Like/Unlike tracks and save/unsave playlists
- ๐ฐ Personalized feed content
- ๐ Push notifications and in-app notifications
- ๐ Shareable links for easy sharing
Tech Stack
- ๐ฑ React Native (Expo) with TypeScript for cross-platform mobile development
- ๐ธ๏ธ NestJS for the backend
- ๐พ PostgreSQL database with Prisma ORM
- ๐ง Python-based recommendation system
- ๐ NextJS for the admin dashboard
- ๐ Agile Incremental model for project methodology
- ๐งช Manual testing and unit testing with Jest
Instructions to Run Locally
Requirements
- Node.js
- NPM
- Python
- eas-cli (for building the app)
- Zrok (recommended for port forwarding)
- Either an SDK manager or a mobile device with Expo installed and connected to the same internet (assuming no firewall blockages)
- PostgreSQL database created based on the following URL:
DATABASE_URL="postgresql://musicverse:musicverse@localhost:5432/musicverse_db?schema=public"
(or edit this in the .env
file of musicverse-backend
)
Setup
- Navigate to
musicverse-app
and runnpm install
- Navigate to
musicverse-backend
and runnpm install
- Navigate to
musicverse-dashboard
and runnpm install
- Navigate to
musicverse-recommendation-system
, activate the virtual environment, and runpip install -r requirements.txt
- Run
npx prisma migrate
to create tables according to the schema
Running the Project
You have two options for running the project:
Option 1: Change Port Numbers
- Change the port numbers for each project and update the
BASE_URL
in the.env
file,package.json
, andeas.json
accordingly.
Option 2: (Recommended) Use Zrok
- Install Zrok from https://docs.zrok.io/docs/getting-started
- Invite yourself to Zrok by running the
zrok invite
command - Check your email, click the invite link, and enter a password for your account
- Log in to Zrok and retrieve your token
- Back in your terminal, run
zrok enable [your_token]
- Run the following command:
zrok reserve public http://localhost:{musicverse_backend_port}--backend-mode proxy
This will generate a reserved token, which you can use to forward the musicverse-backend
localhost port, making it publicly accessible and bypassing any firewall limitations.
- Update the
package.json
ofmusicverse-backend
with your new Zrok reserved token:
"start:dev": "nest start --watch --port 5984",
"start:zrok": "zrok share reserved {zrok_reserved_token}",
"start:both": "concurrently \"npm:start:dev\" \"npm:start:zrok\""
Replace "{zrok_reserved_token}" with your own token and execute npm run start:both.
Update the package.json of musicverse-dashboard and musicverse-app, eas.json of musicverse-app, and recommender.py of musicverse-recommendation-system with your new Zrok reserved token. Navigate to musicverse-dashboard and run npm run dev.
The default admin credentials are (automatically seeded): Email: [email protected] Password: Admin@2024 Username: admin
Run python recommender/app.py to start the Flask app for the recommendation system. Run npm run dev in musicverse-app to run the React Native app in development mode. Open the SDK emulator or your phone, launch Expo, and run the app.
ยฉ๏ธ Copyright Sugam Subedi https://www.github.com/supSugam