Documentation Index

Fetch the complete documentation index at: https://cli.ncloud-docs.com/llms.txt

Use this file to discover all available pages before exploring further.

getInitScriptDetail

Prev Next

VPC環境で利用できます。

初期化スクリプトの詳細情報を照会します。

構文

getInitScriptDetail構文は次の通りです。

./ncloud vserver getInitScriptDetail \
    --initScriptNo <init-script-no> \
    [--regionCode <KR|SGN|JPN>] \
    [--output <json|xml>]

オプション

getInitScriptDetailの実行時に指定できるオプションについて説明します。

必須オプション

getInitScriptDetailの必須オプションです。

オプション タイプ 必須の有無 説明
--initScriptNo String Required 初期化スクリプト番号

共通オプション

vserverコマンドで共通して使用するオプションについては、Server (VPC)のオプションをご参照ください。

初期化スクリプトの詳細照会リクエストが成功すると、スクリプトの識別情報と内容が返されます。

コマンド

コマンドの例は次の通りです。

./ncloud vserver getInitScriptDetail \
    --initScriptNo 12345678 \
    --regionCode KR \
    --output json

出力

出力の例は次の通りです。

{
  "getInitScriptDetailResponse": {
    "totalRows": 1,
    "initScriptList": [
      {
        "initScriptNo": "12345678",
        "initScriptName": "test-init-script-01",
        "createDate": "2026-05-14T14:08:35+0900",
        "initScriptDescription": "Test init script for documentation",
        "initScriptContent": "#!/bin/bash\necho \"Hello from init script\"\nsudo apt-get update -y",
        "osType": {
          "code": "LNX",
          "codeName": "LINUX"
        }
      }
    ],
    "requestId": "c3d4e5f6-a7b8-9012-cdef-345678901234",
    "returnCode": "0",
    "returnMessage": "success"
  }
}