-
Docker, Kubernetes are supported
-
Docker image at
ntrung03/musicstream
-
Fill out the tokens in
.env
or in docker-compose.yml -
Run
docker-compose up
-
Run
docker pull ntrung03/musicstream
to update to the latest image
-
Fill out the tokens in
secrets-example.yml
, base64-encoded -
Run
kubectl apply -f /path/to/secrets-example.yml
to set the secrets -
Run
kubectl apply -f k8s.yml
to start the server -
Run
kubectl rollout restart deployment/musicstream
to pull new image from docker and update the server
- You can find the required APT packages in Aptfile
- Run
go build -o MusicStream cmd/MusicStream/main.go
to build the server
-
Run
./MusicStream
to start the server -
By default, the server listens at port
:8080
, change that by setting$PORT
-
By default, the server servers static files from
www/
, change the serving directory by setting$WWW
- Prebuilt binaries of tags are available from the Releases tab.
Enviroment variables are also loaded from .env
file, if exists
- Login to Musixmatch on your browser
- Find the usertoken, which is the cookies named
musixmatchUsertoken
andOB-USER-TOKEN
- Put their values into enviroment variables named
MUSIXMATCH_USER_TOKEN
andMUSIXMATCH_OB_USER_TOKEN
, respectively - The
MUSIXMATCH_OB_USER_TOKEN
is optional and can be omited if you can get the usertoken from the Musixmatch's client app.
- Get Youtube Data API v3 key from Google Cloud Console and put in the environment variable named
YOUTUBE_DEVELOPER_KEY
- The default path will be served is
www/
, if you want to serve from another directory, set environment variableWWW
to the path to that directory
- By default, all music sources are sorted alphabetically by plugins' file name and the first source is selected automatically if user visits the website for the first time. Set environment variable
DEFAULT_SOURCE
to the first choice source.