dockerfile apt-get install ffmpeg неудовлетворенные зависимости - PullRequest
0 голосов
/ 08 июля 2020

У меня есть Dockerfile , который выглядит так:

FROM node:carbon
VOLUME ["/root"]
ADD setup-ffmpeg.sh /root
RUN /root/setup-ffmpeg.sh
# Create app directory
WORKDIR /usr/src/app
# Install app dependencies
# A wildcard is used to ensure both package.json AND package-lock.json are copied
# where available (npm@5+)
COPY package*.json ./
RUN npm install
# If you are building your code for production
# RUN npm install --only=production
# Bundle app source
COPY . .
EXPOSE 8080
CMD [ "npm", "start" ]

который пытается запустить файл setup-ffmpeg. sh:

#!/usr/bin/env bash
echo 'deb http://www.deb-multimedia.org jessie main non-free' >> /etc/apt/sources.list
echo 'deb-src http://www.deb-multimedia.org jessie main non-free' >> /etc/apt/sources.list
apt-get update
apt-get install -y --force-yes deb-multimedia-keyring
apt-get remove -y --force-yes ffmpeg
apt-get install -y --force-yes build-essential libmp3lame-dev libvorbis-dev libtheora-dev     libspeex-dev yasm pkg-config libfaac-dev libx264-dev libav-tools 
echo "ffmpeg time"
apt-get install ffmpeg 

Я использую Ubuntu 20.04 LTS и пытаюсь запустить этот Dockerfile из терминала с помощью команды:

docker build -t alien35/node-web-app .

Это вызывает ошибку при достижении части ffmpeg:

Sending build context to Docker daemon  9.793MB
Step 1/10 : FROM node:carbon
 ---> 8eeadf3757f4
Step 2/10 : VOLUME ["/root"]
 ---> Using cache
 ---> 3658672462de
Step 3/10 : ADD setup-ffmpeg.sh /root
 ---> c9c192aa97c5
Step 4/10 : RUN /root/setup-ffmpeg.sh
 ---> Running in b9240ac8d351
Ign:1 http://deb.debian.org/debian stretch InRelease
Get:2 http://security.debian.org/debian-security stretch/updates InRelease [53.0 kB]
Get:3 http://deb.debian.org/debian stretch-updates InRelease [93.6 kB]
Get:4 http://deb.debian.org/debian stretch Release [118 kB]
Get:5 http://deb.debian.org/debian stretch Release.gpg [2410 B]
Get:6 http://security.debian.org/debian-security stretch/updates/main amd64 Packages [529 kB]
Get:7 http://deb.debian.org/debian stretch-updates/main amd64 Packages [28.2 kB]
Get:8 http://deb.debian.org/debian stretch/main amd64 Packages [7083 kB]
Get:9 http://www.deb-multimedia.org jessie InRelease [24.6 kB]
Ign:9 http://www.deb-multimedia.org jessie InRelease
Get:10 http://www.deb-multimedia.org jessie/main Sources [60.8 kB]
Get:11 http://www.deb-multimedia.org jessie/non-free Sources [2480 B]
Get:12 http://www.deb-multimedia.org jessie/main amd64 Packages [82.8 kB]
Get:13 http://www.deb-multimedia.org jessie/non-free amd64 Packages [1776 B]
Fetched 8080 kB in 2s (3402 kB/s)
Reading package lists...
W: GPG error: http://www.deb-multimedia.org jessie InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 5C808C2B65558117
W: The repository 'http://www.deb-multimedia.org jessie InRelease' is not signed.
Reading package lists...
Building dependency tree...
Reading state information...
The following NEW packages will be installed:
  deb-multimedia-keyring
0 upgraded, 1 newly installed, 0 to remove and 56 not upgraded.
Need to get 10.7 kB of archives.
After this operation, 25.6 kB of additional disk space will be used.
WARNING: The following packages cannot be authenticated!
  deb-multimedia-keyring
Get:1 http://www.deb-multimedia.org jessie/main amd64 deb-multimedia-keyring all 2016.8.1 [10.7 kB]
debconf: delaying package configuration, since apt-utils is not installed
Fetched 10.7 kB in 0s (23.3 kB/s)
Selecting previously unselected package deb-multimedia-keyring.
(Reading database ... 29962 files and directories currently installed.)
Preparing to unpack .../deb-multimedia-keyring_2016.8.1_all.deb ...
Unpacking deb-multimedia-keyring (2016.8.1) ...
Setting up deb-multimedia-keyring (2016.8.1) ...
W: --force-yes is deprecated, use one of the options starting with --allow instead.
W: --force-yes is deprecated, use one of the options starting with --allow instead.
Reading package lists...
Building dependency tree...
Reading state information...
Package 'ffmpeg' is not installed, so not removed
0 upgraded, 0 newly installed, 0 to remove and 56 not upgraded.
Reading package lists...
Building dependency tree...
Reading state information...
pkg-config is already the newest version (0.29-4+b1).
pkg-config set to manually installed.
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 libav-tools : Depends: ffmpeg (= 10:2.6.9-dmo1+deb8u2) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
ffmpeg time
Reading package lists...
Building dependency tree...
Reading state information...
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 ffmpeg : Depends: libavcodec56 (>= 10:2.6.9) but it is not going to be installed
          Depends: libavdevice56 (>= 10:2.6.9) but it is not going to be installed
          Depends: libavfilter5 (>= 10:2.6.9) but it is not going to be installed
          Depends: libavformat56 (>= 10:2.6.9) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
The command '/bin/sh -c /root/setup-ffmpeg.sh' returned a non-zero code: 100

Я попытался добавить зависимости к apt-get install в моем Dockerfile, а также -f в команду ffmpeg, но я все еще получаю эту ошибку

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...