从2月14号开始,上传AppStore会碰到:Failed to locate or generate matching

    文/没故事的卓同学(简书作者)
   原文链接:http://www.jianshu.com/p/cda1790ea317

从2月14号开始,上传AppStore时可能会碰到这个问题:

Failed to locate or generate matching signing assets
Xcode attempted to locate or generate matching signing assets and failed to do so because of the following issues.
Missing iOS Distribution signing identity for ... Xcode can request one for you.

截图如下:

原因是Apple World Wide Developer Relations Certificate Authority的过期时间是2016年2月14。苹果的回答如下:

Thanks for bringing this to the attention of the community and apologies for the issues you’ve been having. This issue stems from having a copy of the expired WWDR Intermediate certificate in both your System and Login keychains. To resolve the issue, you should first download and install the new WWDR intermediate certificate (by double-clicking on the file). Next, in the Keychain Access application, select the System keychain. Make sure to select “Show Expired Certificates” in the View menu and then delete the expired version of the Apple Worldwide Developer Relations Certificate Authority Intermediate certificate (expired on February 14, 2016). Your certificates should now appear as valid in Keychain Access and be available to Xcode for submissions to the App Store.

简单的说就是颁发开发者证书的根证书过期了。如果这个时候你打开keychain看你的发布证书会是这样的:

就是这个Apple World Wide Developer Relations Certificate Authority过期了,所以这个颁发的证书都不能使用了。

现在来说下解决方案:

1.打开keychain(钥匙串),在登录和系统中找到过期的 Apple World Wide Developer Relation Certification Authority,然后删除它

注意在keychain显示菜单下,设置成显示过期证书

2.下载这个链接里的AppleWWDRCA.cer的证书到本地

3.记得要把系统钥匙串的设置权限打开

4.把AppleWWDRCA.cer安装到登录和系统中

设置成功后就可以了。查看下你的发布证书是否已经正常了。

欢迎关注我的微博:@没故事的卓同学

相关链接:

http://stackoverflow.com/questions/32821189/xcode-7-error-missing-ios-distribution-signing-identity-for
考虑柔性负荷的综合能源系统低碳经济优化调度【考虑碳交易机制】(Matlab代码实现)内容概要:本文围绕“考虑柔性负荷的综合能源系统低碳经济优化调度”展开,重点研究在碳交易机制下如何实现综合能源系统的低碳化与经济性协同优化。通过构建包含风电、光伏、储能、柔性负荷等多种能源形式的系统模型,结合碳交易成本与能源调度成本,提出优化调度策略,以降低碳排放并提升系统运行经济性。文中采用Matlab进行仿真代码实现,验证了所提模型在平衡能源供需、平抑可再生能源波动、引导柔性负荷参与调度等方面的有效性,为低碳能源系统的设计与运行提供了技术支撑。; 适合人群:具备一定电力系统、能源系统背景,熟悉Matlab编程,从事能源优化、低碳调度、综合能源系统等相关领域研究的研究生、科研人员及工程技术人员。; 使用场景及目标:①研究碳交易机制对综合能源系统调度决策的影响;②实现柔性负荷在削峰填谷、促进可再生能源消纳中的作用;③掌握基于Matlab的能源系统建模与优化求解方法;④为实际综合能源项目提供低碳经济调度方案参考。; 阅读建议:建议读者结合Matlab代码深入理解模型构建与求解过程,重点关注目标函数设计、约束条件设置及碳交易成本的量化方式,可进一步扩展至多能互补、需求响应等场景进行二次开发与仿真验证。
### GitLab Runner 权限问题分析 当遇到 `failed to locate executable` 或者 `permission denied` 的错误时,这通常表明 GitLab Runner 在尝试运行某个命令或脚本时遇到了权限不足的问题。以下是可能的原因以及解决方案: #### 可能原因 1. **Runner 用户权限不足**: 如果 GitLab Runner 使用的是低权限用户(如 `gitlab-runner`),而目标可执行文件需要更高的权限,则会触发此错误。 2. **文件路径配置不正确**: 配置中的可执行文件路径可能指向了一个不存在或者不可访问的位置。 3. **文件权限设置不当**: 文件本身缺少必要的执行权限。 --- ### 解决方案 #### 1. 检查并修复文件权限 确保目标可执行文件具有正确的权限。可以通过以下命令检查和修改文件权限: ```bash ls -l /path/to/executable chmod +x /path/to/executable ``` 如果文件位于 Docker 容器内部,则还需要确认容器内的文件权限是否正确[^1]。 #### 2. 修改 Runner 执行用户 默认情况下,GitLab Runner 使用 `gitlab-runner` 用户来执行任务。可以将其更改为更高权限的用户(如 root)。通过编辑 `/etc/gitlab-runner/config.toml` 文件实现: ```toml [[runners]] executor = "shell" [runners.custom] command = ["sudo", "/bin/bash"] ``` 注意:更改用户可能会带来安全风险,请谨慎操作[^2]。 #### 3. 确认配置文件无误 打开 `/etc/gitlab-runner/config.toml` 并验证其中定义的路径是否有效。例如: ```toml [[runners]] name = "example-runner" url = "https://gitlab.com/" token = "your_token_here" executor = "docker" [runners.docker] image = "alpine:latest" privileged = true ``` 特别关注 `[runners.docker.privileged]` 参数,启用该参数允许容器拥有更多权限[^3]。 #### 4. 调试日志排查 增加调试模式可以帮助定位具体问题所在。启动 Runner 时加入 `-debug` 标记: ```bash gitlab-runner run --debug ``` 查看输出的日志信息以进一步缩小范围[^4]。 --- ### 示例代码调整 假设问题是由于 Docker 中未赋予足够的权限引起,可以在 `.gitlab-ci.yml` 文件中显式声明特权选项: ```yaml stages: - build build_job: stage: build script: - echo "Running with elevated privileges..." services: - docker:dind variables: DOCKER_DRIVER: overlay2 tags: - docker before_script: - docker info after_script: - chmod +x ./script.sh && ./script.sh ``` 以上示例展示了如何利用 Docker-in-Docker (dind) 提供额外支持,并确保脚本具备执行权。 --- ### 总结 通过对文件权限、Runner 用户身份、配置准确性以及调试工具的应用,能够有效地解决 `failed to locate executable permission denied` 错误。务必逐一排除潜在因素直至恢复正常运作状态。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值