【发布时间】:2021-04-07 17:48:44
【问题描述】:
将 elasticbeanstalk 与在 64 位 Amazon Linux 2/5.2.3 上运行的 Node.js 10 结合使用。我在 .ebextensions 文件夹下有一个 packages.config 文件。
packages:
yum:
ImageMagick: []
ImageMagick-devel: []
commands:
01-wget:
command: "wget -O /tmp/ffmpeg.tar.xz http://ffmpeg.org/releases/ffmpeg-4.1.tar.gz"
02-mkdir:
command: "if [ ! -d /opt/ffmpeg ] ; then mkdir -p /opt/ffmpeg; fi"
03-tar:
command: "tar xvf /tmp/ffmpeg.tar.xz -C /opt/ffmpeg"
04-ln:
command: "if [[ ! -f /usr/bin/ffmpeg ]] ; then ln -sf /opt/ffmpeg/ffmpeg-4.1/ffmpeg /usr/bin/ffmpeg; fi"
05-ln:
command: "if [[ ! -f /usr/bin/ffprobe ]] ; then ln -sf /opt/ffmpeg/ffmpeg-4.1/ffprobe /usr/bin/ffprobe; fi"
06-pecl:
command: "if [ `pecl list | grep imagick` ] ; then pecl install -f imagick; fi"
我正在使用 fluent-ffmpeg@2.1.2 模块来保存屏幕截图。
【问题讨论】:
-
您是否检查了 EB 日志文件以获取更详细的错误消息?
-
是的@Marcin
Dec 31 11:41:54 ip-172-31-46-171 web: Cannot process video: Error: Cannot find ffprobe Dec 31 11:41:54 ip-172-31-46-171 web: (node:10094) UnhandledPromiseRejectionWarning: Cannot find ffprobe Dec 31 11:41:54 ip-172-31-46-171 web: (node:10094) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 2)
标签: node.js amazon-web-services ffmpeg amazon-elastic-beanstalk ffprobe