欢迎使用普元产品知识库,本知识库包含普元应用开发平台EOSPlatform,流程平台BPS,企业服务总线ESB,微服务平台Microservice,运维管理平台Devops,数据集成平台DI

页面树结构

欢迎使用普元文档库

Skip to end of metadata
Go to start of metadata

问题:在执行部署任务时报错:

[Pipeline] timestamps
[Pipeline] {
[Pipeline] git
09:48:18.920 Cloning the remote Git repository
09:48:18.920 Cloning repository null
09:48:18.920 > git init /opt/idc/apps/jenkins/work/workspace/release-DEV-2-NAIS-0.12-DEV01-160 # timeout=10
09:48:18.927 Fetching upstream changes from null
09:48:18.927 > git --version # timeout=10
09:48:18.933 using GIT_ASKPASS to set credentials auto create
09:48:18.933 > git fetch --tags --progress null +refs/heads/*:refs/remotes/origin/*
09:48:18.941 ERROR: Error cloning remote repo 'origin'
09:48:18.941 hudson.plugins.git.GitException: Command "git fetch --tags --progress null +refs/heads/*:refs/remotes/
origin/*" returned status code 128:
09:48:18.941 stdout:
09:48:18.941 stderr: fatal: 'null' does not appear to be a git repository
09:48:18.941 fatal: Could not read from remote repository.
09:48:18.941
09:48:18.941 Please make sure you have the correct access rights
09:48:18.941 and the repository exists.
09:48:18.941
09:48:18.942 at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1784)
09:48:18.942 at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:1513)
09:48:18.942 at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$300(CliGitAPIImpl.java:64)
09:48:18.942 at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:315)
09:48:18.942 at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$2.execute(CliGitAPIImpl.java:512)
09:48:18.942 at hudson.plugins.git.GitSCM.retrieveChanges(GitSCM.java:1057)
09:48:18.942 at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1097)
09:48:18.942 at org.jenkinsci.plugins.workflow.steps.scm.SCMStep.checkout(SCMStep.java:109)
09:48:18.942 at org.jenkinsci.plugins.workflow.steps.scm.SCMStep$StepExecutionImpl.run(SCMStep.java:83)
09:48:18.942 at org.jenkinsci.plugins.workflow.steps.scm.SCMStep$StepExecutionImpl.run(SCMStep.java:73)
09:48:18.942 at
org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNon
BlockingStepExecution.java:47)
09:48:18.942 at hudson.security.ACL.impersonate(ACL.java:221)
09:48:18.942 at
org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBl
ockingStepExecution.java:44)
09:48:18.942 at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
09:48:18.942 at java.util.concurrent.FutureTask.run(FutureTask.java:266)
09:48:18.942 at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
09:48:18.942 at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
09:48:18.942 at java.lang.Thread.run(Thread.java:745)
[Pipeline] }
[Pipeline] // timestamps
[Pipeline] echo

解决:在DevOps5.2中,部署编译好的介质至某台机器上,首先需要确认需要使用的机器是否进行过初始化(参考产品安装指南中的初始化部分介绍),初始化后将机器信息添加至ansible脚本仓库中(ansible脚本仓库地址,可以至管理平台--》服务集成中确认),添加至ansible脚本仓库中后,再将机器信息添加至部署–》资源处,最后再执行部署即可。

ansible脚本仓库中填写可以参考如下截图配置(遮盖住的为添加机器的ip地址):