5

Windows Azure の IaaS 部分をテストしており、REST API を使用してさまざまな仮想マシン インスタンスを正常に展開しています。VM を起動するための POST 要求の XML 本文は次のとおりです。

<Deployment xmlns="http://schemas.microsoft.com/windowsazure" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
  <Name>Azure</Name>
  <DeploymentSlot>Production</DeploymentSlot>
  <Label>Azure IM created VM</Label>
  <RoleList>
    <Role i:type="PersistentVMRole">
      <RoleName>IMVMRole</RoleName>
      <OsVersion i:nil="true"/>
      <RoleType>PersistentVMRole</RoleType>
      <ConfigurationSets>

        <ConfigurationSet i:type="LinuxProvisioningConfigurationSet">
          <ConfigurationSetType>LinuxProvisioningConfiguration</ConfigurationSetType>
          <HostName>AzureNode</HostName>
          <UserName>user</UserName>
          <UserPassword>Prueba+1111</UserPassword>
          <DisableSshPasswordAuthentication>false</DisableSshPasswordAuthentication>
        </ConfigurationSet>

        <ConfigurationSet i:type="NetworkConfigurationSet">
          <ConfigurationSetType>NetworkConfiguration</ConfigurationSetType>
          <InputEndpoints>
            <InputEndpoint>
              <LocalPort>22</LocalPort>
              <Name>SSH</Name>
              <Port>22</Port>
              <Protocol>TCP</Protocol>
            </InputEndpoint>
          </InputEndpoints>
        </ConfigurationSet>
      </ConfigurationSets>
      <Label>Azure IM created VM</Label>

      <OSVirtualHardDisk>
        <MediaLink>https://XXXXXXX.blob.core.windows.net/vhds/0b11de9248dd4d87b18621318e037d37__RightImage-Ubuntu-12.04-x64-v13.4.vhd</MediaLink>
        <SourceImageName>0b11de9248dd4d87b18621318e037d37__RightImage-Ubuntu-12.04-x64-v13.4</SourceImageName>
      </OSVirtualHardDisk>
      <RoleSize>Small</RoleSize>
    </Role>
  </RoleList>
</Deployment>

ただし、Putty を使用して SSH 経由で VM に接続しようとすると、ユーザー/パスワード経由で認証しようとすると、次のメッセージが表示されます (XML 本文で DisableSshPasswordAuthentication = false と指定していることに注意してください)。利用可能な認証方法 (サーバー送信: 公開鍵)".

助けてくれたstackoverflowコミュニティ全体に感謝します。アベル。

4

1 に答える 1