Local TTS options inside Docker

Tags: #<Tag:0x00007f77fec13b80>

Hi All,

I recently re-built my setup and moved to hosting all my HA related stuff in Docker. This has mostly been great, though I’m still ironing out a few issues. One of these is that my TTS announcements no longer work due to PicoTTS not being available in the Docker image.

As I see it there are a couple of options to fix this:

  1. Build a custom HASS image based on the official one, but including PicoTTS
  2. Install another local TTS option (ideally via Docker), such as MaryTTS that would be available over the network

I’m not all that enthused about option 1 due to the need to re-build the image for every new HASS release. Option 2 just adds another thing to maintain.

Has anyone got any other ideas? Has anyone found another way to get PicoTTS working inside the Docker container?

(Note: I’m not at all interested in non-local i.e. cloud based TTS, hence why it’s not included in the list. Please don’t suggest this as an alternative :slight_smile:).

Thanks in advance.

1 Like

I use a marytts container. I’m not sure what you mean by ‘another thing to maintain’ but it’s just a few lines in my docker-compose and forget about it.

I meant another thing to keep updated and monitor that it’s working.

Which marytts container are you using? I didn’t find an official one in my searches.

I’m using the silversniper/marytts container, my docker-compose…

link removed

Then connect homeassistant to it…

  platform: marytts
  language: 'en-GB'
  host: !secret host_ip

And then that’s it really.

As for maintenance, I upgrade everything all at the same time using a bash script, haven’t had a single issue with MaryTTS since I started using it.

The bash script is here…

link removed

Upgrades the system, upgrades all the docker containers, restarts them all and cleans up. I do that pretty much every time homeassistant is updated.

Hope this helps.

Yes, that does help, thank you. Good to hear that marytts is pretty reliable. I think I’ll give that a try.

Nice work with the bash script, not sure why I didn’t think of that. Too busy trying to make it ‘fully’ automated I guess!

1 Like

hi, I’ve serched for you container but it seems that no longer exist. Can you tell me where to find it?


1 Like

Thank you! but there’s no documentation. How can I add more voices? Can you give me some more hint please?

You can check out my post on how I set it up:


Hope this helps!

Thank you! I will try to follow your instructions!

OK I installed it and can use it with the web page.

But can’t test it with HA.

I call service “tts.marytts_say” with this service data

{“entity_id”: “media_player.corridoio”, “message”:“testing one, two, three”}

But I receive error 500

Here’s my config for Marytts.

 - platform: marytts

Any hint?

Have a look at the logs from your marytts container with docker logs <container name>. Post them here if you have trouble working it out from that.