Skip to content

dtinth/jamulus-php

 
 

Repository files navigation

jamulus-php

PHP script to fetch info from Jamulus servers and return as JSON

Used as a back-end by Jamulus Explorer (github page) and also Jamulus.Live (github page).

Normally invoked as servers.php?directory=directory.server.host:port, which will return data for all servers registered with that directory server.

Can also be invoked as servers.php?server=individual.server.host:port, which will return data just for the specified individual server. Note that in this case, the server name, city and country cannot be returned, as they are only available from a directory server.

Finally, it is possible to query a server's welcome message using servers.php?query=individual.server.host:port, which will briefly initiate an audio connection to the server, collect any welcome message returned, and disconnect again. This happens quickly, so no additional client is displayed to the other clients, but if a server is already full, it does not work.

Firewall requirements

In order to support "port2" detection, this back-end needs to be able to accept server replies coming from any port, not just from the expected port to which a request was sent.

To allow this, the server.php back-end sets its source port in a specific range, 22134-22149 (See the defines for CLIENT_PORT and CLIENT_PORTS_TO_TRY). The system hosting the back-end needs to have its firewall configured to accept incoming traffic to that specific port range from any IP address and any port number.

docker pull ghcr.io/dtinth/jamulus-server-list-backend:master
docker tag ghcr.io/dtinth/jamulus-server-list-backend:master asia-southeast1-docker.pkg.dev/$GOOGLE_CLOUD_PROJECT/jamulus-server-list-backend/jamulus-server-list-backend:latest
docker push asia-southeast1-docker.pkg.dev/$GOOGLE_CLOUD_PROJECT/jamulus-server-list-backend/jamulus-server-list-backend:latest

About

PHP script to fetch info from Jamulus servers and return as JSON

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages

  • PHP 67.8%
  • TypeScript 31.6%
  • Dockerfile 0.6%