Yet another Campus Playout implementation. Will it succeed? Who knows!
- Liquidsoap (actually does the audio stuff)
- mediamtx (HLS streaming)
- Rust + axum (backend)
- sqlite (database)
- maud (HTML templating)
- htmx (frontend interactivity)
- Bootstrap (UI styling)
- A last.fm API key
- A MyRadio API key
- A rust toolchain
- Liquidsoap
- The sqlx-cli (
cargo install sqlx-cli) - mediamtx server with SRT and HLS enabled
Create a .env file with the following content:
DATABASE_URL=sqlite:database.db
INSTANCE_NAME="Test Venue"
LAST_FM_API_KEY=
MYRADIO_API_BASE=https://ury.org.uk/api/v2
MYRADIO_API_KEY=
PLAYLIST_CATEGORY_ID=3
DEFAULT_PLAYLIST_ID=pop-
JINGLES_FILE=/data/jingles.txt
MORNING_JINGLES_FILE=/data/morning-jingles.txt
AFTERNOON_JINGLES_FILE=/data/afternoon-jingles.txt
EVENING_JINGLES_FILE=/data/evening-jingles.txt
PROMOS_PLAYLIST_ID=6
PLAYLIST_FILE=./playlist-gen.txt
UNIX_SOCKET_PATH=test/campus-playout.sock
API_TOKEN=changeme
SRT_HOST=mediamtx
SRT_PORT=8890
SRT_USERNAME=username
SRT_PASSWORD=password
SRT_STREAM_ID=test-venue
HLS_BASE_URL=http://mediamtx:8888
Loading the .env file is up to you.
Create the database with sqlx database create.
Run the Rust control server with cargo run.
Start the liquidsoap script with liquidsoap scripts/playout.liq.
