【发布时间】:2020-04-30 12:03:05
【问题描述】:
我正在使用 Azure Batch。我正在编写一个将文件上传到 Azure 存储帐户的 c# 应用程序。然后代码创建一个池和任务 - 除了一件事之外,这一切都很好。该任务有一个命令行,该命令行在池中的每个节点 (VM) 上执行,以在每个节点上运行 c# 应用程序。该应用程序已成功下载到节点,但我认为我的 exe 路径在代码中是错误的..
const string appPackageId = "ffmpeg";
const string appPackageVersion = "6.0";
...
string taskCommandLine = String.Format("cmd /c {0}\\ffmpeg\\bin\\{1}.exe -i {2} {3}", appPath, appPackageId, inputMediaFile, outputMediaFile);
// Create a cloud task (with the task ID and command line) and add it to the task list
CloudTask task = new CloudTask(taskId, taskCommandLine);
task.ResourceFiles = new List<ResourceFile> { inputFiles[i] };
...
如何将 taskCommandLine 设置为 VM 上 exe 的正确路径?
我知道在 VM 上创建了文件夹,但我不确定 exe 和支持文件下载到哪里...? (必须有某种文件/文件夹结构)
问候 伊恩
【问题讨论】:
标签: c# azure azure-batch