我的系统上安装的 Curl 版本是:curl 7.35.0 我尝试运行以下命令,但它返回错误代码 7:
outpt=0;
FUEL_TOKEN_JSON="$( /usr/bin/curl --noproxy '*' -s -H 'Content-Type: application/json' -X POST -d '{"auth":{"passwordCredentials":{"username":"","password":""},"tenantName":""}}' -e "http://IP:port/" -k -A 'Mozilla' "http://IP:port/keystone/v2.0/tokens" || :)" || outpt=$?
ErrorReceived:puppet::Parser::AST::Resource failed with error ArgumentError: Could not find declared class ::keystone at /etc/puppet/modules/fuel/manifests/keystone.pp
答案1
从输出可以看出,问题是不是使用 curl,但使用你的 Puppet 类:
ErrorReceived:puppet::Parser::AST::Resource failed with error ArgumentError: Could not find declared class ::keystone at /etc/puppet/modules/fuel/manifests/keystone.pp
/etc/puppet/modules/fuel/manifests/keystone.pp
具体来说,您的 Puppet 服务器出了问题。