0

我正在为 CI 使用 jenkins mesos 插件。最初,我遵循以下教程:http ://www.ebaytechblog.com/2014/05/12/delivering-ebays-ci-solution-with-apache-mesos-part-ii/

但是詹金斯本身并没有通过这个设置。(我得到错误无法加载 config.xml 文件,即使有一个)

然后我跟着https://rogerignazio.com/blog/scaling-jenkins-mesos-marathon/ ,我能够运行 jenkins master (jenkins framework/scheduler),但是当我定义要运行的脚本时,jenkins-slaves没有被创建。我想我缺少一些关于奴隶的配置。你能告诉我,没有创建奴隶来运行工作的原因是什么。

在詹金斯构建页面上,我得到:

(pending—Waiting for next available executor)

在詹金斯日志中,我收到以下错误:

INFO: Provisioning Jenkins Slave on Mesos with 1 executors. Remaining excess workload: 0 executors)
Jun 19, 2015 4:02:55 PM hudson.slaves.NodeProvisioner$StandardStrategyImpl apply
INFO: Started provisioning MesosCloud from MesosCloud with 1 executors. Remaining excess workload: 0
Jun 19, 2015 4:02:55 PM org.jenkinsci.plugins.mesos.MesosComputerLauncher <init>
INFO: Constructing MesosComputerLauncher
Jun 19, 2015 4:02:55 PM org.jenkinsci.plugins.mesos.MesosSlave <init>
INFO: Constructing Mesos slave mesos-jenkins-1f8691df-9918-4175-87b3-bcc3de80b258 from cloud 
Jun 19, 2015 4:03:05 PM org.jenkinsci.plugins.mesos.MesosComputerLauncher launch
INFO: Launching slave computer mesos-jenkins-1f8691df-9918-4175-87b3-bcc3de80b258
Jun 19, 2015 4:03:05 PM org.jenkinsci.plugins.mesos.MesosComputerLauncher launch
INFO: Sending a request to start jenkins slave mesos-jenkins-1f8691df-9918-4175-87b3-bcc3de80b258
Jun 19, 2015 4:03:05 PM org.jenkinsci.plugins.mesos.JenkinsScheduler requestJenkinsSlave
INFO: Enqueuing jenkins slave request
Jun 19, 2015 4:03:05 PM hudson.slaves.NodeProvisioner update
INFO: MesosCloud provisioning successfully completed. We have now 2 computer(s)
java.lang.NullPointerException
    at org.jenkinsci.plugins.mesos.JenkinsScheduler.matches(JenkinsScheduler.java:306)
    at org.jenkinsci.plugins.mesos.JenkinsScheduler.resourceOffers(JenkinsScheduler.java:252)
Jun 19, 2015 4:03:06 PM org.jenkinsci.plugins.mesos.JenkinsScheduler$1 run
SEVERE: The Mesos driver was aborted! Status code: 3

编辑:我想我遇到了错误,因为我没有定义任何容器端口映射。谁能告诉我该怎么做?

更新:实际上 0.7 版本的 mesos 插件存在很多问题。所以,我干脆降级到0.6版本。

4

1 回答 1

0

有关 marathon 的端口映射,请查看此处

希望这可以帮助!

于 2015-06-25T06:06:44.833 回答