stuckj / subsonic-docker

Docker container for subsonic
MIT License
4 stars 5 forks source link

bash: line 1: -Dsubsonic.defaultMusicFolder=/var/music: No such file or directory #7

Open pscriptos opened 1 month ago

pscriptos commented 1 month ago

Hello,

I have a now very old Subsonic installation, but not as a Docker. Today I discovered your Docker image.

I have written a docker-compose file. Unfortunately, when I start the Docker, I quickly get the message that the directory ‘/var/music’ does not exist.

➜  sub docker-compose up
WARN[0000] /docker-compose/sub/docker-compose.yaml: `version` is obsolete
[+] Running 2/2
 ✔ Container subsonic-db   Created                                                                                                                                                                      0.0s
 ✔ Container subsonic-app  Recreated                                                                                                                                                                    0.1s
Attaching to subsonic-app, subsonic-db
subsonic-db   | The files belonging to this database system will be owned by user "postgres".
subsonic-db   | This user must also own the server process.
subsonic-db   |
subsonic-db   | The database cluster will be initialized with locale "en_US.utf8".
subsonic-db   | The default database encoding has accordingly been set to "UTF8".
subsonic-db   | The default text search configuration will be set to "english".
subsonic-db   |
subsonic-db   | Data page checksums are disabled.
subsonic-db   |
subsonic-db   | fixing permissions on existing directory /var/lib/postgresql/data ... ok
subsonic-db   | creating subdirectories ... ok
subsonic-db   | selecting dynamic shared memory implementation ... posix
subsonic-db   | selecting default "max_connections" ... 100
subsonic-db   | selecting default "shared_buffers" ... 128MB
subsonic-db   | selecting default time zone ... Etc/UTC
subsonic-db   | creating configuration files ... ok
subsonic-db   | running bootstrap script ... ok
subsonic-app  | useradd warning: subsonic's uid 1000 is greater than SYS_UID_MAX 999
subsonic-app  | bash: line 1: -Dsubsonic.defaultMusicFolder=/var/music: No such file or directory
subsonic-db   | performing post-bootstrap initialization ... ok
subsonic-app exited with code 0
subsonic-app  | bash: line 1: -Dsubsonic.defaultMusicFolder=/var/music: No such file or directory
subsonic-app exited with code 0
subsonic-app  | bash: line 1: -Dsubsonic.defaultMusicFolder=/var/music: No such file or directory
subsonic-app exited with code 127
subsonic-app  | bash: line 1: -Dsubsonic.defaultMusicFolder=/var/music: No such file or directory
subsonic-db   | syncing data to disk ... ok
subsonic-db   |
subsonic-db   |
subsonic-db   | Success. You can now start the database server using:
subsonic-db   |
subsonic-db   |     pg_ctl -D /var/lib/postgresql/data -l logfile start
subsonic-db   |
subsonic-db   | initdb: warning: enabling "trust" authentication for local connections
subsonic-db   | initdb: hint: You can change this by editing pg_hba.conf or using the option -A, or --auth-local and --auth-host, the next time you run initdb.
subsonic-db   | waiting for server to start....2024-10-05 19:15:57.915 UTC [49] LOG:  starting PostgreSQL 17.0 (Debian 17.0-1.pgdg120+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 12.2.0-14) 12.2.0, 64-bit
subsonic-db   | 2024-10-05 19:15:57.921 UTC [49] LOG:  listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
subsonic-db   | 2024-10-05 19:15:57.943 UTC [52] LOG:  database system was shut down at 2024-10-05 19:15:55 UTC
subsonic-db   | 2024-10-05 19:15:57.953 UTC [49] LOG:  database system is ready to accept connections
subsonic-db   |  done
subsonic-db   | server started
subsonic-db   | CREATE DATABASE
subsonic-db   |
subsonic-db   |
subsonic-db   | /usr/local/bin/docker-entrypoint.sh: ignoring /docker-entrypoint-initdb.d/*
subsonic-db   |
subsonic-db   | 2024-10-05 19:15:58.137 UTC [49] LOG:  received fast shutdown request
subsonic-db   | waiting for server to shut down....2024-10-05 19:15:58.143 UTC [49] LOG:  aborting any active transactions
subsonic-db   | 2024-10-05 19:15:58.146 UTC [49] LOG:  background worker "logical replication launcher" (PID 55) exited with exit code 1
subsonic-db   | 2024-10-05 19:15:58.147 UTC [50] LOG:  shutting down
subsonic-db   | 2024-10-05 19:15:58.153 UTC [50] LOG:  checkpoint starting: shutdown immediate
subsonic-app  | bash: line 1: -Dsubsonic.defaultMusicFolder=/var/music: No such file or directory
subsonic-db   | 2024-10-05 19:15:58.934 UTC [50] LOG:  checkpoint complete: wrote 921 buffers (5.6%); 0 WAL file(s) added, 0 removed, 0 recycled; write=0.029 s, sync=0.730 s, total=0.788 s; sync files=301, longest=0.010 s, average=0.003 s; distance=4238 kB, estimate=4238 kB; lsn=0/1908980, redo lsn=0/1908980
subsonic-db   | 2024-10-05 19:15:58.944 UTC [49] LOG:  database system is shut down
subsonic-db   |  done
subsonic-db   | server stopped
subsonic-db   |
subsonic-db   | PostgreSQL init process complete; ready for start up.
subsonic-db   |
subsonic-db   | 2024-10-05 19:15:59.075 UTC [1] LOG:  starting PostgreSQL 17.0 (Debian 17.0-1.pgdg120+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 12.2.0-14) 12.2.0, 64-bit
subsonic-db   | 2024-10-05 19:15:59.075 UTC [1] LOG:  listening on IPv4 address "0.0.0.0", port 5432
subsonic-db   | 2024-10-05 19:15:59.075 UTC [1] LOG:  listening on IPv6 address "::", port 5432
subsonic-db   | 2024-10-05 19:15:59.091 UTC [1] LOG:  listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
subsonic-db   | 2024-10-05 19:15:59.106 UTC [65] LOG:  database system was shut down at 2024-10-05 19:15:58 UTC
subsonic-db   | 2024-10-05 19:15:59.116 UTC [1] LOG:  database system is ready to accept connections
subsonic-app  | bash: line 1: -Dsubsonic.defaultMusicFolder=/var/music: No such file or directory
subsonic-app  | bash: line 1: -Dsubsonic.defaultMusicFolder=/var/music: No such file or directory
subsonic-app  | bash: line 1: -Dsubsonic.defaultMusicFolder=/var/music: No such file or directory
subsonic-app  | bash: line 1: -Dsubsonic.defaultMusicFolder=/var/music: No such file or directory
^CGracefully stopping... (press Ctrl+C again to force)
[+] Stopping 2/2
 ✔ Container subsonic-app  Stopped                                                                                                                                                                      0.0s
 ✔ Container subsonic-db   Stopped

What went wrong here?

This is my Docker-Compose.yaml.

version: '3.8'

services:
  subsonic-db:
  # url: https://hub.docker.com/r/stuckj/subsonic
    image: postgres:latest
    container_name: subsonic-db
    networks:
      dockernet:
        ipv4_address: 172.16.0.170
    environment:
      - POSTGRES_DB=subsonicdb
      - POSTGRES_USER=subsonic
      - POSTGRES_PASSWORD=deinPasswortHier
    volumes:
      - ./data/database:/var/lib/postgresql/data
    restart: unless-stopped

  subsonic-app:
    image: stuckj/subsonic:latest
    container_name: subsonic-app
    depends_on:
      - subsonic-db
    environment:
      - SUBSONIC_PORT=4040
      - SUBSONIC_HTTPS_PORT=4443
      - SUBSONIC_CONTEXT_PATH=/
      - SUBSONIC_HOME=/var/subsonic
      - SUBSONIC_HOST=0.0.0.0
      - SUBSONIC_MAX_MEMORY=512
      - SUBSONIC_DB=jdbc:postgresql://subsonic-db:5432/subsonicdb?user=subsonic&password=deinPasswortHier
      - SUBSONIC_UID=1000
      - SUBSONIC_GID=1000
      - SUBSONIC_DEFAULT_MUSIC_FOLDER=/var/music
      - SUBSONIC_DEFAULT_PODCAST_FOLDER=/var/music/Podcast
      - SUBSONIC_DEFAULT_PLAYLIST_FOLDER=/var/playlists
    ports:
      - "4040:4040"
      - "4443:4443"
    networks:
      dockernet:
        ipv4_address: 172.16.0.171
    volumes:
      - ./data/music:/var/music
      - ./data/playlists:/var/playlists
      - ./data/subsonic:/var/subsonic
    restart: unless-stopped

networks:
  dockernet:
    external: true

Can anyone say anything about it? The User with ID 1000 exist. Many thanks for your work!

Patrick

pscriptos commented 2 weeks ago

can you say anythink about this? Thank you.