|
|
3 zile în urmă | |
|---|---|---|
| .. | ||
| .dockerignore | 3 zile în urmă | |
| .gitignore | 3 zile în urmă | |
| Dockerfile | 3 zile în urmă | |
| README.md | 3 zile în urmă | |
| cert_request.ext | 3 zile în urmă | |
| cert_request.ini | 3 zile în urmă | |
| docker-compose.yml | 3 zile în urmă | |
| entrypoint.sh | 3 zile în urmă | |
| hls.html | 3 zile în urmă | |
| nginx.conf | 3 zile în urmă | |
This is a test server that can used for isolated testing of the following streams:
Note! RTMPS functionality is not currently working as indicated by strike-throughs below
Start server with:
SSL_DOMAIN="{IP_ADDRESS}" docker compose up
where IP_ADDRESS is the IP Address of the device the server is running on.
The server accepts communication on the following endpoints / ports:
| Port | Endpoint | Communication Type | Example |
|---|---|---|---|
| 8080 | HLS stream viewer | http://{IP_ADDRESS}:8080 | |
| 8080 | stats | stream stats via HTTP | http://{IP_ADDRESS}:8080/stats |
| 8443 | stats | stream stats via HTTPS | https://{IP_ADDRESS}:8443/stats |
| 1935 | live/test | RTMP stream | rtmp://{IP_ADDRESS}:1935/live/test |
The general usage is:
live/test endpoints.http://{IP_ADDRESS}:8080)A certificate and key are generated when docker image starts and placed in the .ssl directory.
To use this certificate to communicate with the test server, install rtmp.crt as trusted root certificate.
The steps for this vary per OS. On Ubuntu for example:
$ sudo cp ./.ssl/self-signed/rtmp.crt /usr/local/share/ca-certificates
$ sudo update-ca-certificates
For sanity testing, an RTMP(S) stream can be sent to the test server as follows:
Test via:
docker run --rm jrottenberg/ffmpeg:4.1-alpine -r 30 -f lavfi -i testsrc -vf scale=1280:960 -vcodec libx264 -profile:v baseline -pix_fmt yuv420p -f flv rtmp://{IP_ADDRESS}:1935/live/test
View at: http://localhost:8080
1. Test via:
docker run --rm jrottenberg/ffmpeg:4.1-alpine -r 30 -f lavfi -i testsrc -vf scale=1280:960 -vcodec libx264 -profile:v baseline -pix_fmt yuv420p -f flv rtmps://{IP_ADDRESS}:1936/live/test
2. View at: http://localhost:8080
Per-stream stats can be viewed at http://localhost:8080/stats. The .xml provided by this endpoint could,
for example, be used as a programmatic way to verify a stream has started / stopped.