Skip to content

2mixxx allows you to request songs to the DJ (guest user) or moderate song requests (DJ user). This application also allows DJs to have full control over the songs that can be requested by importing their iTunes libraries into the application.

License

Notifications You must be signed in to change notification settings

carlesfelix/2mixxx

Repository files navigation

2mixxx

2mixxx is a web application for requesting songs that DJs have in their iTunes libraries.

image

Installation and build guide

  1. Install git
  2. Install docker compose
  3. Create an auth0 account.
  4. Create a Single-Page Application API in your auth0 account.
  5. Create a Machine to Machine API in your auth0.
  6. Clone the project
$ git clone https://github.com/carlesfelix/2mixxx.git
  1. Create the environment variables for frontend. /frontend/.env
REACT_APP_SOCKET_BASE_URI=wss://{your_host}:3002
REACT_APP_AUTH0_DOMAIN={your_auth0_domain}
REACT_APP_AUTH0_CLIENT_ID={your_auth0_SPA_client_id}
REACT_APP_API_BASE_URL=https://{your_host}:3001/api
GENERATE_SOURCEMAP=false
  1. Create the environment variables for backend. /backend/.env
NODE_ENV=production
API_PORT=3001
MYSQL_ROOT_PASSWORD={your_mysql_root_password}
MYSQL_DATABASE={your_mysql_database}
MYSQL_USER={your_mysql_user}
MYSQL_PASSWORD={your_mysql_password}
MYSQL_HOST=mysql
MYSQL_PORT=3306
MYSQL_SSL=0 # To be upgraded to 1 in the future
SOCKET_PORT=3002
WEB_ORIGIN=https://{your_host}
JWT_ROOM_USERS_SECRET={your_secret}
AUTH0_DOMAIN={your_auth0_domain}
AUTH0_MACHINE_TO_MACHINE_CLIENT_ID={your_machine_to_machine_client_id}
AUTH0_MACHINE_TO_MACHINE_CLIENT_SECRET={your_machine_to_machine_client_secret}
AUTH0_DB_CONNECTION={name_of_the_auth0_database_connection_that_stores_your_users}
  1. Place your ssl files 2mixxx.crt and 2mixxx.key in the project root directory.
  2. Launch 2mixxx with docker compose.
$ docker-compose -f docker-compose.deploy-vps.yml build
$ docker-compose -f docker-compose.deploy-vps.yml up -d
  1. Create the first registered user in your auth0 dashboard.
  2. Create the first registered user (as admin) in the database in order to have full access to the dashboard.
INSERT INTO registered_users (id, createdAt, updatedAt, sub, email, userRole) VALUES('70b77906-ec13-4b79-8a55-f8d33429dfce', now(), now(), 'auth0|auth0_user_id', 'your@email.com', 1);

Setting up the environment for development

Follow the instruccions located in Frontend (client side) and Backend (server side).

About

2mixxx allows you to request songs to the DJ (guest user) or moderate song requests (DJ user). This application also allows DJs to have full control over the songs that can be requested by importing their iTunes libraries into the application.

Topics

Resources

License

Stars

Watchers

Forks