amazon-web-services - 如何在 AWS Elastic Beanstalk 上安装音频波形程序

标签 amazon-web-services amazon-ec2 amazon-elastic-beanstalk

仅供引用......这里的上下文是AWS Elastic Beanstalk .我正在尝试安装 audiowaveform 64 位 Amazon Linux 2015.03 v1.4.3 上的程序(客户 AMI ID 为 ami-6b50291c)。运行这个...👇

$ sudo yum install git cmake libmad-devel libsndfile-devel gd-devel boost-devel

... 成功安装除 libmad-devel 之外的所有软件包和 libsndfile-devel .以下是相关输出...
Failed to set locale, defaulting to C
Loaded plugins: priorities, update-motd, upgrade-helper
amzn-main/2015.03                                                        | 2.1 kB     00:00     
amzn-updates/2015.03                                                     | 2.3 kB     00:00     
Package git-2.1.0-1.38.amzn1.x86_64 already installed and latest version
Package cmake-2.8.12-2.20.amzn1.x86_64 already installed and latest version
No package libmad-devel available.
No package libsndfile-devel available.
Package gd-devel-2.0.35-11.10.amzn1.x86_64 already installed and latest version
Package boost-devel-1.53.0-14.21.amzn1.x86_64 already installed and latest version
Nothing to do

也就是说,这不是音频波形的问题……所有这一切都意味着为 Amazon Linux AMI 启用的存储库没有 libmad-devellibsndfile-devel默认情况下。我想我可能不得不简单地添加我自己的来源。

另外要注意的是没有yum存在适用于 audio waveform 的软件包所以我必须手动构建它。

获取源码...👇
$ git clone https://github.com/bbcrd/audiowaveform.git
$ cd audio waveform

然后构建和安装...👇
$ mkdir build
$ cd build
$ cmake ..
$ make
$ sudo make install

问题 1

在 AWS EB 上……EC2 实例被配置为使用没有上述包的 Amazon 源,即 libmad-devellibsndfile-devel .添加这些包以便它们可供 yum 使用的推荐方法是什么? ?

我强调推荐,因为我觉得改变亚马逊的来源可能不是最好的方法。也没有添加可能与亚马逊的包裹冲突的另一个来源……等等等等……

问题 2

假设我能够安装 libmad-devellibsndfile-devel .我仍然需要手动构建它,因为没有 audiowaveform 的包.在 AWS EB 上,我可以编写一个脚本来执行此操作,因为每个实例正在被实例化……但我觉得这并不理想、速度慢且有点容易出错。有人对我如何做得更好有建议吗?

可能准备一个基于 ami-6b50291c 的已构建的 AMI .想法?

核心目标

我不必使用 audiowaveform ...我的目标实际上是提取某些音频(MP3)的峰值点。我将把它设置为一个单独的问题。

最佳答案

Amazon Elastic Beanstalk 在您可以安装哪些软件方面往往受到很大限制。我通过 dockerizing 我的应用程序环境解决了这个问题。现在即使在 Elastic Beanstalk 上也可以做到这一点。

Learn more about Elastic Beanstalk's support for Docker ...

AWS Elastic Beanstalk makes it easy for you to deploy and manage applications in the AWS cloud. After you upload your application, Elastic Beanstalk will provision, monitor, and scale capacity (Amazon EC2 instances), while also load balancing incoming requests across all of the healthy instances.

Docker automates the deployment of applications in the form of lightweight, portable, self-sufficient containers that can run in a variety of environments. Containers can be populated from pre-built Docker images or from a simple recipe known as a Dockerfile.

Docker’s container-based model is very flexible. You can, for example, build and test a container locally and then upload it to the AWS Cloud for deployment and scalability. Docker’s automated deployment model ensures that the runtime environment for your application is always properly installed and configured, regardless of where you decide to host the application.



这样……您可以在容器中做任何您想做的事情,并且该容器将在 Amazon Linux AMI 实例提供的内核上运行(显然是完全隔离的)。

关于amazon-web-services - 如何在 AWS Elastic Beanstalk 上安装音频波形程序,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31287024/

相关文章:

amazon-web-services - AWS Lambda 请求者付费模式

Django Celery 无法连接到 EC2 上的远程 RabbitMQ

python - 如何运行作为我在 AWS SSH session 中上传的应用程序的一部分的 Python 脚本?

amazon-web-services - 当文件中明确指定了 executionRoleArn 时,为什么我会收到有关未指定 executionRoleArn 的错误?

amazon-web-services - Neptune 加载程序 FROM_OR_TO_VERTEX_ARE_MISSING

node.js - 弹性 beantalk 上的 npm 全局安装

amazon-web-services - 使用 Google Cloud Pub/Sub 时如何在 AWS/SQS 中实现 "locked"功能?

amazon-ec2 - 如何使用 API 获取在我的 Amazon EC2 账户下运行的服务器实例的数量

amazon-web-services - CodeDeploy找不到我的AWS Lambda函数

hadoop - 在 AMAZON EMR 上运行 yarn 应用程序