Page 1 of 1

[Solved] yams stop - Failed to stop services

Posted: Wed Jul 23, 2025 12:33 pm
by labs

Hi all. Yesterday I fully set up the media centre using yams, all is working well until the point I started faffing around trying to add a new volume to expand the storage, which worked and did not work.

The procedure was editing the volumes bit in the docker-compose file, stopping the service, saving the file then re-starting the services. At some point I miss alt-tabbed and I believe I added (or removed) some wrong character to the file rendering any "yams start" or "yams stop" useless, which return the following to me:

Code: Select all

service "jellyfin" refers to undefined volume jellyfin: invalid compose project
Failed to stop services

Everything works. Jellyfin is streaming to devices, sonarr and radarr are downloading, and vpn checks are good.

The jellyfin code bit looks like this: - As I am new to yams, ofc, I don't have a backup of the compose file therefore I don't know how it should look like.

Code: Select all

services:
  # jellyfin is used to serve your media to the client devices
  jellyfin:
    image: lscr.io/linuxserver/${MEDIA_SERVICE}
    container_name: ${MEDIA_SERVICE}
    #network_mode: host # plex
    environment:
      - PUID=${PUID}
      - PGID=${PGID}
      - VERSION=docker
    volumes:
      - /etc/localtime:/etc/localtime:ro
      - ${MEDIA_DIRECTORY}:/data
      - ${INSTALL_DIRECTORY}:/config
      - ${MEDIA_SERVICE}:/config
    ports: # plex
      - 8096:8096 # plex
    restart: unless-stopped

Any ideas about what could be causing this error?

Thank you in advance.


Re: yams stop - Failed to stop services

Posted: Wed Jul 23, 2025 12:53 pm
by rogs

Hey @labs!

I have one question: What does - ${MEDIA_SERVICE}:/config do? You are mounting a volume twice on the same directory, that's most likely your problem.

Cheers!

Roger.


Re: yams stop - Failed to stop services

Posted: Wed Jul 23, 2025 12:56 pm
by labs

Key @rogs, I was about to edit the post with the solution. I found the original compose file here https://gitlab.com/rogs/yams/-/blob/mas ... type=heads then compared both.
Apparently I deleted part of the

Code: Select all

- ${INSTALL_DIRECTORY}/config/${MEDIA_SERVICE}:/config

it was just

Code: Select all

- ${INSTALL_DIRECTORY}/config

Adding the rest of the string "/${MEDIA_SERVICE}:/config" brought everything back as normal. Now I can stop and start the services.

It now looks like this

Code: Select all

volumes:
      - /etc/localtime:/etc/localtime:ro
      - ${MEDIA_DIRECTORY}:/data
      - ${INSTALL_DIRECTORY}/config/${MEDIA_SERVICE}:/config

TIA


Re: yams stop - Failed to stop services

Posted: Wed Jul 23, 2025 1:05 pm
by rogs

Yes, that's the solution! I'm glad you were able to fix it :mrgreen:

If you want to add more services to YAMS you can use this documentation: https://yams.media/advanced/add-your-own-containers/

I'll mark this issue as solved!

Cheers!

Roger.