mdhiggins / sonarr-sma

Sonarr docker based on linuxserver/sonarr with SMA built in using python3
MIT License
38 stars 18 forks source link

Unable to locate package libnppig10 in build #27

Closed preacher65 closed 2 years ago

preacher65 commented 2 years ago

Hi, not sure if I'm doing something wrong, but just tried to rebuild my container which has the following in the docker-compose file:

    build:
      context: https://github.com/mdhiggins/sonarr-sma.git#build
      args:
        - ffmpeg_tag=4.3.2-vaapi1804
        - sonarr_tag=latest

The command I'm using to build is docker-compose build --force-rm --no-cache

This has always previously worked, but I now get the following error:

Get:22 http://archive.ubuntu.com/ubuntu bionic-security/multiverse amd64 Packages [26.7 kB]
Fetched 12.3 MB in 4s (3,009 kB/s)
Reading package lists...
W: Conflicting distribution: http://download.mono-project.com/repo/ubuntu bionic/snapshots/5.20 InRelease (expected bionic/snapshots/5.20 but got bionic)
Reading package lists...
Building dependency tree...
Reading state information...
E: Unable to locate package libnppig10
E: Unable to locate package libnppicc10
E: Unable to locate package libnppidei10
Removing intermediate container f43da793117d
The command '/bin/sh -c apt-get update &&   apt-get install -y     git     wget     python3     python3-pip     libnppig10     libnppicc10     libnppidei10 &&   mkdir ${SMA_PATH} &&   git clone https://github.com/mdhiggins/sickbeard_mp4_automator.git ${SMA_PATH} &&   python3 -m pip install --user --upgrade pip &&   python3 -m pip install --user virtualenv &&   python3 -m virtualenv ${SMA_PATH}/venv &&   ${SMA_PATH}/venv/bin/pip install -r ${SMA_PATH}/setup/requirements.txt &&   chgrp users /usr/local/bin/ffmpeg &&   chgrp users /usr/local/bin/ffprobe &&   chmod g+x /usr/local/bin/ffmpeg &&   chmod g+x /usr/local/bin/ffprobe &&   apt-get purge --auto-remove -y &&   apt-get clean &&   rm -rf     /tmp/*     /var/lib/apt/lists/*     /var/tmp/*' returned a non-zero code: 100
ERROR: Service 'sonarr' failed to build

The "Conflicting distribution" part has been happening for a while, but so far appears to be benign. It's the "Unable to locate package" lines that seem to be causing the problem, and I assume causing the apt-get install for libnppig10, libnppicc10 and libnppidei10 to fail. Had a bit of a try at troubleshooting, but to be honest I have no idea whether it's an issue with my build process, the linuxserver container, the ffmpeg one, or the sma build scripts.

Any advice appreciated.

mdhiggins commented 2 years ago

Just pushed an update to address this

Rather than forcing those packages which aren't needed in all scenarios I've included an extra_packages argument that allows people to specify if they need to install special dependencies via apt-get

ARG extra_packages
...
  apt-get update && \
  apt-get install -y \
    git \
    wget \
    python3 \
    python3-pip \
    ${extra_packages} && \