启动vm时,根目录中没有文件,并且配置脚本无法运行,因为文档说它应该是(https://sldn.softlayer.com/blog/jarteche/Getting-Started-User-Data-and-Post-Provisioning-Scripts)。这是我用来创建服务器的请求。
{
"method": "post",
"baseUrl": "https://api.softlayer.com/rest/v3",
"url": "/SoftLayer_Product_Order/placeOrder",
"headers": {
"authorization": "Basic authtoken",
"content-type": "application/json",
"accept": "application/json"
},
"body": "{\"parameters\":[{\"complexType\":\"SoftLayer_Container_Product_Order_Virtual_Guest\",\"packageId\":46,\"sshKeys\":[{\"sshKeyIds\":[]}],\"quantity\":1,\"location\":957095,\"useHourlyPricing\":true,\"prices\":[{\"id\":1641},{\"id\":1645},{\"id\":273},{\"id\":1800},{\"id\":13887},{\"id\":55},{\"id\":905},{\"id\":57},{\"id\":58},{\"id\":21},{\"id\":37202},{\"id\":420},{\"id\":418}],\"provisionScripts\":[\"https://stage-provision.containership.io/provision-script?config=234d0983117bfd4054750cdbc2b4b72ef5c8fee22b69aa60b921f88dca5a8b33548efb0473d91ed86493214be27c19c17b551a2031aeaf7273f4ba5baf0030f86e7b886a829bc8c7b44d064254407edb7d297d6bb2ebca479aa814811f2345cebd00df8e666911cf3b9a292c3f6f59b43369a015c78f5c7a8a6627c68e55ab77e86972f834427f2f3b003ff022c0f694098d683a6f1723521d88fd02d3b17475e8392b29b974c60f680488ddd955d839e8db62c49d9f1eae031dadf05a0606879c0bba73198e3dc780b1bb77d72aa4abb887053694bf79e000483e847abff4831550e3760925c6e2bb1daa727a07373a536d52f5453027a2a71b40b64fc696c28ccff92071e8d78c0f73dc1d7c53f8518058723bfddcfb7799c70997979fd80794fa6deead1dc64506008c717a54b02a2304e9c013736bcfa63221e105d6b948c43ebd817e8a0cf6139547867c4c55d746ea9a0cccffe0f1528f464381a2de2d597adc1a1864b51f5d6791ecb05ea91df3af92e731b189d52d31bb32ade9bf29169a9b4a2430aaff35e87c990326ffe9fb09bcd3e6be0316881510bb0714f0fc4acc43bacc476275efac70205f05c97440cebb642c160622f6b08d9e45651bb40b913396da56dcb0181fc8f12f1a56408c8a569ae5061b813211e0645ec614bffa1fa4e92c137ba635d6302c423e5ea51f0564d913b11454efe9bf245b3d83348ccf2ae8fd7f69d9a3eea867ca128968599840a1bce38d157e787402ee5e8af239810629a60355c73cc889769c3276dc5244943f7bc1045e868105deb49aa8ddd58733f0b68b9d08ad83c46690cf2a6bc7dee1a9b1d428440de149cbe307791834fd981d825ff220d576af7180170ce9db5d365c13459773fd74a68e3949d7969ebcb9d4a2b286c7112c2bbaa92bf8db5b411a1f772d45044ef23a8a65b6b54fcc4428fcf98f98e7fa6da99afcc9200aab0de61ffa560dff1cf2e5c39ac57fe6458479b390644\"],\"virtualGuests\":[{\"hostname\":\"6de66c24-2ccb-43b1-b6e9-3dcdf6fa3ccb\",\"domain\":\"containership.io\"}]}]}"
}
答案 0 :(得分:0)
请查看您的电子邮件,下载失败时会发送电子邮件。此外,我注意到您正在使用动态URL,此行为可能与此相关。我建议你尽可能使用静态网址。
如果您想再次尝试下载该文件,我建议您使用方法SoftLayer_Virtual_Guest::executeRemoteScript。成功时返回NULL,如果失败则返回异常:
Script download failed. Could not confirm file downloaded correctly.
您可以使用以下REST调用:
https://[username]:[apikey]@api.softlayer.com/rest/v3/SoftLayer_Virtual_Guest/[device_id]/executeRemoteScript
Method: POST
Body JSON:
{
"parameters":[
"https://stage-provision.containership.io/provision-script?config=234d0983117bfd4054750cdbc2b4b72ef5c8fee22b69aa60b921f88dca5a8b33548efb0473d91ed86493214be27c19c17b551a2031aeaf7273f4ba5baf0030f86e7b886a829bc8c7b44d064254407edb7d297d6bb2ebca479aa814811f2345cebd00df8e666911cf3b9a292c3f6f59b43369a015c78f5c7a8a6627c68e55ab77e86972f834427f2f3b003ff022c0f694098d683a6f1723521d88fd02d3b17475e8392b29b974c60f680488ddd955d839e8db62c49d9f1eae031dadf05a0606879c0bba73198e3dc780b1bb77d72aa4abb887053694bf79e000483e847abff4831550e3760925c6e2bb1daa727a07373a536d52f5453027a2a71b40b64fc696c28ccff92071e8d78c0f73dc1d7c53f8518058723bfddcfb7799c70997979fd80794fa6deead1dc64506008c717a54b02a2304e9c013736bcfa63221e105d6b948c43ebd817e8a0cf6139547867c4c55d746ea9a0cccffe0f1528f464381a2de2d597adc1a1864b51f5d6791ecb05ea91df3af92e731b189d52d31bb32ade9bf29169a9b4a2430aaff35e87c990326ffe9fb09bcd3e6be0316881510bb0714f0fc4acc43bacc476275efac70205f05c97440cebb642c160622f6b08d9e45651bb40b913396da56dcb0181fc8f12f1a56408c8a569ae5061b813211e0645ec614bffa1fa4e92c137ba635d6302c423e5ea51f0564d913b11454efe9bf245b3d83348ccf2ae8fd7f69d9a3eea867ca128968599840a1bce38d157e787402ee5e8af239810629a60355c73cc889769c3276dc5244943f7bc1045e868105deb49aa8ddd58733f0b68b9d08ad83c46690cf2a6bc7dee1a9b1d428440de149cbe307791834fd981d825ff220d576af7180170ce9db5d365c13459773fd74a68e3949d7969ebcb9d4a2b286c7112c2bbaa92bf8db5b411a1f772d45044ef23a8a65b6b54fcc4428fcf98f98e7fa6da99afcc9200aab0de61ffa560dff1cf2e5c39ac57fe6458479b390644"
]
}
请勿忘记使用您自己的数据更改 [用户名] , [apikey] , [device_id] 。请注意, [device_id] 是您的虚拟访客的ID。
如果问题仍然存在,我建议您提交机票以获得进一步的帮助。