Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HTTPD stream #403

Open
bonelifer opened this issue May 4, 2024 · 6 comments
Open

HTTPD stream #403

bonelifer opened this issue May 4, 2024 · 6 comments

Comments

@bonelifer
Copy link

bonelifer commented May 4, 2024

Now that I changed the httpd to lame, 320, I can't get MPDroid or any other mpd client which supports the httpd stream. When my set up was wrong with wave and HTTPD_OUTPUT_ENCODER_BITRATE and HTTPD_OUTPUT_ENCODER_QUALITY set, at least MPDroid would grab the stream and play it. Not sure what to do. Everything seems right. mpd is running as I an able to listen on the desktop via pulseaudio.

.env

HTTPD_OUTPUT_CREATE=yes
HTTPD_OUTPUT_ENABLED=yes
HTTPD_OUTPUT_NAME="HTTP Stream"
HTTPD_OUTPUT_PORT=8000
HTTPD_OUTPUT_BIND_TO_ADDRESS=192.168.1.80
HTTPD_OUTPUT_ENCODER=lame
HTTPD_OUTPUT_ENCODER_BITRATE=320
HTTPD_OUTPUT_MAX_CLIENTS=0
HTTPD_OUTPUT_ALWAYS_ON=yes
HTTPD_OUTPUT_TAGS=yes
HTTPD_OUTPUT_FORMAT=44100:16:2
HTTPD_OUTPUT_MIXER_TYPE=software
PULSE_AUDIO_OUTPUT_CREATE=yes
ENFORCE_PLAYER_STATE=no
AUTO_UPDATE=yes
PUID=1000
GUID=1000

docker-compose.yml

---
services:
  mpd-alsa:
    container_name: mpd-alsa
    devices:
      - /dev/snd
    ports:
      - 6600:6600
    environment:
      - PULSE_AUDIO_OUTPUT_CREATE=${PULSE_AUDIO_OUTPUT_CREATE:-yes}
#      - MPD_BIND_ADDRESS=${MPD_BIND_ADDRESS:-192.168.1.80}
      - MPD_PORT=${MPD_PORT:-6600}
      - PUID=${PUID:-1000}
      - GUID=${GUID:-1000}
      - HTTPD_OUTPUT_CREATE=${HTTPD_OUTPUT_CREATE:-yes}
      - HTTPD_OUTPUT_ENABLED=${HTTPD_OUTPUT_ENABLED:-yes}
      - HTTPD_OUTPUT_NAME=${HTTPD_OUTPUT_NAME:-HTTP Stream}
      - HTTPD_OUTPUT_PORT=${HTTPD_OUTPUT_PORT:-8000}
      - HTTPD_OUTPUT_BIND_TO_ADDRESS=${HTTPD_OUTPUT_BIND_TO_ADDRESS}
      - HTTPD_OUTPUT_ENCODER=${HTTPD_OUTPUT_ENCODER:-lame}
      - HTTPD_OUTPUT_ENCODER_BITRATE=${HTTPD_OUTPUT_ENCODER_BITRATE}
      - HTTPD_OUTPUT_MAX_CLIENTS=${HTTPD_OUTPUT_MAX_CLIENTS:-0}
      - HTTPD_OUTPUT_ALWAYS_ON=${HTTPD_OUTPUT_ALWAYS_ON:-yes}
      - HTTPD_OUTPUT_TAGS=${HTTPD_OUTPUT_TAGS:-yes}
      - HTTPD_OUTPUT_FORMAT=${HTTPD_OUTPUT_FORMAT:-44100:16:2}
      - HTTPD_OUTPUT_MIXER_TYPE=${HTTPD_OUTPUT_MIXER_TYPE:-software}
      - AUTO_UPDATE=${AUTO_UPDATE:-yes}
      - ENFORCE_PLAYER_STATE=${ENFORCE_PLAYER_STATE:-no}

    volumes:
      - /media/william/OracleHarbor/LidarMusic/CLEAN/:/music:ro
      - ./data/.mpd/playlists:/playlists
      - ./data/.mpd/log:/log
      - ./data/.mpd/config:/user/config
      - ./data/.mpd/db:/db
      - /run/user/${PUID}/pulse:/run/user/${PUID}/pulse
    network_mode: "host"  # Add host mode networking
    restart: unless-stopped
    image: giof71/mpd-alsa
@GioF71
Copy link
Owner

GioF71 commented May 4, 2024

Looks ok... can you post the logs of mpd so I can check the generated file?

docker-compose logs mpd-alsa

Let's also see if mpd cannot open the specified port. The logs should provide the information hopefully

@GioF71
Copy link
Owner

GioF71 commented May 4, 2024

One thing, if you use host networking, port mapping has no effect. You are probably getting the warning from docker-compose I believe

@GioF71
Copy link
Owner

GioF71 commented May 4, 2024

Also check in mympd that the output if effectively enabled

@GioF71
Copy link
Owner

GioF71 commented May 19, 2024

Hello @bonelifer, did you solve the issue?

@bonelifer
Copy link
Author

Sorry haven't had a chance, have been working on revising a website. I'll close this for now and reopen it when I have time. Thanks for getting back to me.

@GioF71
Copy link
Owner

GioF71 commented May 19, 2024

You can leave it open, no worries. I was just asking for an update!

@bonelifer bonelifer reopened this May 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants