我已经通过libav-tools安装了一个安装了ffmpeg的应用程序.该应用程序启动没有问题,但当fluent-ffmpeg npm模块尝试执行ffmpeg命令时发生问题,但未找到该命令.当我想检查ffmpeg的版本和图像中设置的linux发行版时,我使用了sudo docker exec -it c44f29d30753 "lsb_release -a"命令,但它给出了以下错误:OCI runtime exec failed: exec failed: container_linux.go:296: starting container process caused "exec: \"lsb_release -a\": executable file not found in $PATH": unknown
然后我意识到它给了我与我尝试在图像或容器内运行的所有命令相同的错误.
OCI runtime exec failed: exec failed: container_linux.go:296: starting container process caused "exec: \"ffmpeg -a\": executable file not found in $PATH": unknown
Run Code Online (Sandbox Code Playgroud)
这是我的Dockerfile:
FROM ubuntu:xenial
FROM node
RUN apt-get -y update
RUN apt-get --yes install libav-tools
RUN mkdir -p /usr/src/app
WORKDIR /usr/src/app
COPY package.json /usr/src/app
RUN npm install
COPY …Run Code Online (Sandbox Code Playgroud) 我已按照React Native的Android设置页面中显示的确切说明操作并运行代码,而不会遇到任何问题.今天,我正在尝试运行完全相同的代码.它说,正如我在下面提供的"构建是成功的",但我看到只有android/build/intermediates/dex-cache/cache.xml文件,并没有更多的android/builid文件夹.还有如下图所示的错误.我想弄清楚出了什么问题.这是终端输出:
ugur@ugur-Lenovo-ideapad-510-15IKB:~/Desktop/tutorials/react native tutorial/NewPro$ react-native run-android
Scanning 559 folders for symlinks in /home/ugur/Desktop/tutorials/react native tutorial/NewPro/node_modules (2ms)
Starting JS server...
Building and installing the app on the device (cd android && ./gradlew installDebug)...
Incremental java compilation is an incubating feature.
:app:preBuild UP-TO-DATE
:app:preDebugBuild UP-TO-DATE
:app:checkDebugManifest
:app:preReleaseBuild UP-TO-DATE
:app:prepareComAndroidSupportAppcompatV72301Library UP-TO-DATE
:app:prepareComAndroidSupportSupportV42301Library UP-TO-DATE
:app:prepareComFacebookFbuiTextlayoutbuilderTextlayoutbuilder100Library UP-TO-DATE
:app:prepareComFacebookFrescoDrawee101Library UP-TO-DATE
:app:prepareComFacebookFrescoFbcore101Library UP-TO-DATE
:app:prepareComFacebookFrescoFresco101Library UP-TO-DATE
:app:prepareComFacebookFrescoImagepipeline101Library UP-TO-DATE
:app:prepareComFacebookFrescoImagepipelineBase101Library UP-TO-DATE
:app:prepareComFacebookFrescoImagepipelineOkhttp3101Library UP-TO-DATE
:app:prepareComFacebookReactReactNative0471Library UP-TO-DATE
:app:prepareComFacebookSoloaderSoloader010Library UP-TO-DATE
:app:prepareOrgWebkitAndroidJscR174650Library UP-TO-DATE
:app:prepareDebugDependencies …Run Code Online (Sandbox Code Playgroud) 刚刚安装了 awscli,但我的配置有问题。
当我这样做时aws configure:
AWS Access Key ID [None]: "ACCESS KEY HERE"
AWS Secret Access Key [None]: "SECRET KEY HERE"
Default region name [None]: us-east-1
Default output format [None]:
[Errno 13] Permission denied: '/home/ugurkaya/.aws/credentials'
Run Code Online (Sandbox Code Playgroud)
我也尝试过,chmod +x /home/ugurkaya/.aws/credentials但没有帮助。任何想法为什么我有这个问题?
编辑:ls -l ~/.aws/credentials输出:
-rwx--x--x 1 root root 116 jul 13 18:12 /home/ugurkaya/.aws/credentials
下面的代码按预期在一秒内记录"hello world".
function moveOneStep() {
return new Promise((res, rej) => {
setTimeout(() => {
res(console.log('Hello world!'))
}, 1000)
})
}
async function main() {
await moveOneStep();
await moveOneStep();
await moveOneStep();
await moveOneStep();
}
Run Code Online (Sandbox Code Playgroud)
考虑到函数的return值async对应resolve于promises中函数返回的函数,为什么下面的代码不会输出相同的结果,而是立即记录所有'hello world':
async function moveOneStepAsync() {
setTimeout(() => {
return console.log('Hello world!');
}, 1000);
}
async function main() {
await moveOneStepAsync();
await moveOneStepAsync();
await moveOneStepAsync();
await moveOneStepAsync();
}
Run Code Online (Sandbox Code Playgroud) async-await ×1
aws-cli ×1
babel ×1
docker ×1
ffmpeg ×1
javascript ×1
native ×1
react-native ×1
reactjs ×1