Sign inSign up

ghiltoniel/playzik

By ghiltoniel

•Updated about 9 years ago

Backend API for the Playzik collaborative playlist platform

Image
0

989

ghiltoniel/playzik repository overview

⁠Playzik

Playzik is a collaborative playlist manager. Live demo : https://beta.playzik.io⁠

⁠Requirements

Playzik requires the following SaaS services to work :

⁠Architecture

Playzik is a classic 4 tiers MVVM app that uses many cloud services to work properly

architecture

⁠Setup

You can host Playzik yourself with docker using the following docker file with the following parameters :

⁠For the frontend
  • Auth0 domain (or host) : your Auth0 domain url (ex : my-domain.eu.auth0.com)
  • Auth0 client ID : your Auth0 client ID (32 length token)
  • SoundCloud Client ID : your Soundcloud client ID (32 length token)
  • Log Entries token : your Log Entries token (36 length token)
  • The API Url : the external address of your back service URL
⁠For the backend
  • MongoDB URI : the URI of the MongoDB Database (cf the database parameters section)
  • Auth0 domain (or host) : your Auth0 domain url (ex : my-domain.eu.auth0.com)
  • Auth0 audience : cf Auth0 Client ID
  • Auth0 secret : your Auth0 secret (64 length token)
  • Auth0 admin token : an admin permanent token (in order to retrieve users email address for SMTP purposes). Docs are here : https://auth0.com/docs/api/management/v2/tokens#get-a-token-manually⁠
  • Mailer From : the SMTP "From" field when sending applications emails
  • Mailer Host : the SMTP Host field to send applications emails
  • Mailer Port : the SMTP Port field to send applications emails
  • Mailer SSL : is the SMTP SSL Secure
  • Mailer Username : the SMTP username field to send applications emails
  • Mailer Password : the SMTP password field to send applications emails
⁠For the database
  • Mongo InitDB Root Username : the MongoDB Username
  • Mongo InitDB Root Password : the MongoDB password
  • Mongo InitDB Database : the MongoDB database name
version: '3'
services:
  front:
    image: ghiltoniel/playzik-front
    ports:
      - "3000:80"
    depends_on:
      - back
    environment:
      AUTH0_DOMAIN: <auth0 domain>
      AUTH0_CLIENTID: <auth0 clientID>
      SC_CLIENTID: <Soundcloud Client ID>
      LE_TOKEN: <Log Entries token>
      API_URL: http://localhost:3001
    networks:
      - playzik

  back:
    image: ghiltoniel/playzik-back
    depends_on:
      - database
    ports:
      - "3001:3000"
    environment:
      MONGOLAB_URI: mongodb://<mongo_username>:<mongo_pass>@database:27017/
      AUTH0_HOST: <auth0 domain>
      AUTH0_SOCKETIO_SECRET: <auth0 socket io secret>
      AUTH0_AUDIENCE: <auth0 audience>
      AUTH0_ADMIN_TOKEN: <auth0 admin user token>
      MAILER_FROM: <from_email>
      MAILER_HOST: <smtp_host>
      MAILER_PORT: <smtp_port>
      MAILER_SSL: <smtp_use_ssl>
      MAILER_USERNAME: <smtp_username>
      MAILER_PASSWORD: <smtp_password>
    networks:
      - playzik

  database:
    image: mongo
    environment:
      # provide your credentials here
      - MONGO_INITDB_ROOT_USERNAME=<mongo_username>
      - MONGO_INITDB_ROOT_PASSWORD=<mongo_pass>
      - MONGO_INITDB_DATABASE=playzik
    networks:
      - playzik

networks:
  playzik:
    driver: bridge

You can start your Playzik instance by running: docker-compose up -d

Tag summary

Content type

Image

Digest

Size

98.2 MB

Last updated

about 9 years ago

docker pull ghiltoniel/playzik