使用exit_code 109指定的无效墨盒 [英] Invalid cartridge specified with exit_code 109

查看:97
本文介绍了使用exit_code 109指定的无效墨盒的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想使用REST API Openshift创建应用程序,我使用smarterclayton墨盒执行curl命令:

i want to create app with REST API Openshift i do this curl Command with smarterclayton cartridge :

curl -k -X POST https://openshift.redhat.com/broker/rest/domains/jhaopenshift/applications 
--user "user@gmail.com:passwd" 
--data "name=myapp&cartridge=https://github.com/smarterclayton/openshift-cdk-cart/blob/master/metadata/manifest.yml&scale=false"

但是我仍然有和无效的墨盒错误:

but i still have and Invalid Cartridge error :

{
"api_version":1.6,
"data":null,
"messages":[{"exit_code":109,
"field":"cartridge",
"index":null,
"severity":"error",
"text":"Invalid cartridge 'https://github.com/smarterclayton/openshift-cdk-cart/blob/master/metadata/manifest.yml' specified."}],
"status":"unprocessable_entity",
"supported_api_versions":[1.0,1.1,1.2,1.3,1.4,1.5,1.6],
"type":null,"version":"1.6"
}

并使用-H'Accept:application/xml'选项,我得到了:

and with -H 'Accept: application/xml' option i get this :

curl: (6) Could not resolve host: Accept
curl: (6) Could not resolve host: POST
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator,
root@localhost and inform them of the time the error occurred,   
and anything you might have done that may have
caused the error.</p>
<p>More information about this error may be available
in the server error log.</p>
<hr>
<address>Apache/2.2.15 (Red Hat) Server at openshift.redhat.com Port 80</address>
</body></html>

有什么办法解决此错误吗?

any ideas how to fix this error?

推荐答案

这应该有效:

curl -k -X POST https://openshift.redhat.com/broker/rest/domains/jhaopenshift/applications --user "user:pass" --data "name=myapp&cartridge[url]=https://cartreflect-claytondev.rhcloud.com/reflect?github=smarterclayton/openshift-cdk-cart&scale=false"

您需要在卡式盒参数之后提供[url],还需要指向包含Source-Url元素的manifest.yml文件,或使用卡式反射器指向带有以下内容的部分github网址:格式user/repo

You need to supply the [url] after the cartridge parameter, you also need to either point to a manifest.yml file that has the Source-Url element included, or use the cartridge reflector to point to the partial github url with the format user/repo

这篇关于使用exit_code 109指定的无效墨盒的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆