Android Firebase应用程序分发-服务凭据文件不存在.请检查服务凭证路径,然后重试 [英] Android Firebase app distribution - Service credentials file does not exist. Please check the service credentials path and try again
问题描述
我正在尝试从Crashlytics Beta迁移到Firebase App Distribution.中间是CircleCi.
I'm trying to migrate from Crashlytics Beta to Firebase App Distribution. CircleCi in the Middle.
CircleCi的构建失败,并出现以下错误:
The build failes in CircleCi with the following error:
- 出了什么问题:任务':FiverrApp:appDistributionUploadRelease'的执行失败.服务凭证文件不存在.请检查服务凭证路径,然后重试
这是我配置serviceCredentialsFile变量的方式在我的build.gradle中:
Here is how i'm configuring serviceCredentialsFile variable In my build.gradle:
release {
buildConfigField "boolean", "FORCE_LOGS", "true"
firebaseAppDistribution {
releaseNotes="Notes\n" + getCommitMessages()
groups="android-testers"
serviceCredentialsFile="/api-project-xxx-yyy.json"
}
}
文件api-project-xxx-yyy.json与build.gradle文件位于同一文件夹中.我也尝试过:
the file api-project-xxx-yyy.json is in the same folder with build.gradle file. I've also tried:
serviceCredentialsFile="api-project-xxx-yyy.json"
serviceCredentialsFile='api-project-xxx-yyy.json'
仍然没有运气...如果有人可以帮助我,将不胜感激.
And still no luck... Would appreciate if someone can help me.
推荐答案
尝试使用 $ rootDir
获取路径.例如,如果您将凭据文件 api-project-xxx-yyy.json
传递到根目录,则可以采用以下方式:
Try to use $rootDir
to get a path. For example if you pass you credentials file api-project-xxx-yyy.json
to root directory than you can take it something like this:
firebaseAppDistribution {
...
serviceCredentialsFile="$rootDir/api-project-xxx-yyy.json"
}
这篇关于Android Firebase应用程序分发-服务凭据文件不存在.请检查服务凭证路径,然后重试的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!