- ホワイトクラウド ASPIRE
- サービスご利用ガイド
- APIを利用する
- APIリファレンス
- 仮想マシン
- コピー(A)
コピー(A)
対象テナントの指定したサイト・Pod・契約リソース・仮想マシングループに仮想マシンをコピーします。
- check
- 重要
APIを連続実行した場合、想定していない結果が生じる可能性がございます。実行したAPIの処理結果をGET /api/1.0/task で完了確認したうえで、次の処理を行ってください。
PUT /api/1.0/vm/{vmId}/action/copy
※ vmId :コピー元の仮想マシンのID
Request parameters | ||||
---|---|---|---|---|
Name | Description | Type | Data type | Required |
Authorization | Bearer [APIキー] | header | String | True |
vm | コピー先の仮想マシン情報 | body | Object | True |
Properties | ||||
---|---|---|---|---|
Name | Description | Example | Data type | Required |
vm | 仮想マシン情報 | Object | True | |
siteId | サイトID | 8eb064f7a5db11e895ea005056898046 | String | True |
vmName | 仮想マシン名 ※コピー先の仮想マシン名 |
VM01 | String | True |
vmgroupId | 仮想マシングループID ※コピー先の仮想マシングループID |
1d10a85b0d774af6b79264717ed57416 | String | True |
storages | 仮想マシンストレージ情報配列 | Array | True | |
storage | 仮想マシンストレージ情報 ※コピー元で保持するディスク数分記載してください。 |
Object | True | |
vmStorageId | 仮想マシンストレージID ※コピー元の仮想マシンのvmStorageIdを指定 |
01887c57faef446fb2cca00cef507efa | String | True |
storageId | ストレージID ※コピー先で利用するstorageIdを指定 |
f1af87b78705473fb7ca7e5924fa1843 | String | True |
nics | 仮想マシンNIC 情報配列 |
Array | ||
nic | 仮想マシンNIC情報 ※指定したテンプレートで保持するNIC数分記載 |
Object | ||
primaryKbn | プライマリ区分 1:プライマリ 0:プライマリ以外 |
1 | String | True |
networkId | ネットワークID ※未接続で作成する場合は空文字(“”)を指定 |
String | True | |
ipAddressKbn | IPアドレス区分 01:固定IPプール 02:手動 03:DHCP ※未接続で作成する場合は空文字(“”)を指定 |
01 | String | True |
ipAddress | IPアドレス ※ipAddressKbnが手動(02)の場合は記載必須 |
String |
Successful Response | |||
---|---|---|---|
Response Code | 200 OK | ||
Response Headers | Content-type: application/json | ||
Response parameters | |||
Name | Description | Example | Data type |
taskId | 実行しているアクションのタスクID | 24714aac4703428292a03cd847c9ed62 | String |
実行例) コピー元の仮想マシンのDisk数が2つ、NIC数1つの場合 |
---|
|
レスポンス例 |
---|
|
タスク確認例 |
---|
|
※ 出力された “targetId” はコピー元の仮想マシンの “vmId” となります。
※ コピー先の仮想マシン情報は仮想マシンの一覧取得をすることで確認できます。