@musicshare/react-graphql-client v1.1.0
Simple yet powerful self-hosted open-source music library.
Motivation
iTunes used to be a really great and simple yet powerful music library, but suffered user experience, platform support, and mobility during the recent years.
Streaming services became the way listening to music nowadays, but you are not the owner of the music.
MusicShare is there to combine both ideas - providing a simple yet powerful service to manage and share your own self-hosted music library.
Current Development Status
We are working hard to release the first version of MusicShare. See the roadmap and project status.
Local Setup
Run The Project
Windows: Be sure to have node-gyp and the latest Node.JS version installed. For node-gyp, see instructions here.
- Clone this repo
- Run
npm installoryarn installto install and bootstrap dependencies - Create local configurations for
frontendandbackendby copying the sample.envfiles (cp projects/backend/config/development_sample.env projects/backend/development.env && cp projects/frontend/config/sample.env projects/frontend/.env) Create and start MusicShares dependencies PostgreSQL database with docker (
docker-compose up)a) If your system already runs a PostgreSQL database:
In this case, you only need to spin up the Minio (S3 compatible file storage) service. Just run
docker-compose up -d minio.b) If your system does no already run a PostgreSQL database:
Run
docker-compose up -dto spin up a PostgreSQL database and the Minio (S3 compatible file storage) service.Open two terminal tabs and start backend and frontend via
npm run start:backendandnpm run start:frontend, respectively.- Once both parts are up and running, you can log in via the default user
test@musicshare.rockswith the super-safe passwordtest1234.
If you want to run parts of the project seperatly, have a look at the provided scripts of the root package.json.
Troubleshooting
SQLError: error: database "<user>" does not exist SQL: SELECT FROM pg_database WHERE datname = 'musicshare' Values:- connect to the PostgreSQL database first via a thrid party client or
psqland create a database named<user> - for more information on this problem you can also visit this StackOverflow thread
- connect to the PostgreSQL database first via a thrid party client or
Testing
To execute the test cases, you need to create a separate test.env for the backend
project (cp projects/backend/config/development_sample.env projects/backend/test.env),
and adjust the database connection variables accordingly.
Important notes
- Be sure to always run tsc in watch mode (e.g. via
dev:backendnpm script) when writing test cases sincets-jestis configured to skip type checking - When calling
executeGraphQLQueryfunction in integration tests, the default logged-in user istestData.users.user1
Contributing
We are always happy welcoming new people contributing to this project. Here's a little guide to get started!
Contributors
- Yannick Stachelscheid (@yss14)
- Felix Wohnhaas (@fewhnhouse)
- Tobias Klesel (@tobi12345)
- Christian Diemers (@Freshchris01)
License
This project is licensed under the AGPL license.