次の方法で共有


KeyVaultBackupClient class

KeyVaultBackupClient には、特定の Azure Key Vault インスタンスのバックアップを生成し、バックアップを復元する方法が用意されています。 このクライアントは、完全バックアップの生成、特定のキーの選択的復元、Key Vault インスタンスの完全復元をサポートします。

コンストラクター

KeyVaultBackupClient(string, TokenCredential, KeyVaultBackupClientOptions)

KeyVaultBackupClient のインスタンスを作成します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

プロパティ

vaultUrl

コンテナーへのベース URL

メソッド

beginBackup(string, KeyVaultBeginBackupOptions)

ユーザー割り当てマネージド ID を使用してストレージ アカウントにアクセスし、指定したストレージ BLOB アカウントで Azure Key Vault のバックアップの生成を開始します。

この関数は、Key Vault のバックアップが生成されるまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const poller = await client.beginBackup(blobStorageUri);

// Serializing the poller
const serialized = poller.toString();

// A new poller can be created with:
await client.beginBackup(blobStorageUri, { resumeFrom: serialized });

// Waiting until it's done
const backupUri = await poller.pollUntilDone();
console.log(backupUri);

完全バックアップ操作を開始します。

beginBackup(string, string, KeyVaultBeginBackupOptions)

指定したストレージ BLOB アカウントで Azure Key Vault のバックアップの生成を開始します。

この関数は、Key Vault のバックアップが生成されるまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const sasToken = "<sas-token>";
const poller = await client.beginBackup(blobStorageUri, sasToken);

// Serializing the poller
const serialized = poller.toString();

// A new poller can be created with:
await client.beginBackup(blobStorageUri, sasToken, { resumeFrom: serialized });

// Waiting until it's done
const backupUri = await poller.pollUntilDone();
console.log(backupUri);

完全バックアップ操作を開始します。

beginPreBackup(string, KeyVaultBeginPreBackupOptions)

マネージド HSM で構成されたユーザー割り当てマネージド ID を使用して、Azure Storage で認証する beginBackup 操作を実行できるかどうかを確認するために使用できるバックアップ前操作を開始します。

この関数は、操作が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const poller = await client.beginPreBackup(blobStorageUri);

// Serializing the poller
const serialized = poller.toString();

// A new poller can be created with:
await client.beginPreBackup(blobStorageUri, { resumeFrom: serialized });

// Waiting until it's done
const result = await poller.pollUntilDone();
console.log(result);
beginPreBackup(string, string, KeyVaultBeginPreBackupOptions)

指定された SAS トークンを使用して、お客様が beginBackup 操作を実行できるかどうかを確認するために使用できるバックアップ前操作を開始します。

この関数は、操作が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const sasToken = "<sas-token>";
const poller = await client.beginPreBackup(blobStorageUri, sasToken);

// Serializing the poller
const serialized = poller.toString();

// A new poller can be created with:
await client.beginPreBackup(blobStorageUri, sasToken, { resumeFrom: serialized });

// Waiting until it's done
const result = await poller.pollUntilDone();
console.log(result);
beginPreRestore(string, KeyVaultBeginPreRestoreOptions)

指定された SAS トークンを使用して、お客様が beginRestore 操作を実行できるかどうかを確認するために使用できる復元前操作を開始します。

この関数は、操作が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const sasToken = "<sas-token>";
const poller = await client.beginPreRestore(blobStorageUri, sasToken);

// The poller can be serialized with:
const serialized = poller.toString();

// A new poller can be created with:
await client.beginPreRestore(blobStorageUri, sasToken, { resumeFrom: serialized });

// Waiting until it's done
await poller.pollUntilDone();
beginPreRestore(string, string, KeyVaultBeginPreRestoreOptions)

指定された SAS トークンを使用して、お客様が beginRestore 操作を実行できるかどうかを確認するために使用できる復元前操作を開始します。

この関数は、操作が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const sasToken = "<sas-token>";
const poller = await client.beginPreRestore(blobStorageUri, sasToken);

// The poller can be serialized with:
const serialized = poller.toString();

// A new poller can be created with:
await client.beginPreRestore(blobStorageUri, sasToken, { resumeFrom: serialized });

// Waiting until it's done
await poller.pollUntilDone();
beginRestore(string, KeyVaultBeginRestoreOptions)

ユーザー割り当てマネージド ID を使用してストレージ アカウントにアクセスし、以前に格納された Azure Blob Storage バックアップ フォルダーを指す SAS トークンを使用して、すべてのキー マテリアルの復元を開始します。

この関数は、Key Vault の復元操作が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const poller = await client.beginRestore(blobStorageUri);

// The poller can be serialized with:
const serialized = poller.toString();

// A new poller can be created with:
await client.beginRestore(blobStorageUri, { resumeFrom: serialized });

// Waiting until it's done
await poller.pollUntilDone();

完全復元操作を開始します。

beginRestore(string, string, KeyVaultBeginRestoreOptions)

以前に格納された Azure Blob Storage バックアップ フォルダーを指す SAS トークンを使用して、すべてのキー マテリアルの復元を開始します。

この関数は、Key Vault の復元操作が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const sasToken = "<sas-token>";
const poller = await client.beginRestore(blobStorageUri, sasToken);

// The poller can be serialized with:
const serialized = poller.toString();

// A new poller can be created with:
await client.beginRestore(blobStorageUri, sasToken, { resumeFrom: serialized });

// Waiting until it's done
const backupUri = await poller.pollUntilDone();
console.log(backupUri);

完全復元操作を開始します。

beginSelectiveKeyRestore(string, string, KeyVaultBeginSelectiveKeyRestoreOptions)

以前に格納された Azure Blob Storage バックアップ フォルダーに使用して、特定のキーのすべてのキー バージョンの復元を開始します。 Blob Storage バックアップ フォルダーには、ユーザー割り当てマネージド ID を使用してアクセスします。

この関数は、Key Vault の選択的復元が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>";
const keyName = "<key-name>";
const poller = await client.beginSelectiveKeyRestore(keyName, blobStorageUri);

// Serializing the poller
const serialized = poller.toString();

// A new poller can be created with:
await client.beginSelectiveKeyRestore(keyName, blobStorageUri, { resumeFrom: serialized });

// Waiting until it's done
await poller.pollUntilDone();

新しいロールの割り当てを作成します。

beginSelectiveKeyRestore(string, string, string, KeyVaultBeginSelectiveKeyRestoreOptions)

以前に格納された Azure Blob Storage バックアップ フォルダーを指すユーザー指定の SAS トークンを使用して、特定のキーのすべてのキー バージョンの復元を開始します。

この関数は、Key Vault の選択的復元が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>";
const sasToken = "<sas-token>";
const keyName = "<key-name>";
const poller = await client.beginSelectiveKeyRestore(keyName, blobStorageUri, sasToken);

// Serializing the poller
const serialized = poller.toString();

// A new poller can be created with:
await client.beginSelectiveKeyRestore(keyName, blobStorageUri, sasToken, {
  resumeFrom: serialized,
});

// Waiting until it's done
await poller.pollUntilDone();

新しいロールの割り当てを作成します。

コンストラクターの詳細

KeyVaultBackupClient(string, TokenCredential, KeyVaultBackupClientOptions)

KeyVaultBackupClient のインスタンスを作成します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);
new KeyVaultBackupClient(vaultUrl: string, credential: TokenCredential, options?: KeyVaultBackupClientOptions)

パラメーター

vaultUrl

string

Key Vault の URL。 次の図形が必要です: https://${your-key-vault-name}.vault.azure.net。 この URL が有効な Key Vault または Managed HSM リソースを参照していることを検証する必要があります。 詳細については、https://aka.ms/azsdk/blog/vault-uri を参照してください。

credential
TokenCredential

サービスへの要求を認証するために使用する TokenCredential インターフェイスを実装するオブジェクト。 @azure/identity パッケージを使用して、ニーズに合った資格情報を作成します。

options
KeyVaultBackupClientOptions

Key Vault API 要求を構成するために使用されるオプション。

プロパティの詳細

vaultUrl

コンテナーへのベース URL

vaultUrl: string

プロパティ値

string

メソッドの詳細

beginBackup(string, KeyVaultBeginBackupOptions)

ユーザー割り当てマネージド ID を使用してストレージ アカウントにアクセスし、指定したストレージ BLOB アカウントで Azure Key Vault のバックアップの生成を開始します。

この関数は、Key Vault のバックアップが生成されるまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const poller = await client.beginBackup(blobStorageUri);

// Serializing the poller
const serialized = poller.toString();

// A new poller can be created with:
await client.beginBackup(blobStorageUri, { resumeFrom: serialized });

// Waiting until it's done
const backupUri = await poller.pollUntilDone();
console.log(backupUri);

完全バックアップ操作を開始します。

function beginBackup(blobStorageUri: string, options?: KeyVaultBeginBackupOptions): Promise<PollerLike<KeyVaultBackupOperationState, KeyVaultBackupResult>>

パラメーター

blobStorageUri

string

バックアップが最終的に格納されるコンテナーへのパスを含む、BLOB ストレージ リソースの URL。

options
KeyVaultBeginBackupOptions

省略可能なパラメーター。

戻り値

beginBackup(string, string, KeyVaultBeginBackupOptions)

指定したストレージ BLOB アカウントで Azure Key Vault のバックアップの生成を開始します。

この関数は、Key Vault のバックアップが生成されるまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const sasToken = "<sas-token>";
const poller = await client.beginBackup(blobStorageUri, sasToken);

// Serializing the poller
const serialized = poller.toString();

// A new poller can be created with:
await client.beginBackup(blobStorageUri, sasToken, { resumeFrom: serialized });

// Waiting until it's done
const backupUri = await poller.pollUntilDone();
console.log(backupUri);

完全バックアップ操作を開始します。

function beginBackup(blobStorageUri: string, sasToken: string, options?: KeyVaultBeginBackupOptions): Promise<PollerLike<KeyVaultBackupOperationState, KeyVaultBackupResult>>

パラメーター

blobStorageUri

string

バックアップが最終的に格納されるコンテナーへのパスを含む、BLOB ストレージ リソースの URL。

sasToken

string

BLOB ストレージ リソースへのアクセスに使用される SAS トークン。

options
KeyVaultBeginBackupOptions

省略可能なパラメーター。

戻り値

beginPreBackup(string, KeyVaultBeginPreBackupOptions)

マネージド HSM で構成されたユーザー割り当てマネージド ID を使用して、Azure Storage で認証する beginBackup 操作を実行できるかどうかを確認するために使用できるバックアップ前操作を開始します。

この関数は、操作が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const poller = await client.beginPreBackup(blobStorageUri);

// Serializing the poller
const serialized = poller.toString();

// A new poller can be created with:
await client.beginPreBackup(blobStorageUri, { resumeFrom: serialized });

// Waiting until it's done
const result = await poller.pollUntilDone();
console.log(result);
function beginPreBackup(blobStorageUri: string, options?: KeyVaultBeginPreBackupOptions): Promise<PollerLike<KeyVaultBackupOperationState, KeyVaultBackupResult>>

パラメーター

blobStorageUri

string

バックアップが最終的に格納されるコンテナーへのパスを含む、BLOB ストレージ リソースの URL。

options
KeyVaultBeginPreBackupOptions

省略可能なパラメーター。

戻り値

beginPreBackup(string, string, KeyVaultBeginPreBackupOptions)

指定された SAS トークンを使用して、お客様が beginBackup 操作を実行できるかどうかを確認するために使用できるバックアップ前操作を開始します。

この関数は、操作が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const sasToken = "<sas-token>";
const poller = await client.beginPreBackup(blobStorageUri, sasToken);

// Serializing the poller
const serialized = poller.toString();

// A new poller can be created with:
await client.beginPreBackup(blobStorageUri, sasToken, { resumeFrom: serialized });

// Waiting until it's done
const result = await poller.pollUntilDone();
console.log(result);
function beginPreBackup(blobStorageUri: string, sasToken: string, options?: KeyVaultBeginPreBackupOptions): Promise<PollerLike<KeyVaultBackupOperationState, KeyVaultBackupResult>>

パラメーター

blobStorageUri

string

バックアップが最終的に格納されるコンテナーへのパスを含む、BLOB ストレージ リソースの URL。

sasToken

string

BLOB ストレージ リソースへのアクセスに使用される SAS トークン。

options
KeyVaultBeginPreBackupOptions

省略可能なパラメーター。

戻り値

beginPreRestore(string, KeyVaultBeginPreRestoreOptions)

指定された SAS トークンを使用して、お客様が beginRestore 操作を実行できるかどうかを確認するために使用できる復元前操作を開始します。

この関数は、操作が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const sasToken = "<sas-token>";
const poller = await client.beginPreRestore(blobStorageUri, sasToken);

// The poller can be serialized with:
const serialized = poller.toString();

// A new poller can be created with:
await client.beginPreRestore(blobStorageUri, sasToken, { resumeFrom: serialized });

// Waiting until it's done
await poller.pollUntilDone();
function beginPreRestore(folderUri: string, options?: KeyVaultBeginPreRestoreOptions): Promise<PollerLike<KeyVaultRestoreOperationState, KeyVaultRestoreResult>>

パラメーター

folderUri

string

前回正常に完了した完全バックアップが格納された BLOB ストレージ リソースの URL。

options
KeyVaultBeginPreRestoreOptions

省略可能なパラメーター。

戻り値

beginPreRestore(string, string, KeyVaultBeginPreRestoreOptions)

指定された SAS トークンを使用して、お客様が beginRestore 操作を実行できるかどうかを確認するために使用できる復元前操作を開始します。

この関数は、操作が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const sasToken = "<sas-token>";
const poller = await client.beginPreRestore(blobStorageUri, sasToken);

// The poller can be serialized with:
const serialized = poller.toString();

// A new poller can be created with:
await client.beginPreRestore(blobStorageUri, sasToken, { resumeFrom: serialized });

// Waiting until it's done
await poller.pollUntilDone();
function beginPreRestore(folderUri: string, sasToken: string, options?: KeyVaultBeginPreRestoreOptions): Promise<PollerLike<KeyVaultRestoreOperationState, KeyVaultRestoreResult>>

パラメーター

folderUri

string

前回正常に完了した完全バックアップが格納された BLOB ストレージ リソースの URL。

sasToken

string

SAS トークン。 SAS トークンが指定されていない場合は、ユーザー割り当てマネージド ID を使用して BLOB ストレージ リソースにアクセスします。

options
KeyVaultBeginPreRestoreOptions

省略可能なパラメーター。

戻り値

beginRestore(string, KeyVaultBeginRestoreOptions)

ユーザー割り当てマネージド ID を使用してストレージ アカウントにアクセスし、以前に格納された Azure Blob Storage バックアップ フォルダーを指す SAS トークンを使用して、すべてのキー マテリアルの復元を開始します。

この関数は、Key Vault の復元操作が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const poller = await client.beginRestore(blobStorageUri);

// The poller can be serialized with:
const serialized = poller.toString();

// A new poller can be created with:
await client.beginRestore(blobStorageUri, { resumeFrom: serialized });

// Waiting until it's done
await poller.pollUntilDone();

完全復元操作を開始します。

function beginRestore(folderUri: string, options?: KeyVaultBeginRestoreOptions): Promise<PollerLike<KeyVaultRestoreOperationState, KeyVaultRestoreResult>>

パラメーター

folderUri

string

前回正常に完了した完全バックアップが格納された BLOB ストレージ リソースの URL。

options
KeyVaultBeginRestoreOptions

省略可能なパラメーター。

戻り値

beginRestore(string, string, KeyVaultBeginRestoreOptions)

以前に格納された Azure Blob Storage バックアップ フォルダーを指す SAS トークンを使用して、すべてのキー マテリアルの復元を開始します。

この関数は、Key Vault の復元操作が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>"; // <Blob storage URL>/<folder name>
const sasToken = "<sas-token>";
const poller = await client.beginRestore(blobStorageUri, sasToken);

// The poller can be serialized with:
const serialized = poller.toString();

// A new poller can be created with:
await client.beginRestore(blobStorageUri, sasToken, { resumeFrom: serialized });

// Waiting until it's done
const backupUri = await poller.pollUntilDone();
console.log(backupUri);

完全復元操作を開始します。

function beginRestore(folderUri: string, sasToken: string, options?: KeyVaultBeginRestoreOptions): Promise<PollerLike<KeyVaultRestoreOperationState, KeyVaultRestoreResult>>

パラメーター

folderUri

string

前回正常に完了した完全バックアップが格納された BLOB ストレージ リソースの URL。

sasToken

string

SAS トークン。 SAS トークンが指定されていない場合は、ユーザー割り当てマネージド ID を使用して BLOB ストレージ リソースにアクセスします。

options
KeyVaultBeginRestoreOptions

省略可能なパラメーター。

戻り値

beginSelectiveKeyRestore(string, string, KeyVaultBeginSelectiveKeyRestoreOptions)

以前に格納された Azure Blob Storage バックアップ フォルダーに使用して、特定のキーのすべてのキー バージョンの復元を開始します。 Blob Storage バックアップ フォルダーには、ユーザー割り当てマネージド ID を使用してアクセスします。

この関数は、Key Vault の選択的復元が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>";
const keyName = "<key-name>";
const poller = await client.beginSelectiveKeyRestore(keyName, blobStorageUri);

// Serializing the poller
const serialized = poller.toString();

// A new poller can be created with:
await client.beginSelectiveKeyRestore(keyName, blobStorageUri, { resumeFrom: serialized });

// Waiting until it's done
await poller.pollUntilDone();

新しいロールの割り当てを作成します。

function beginSelectiveKeyRestore(keyName: string, folderUri: string, options?: KeyVaultBeginSelectiveKeyRestoreOptions): Promise<PollerLike<KeyVaultSelectiveKeyRestoreOperationState, KeyVaultSelectiveKeyRestoreResult>>

パラメーター

keyName

string

復元するキーの名前。

folderUri

string

以前に正常に完了した完全バックアップが格納された BLOB のフォルダー名を含む、BLOB ストレージ リソースの URL。

options
KeyVaultBeginSelectiveKeyRestoreOptions

省略可能なパラメーター。

戻り値

beginSelectiveKeyRestore(string, string, string, KeyVaultBeginSelectiveKeyRestoreOptions)

以前に格納された Azure Blob Storage バックアップ フォルダーを指すユーザー指定の SAS トークンを使用して、特定のキーのすべてのキー バージョンの復元を開始します。

この関数は、Key Vault の選択的復元が完了するまで無期限に待機できる実行時間の長い操作ポーリング ツールを返します。

使用例:

import { DefaultAzureCredential } from "@azure/identity";
import { KeyVaultBackupClient } from "@azure/keyvault-admin";

const vaultUrl = `https://<MY KEY VAULT HERE>.vault.azure.net`;
const credentials = new DefaultAzureCredential();
const client = new KeyVaultBackupClient(vaultUrl, credentials);

const blobStorageUri = "<blob-storage-uri>";
const sasToken = "<sas-token>";
const keyName = "<key-name>";
const poller = await client.beginSelectiveKeyRestore(keyName, blobStorageUri, sasToken);

// Serializing the poller
const serialized = poller.toString();

// A new poller can be created with:
await client.beginSelectiveKeyRestore(keyName, blobStorageUri, sasToken, {
  resumeFrom: serialized,
});

// Waiting until it's done
await poller.pollUntilDone();

新しいロールの割り当てを作成します。

function beginSelectiveKeyRestore(keyName: string, folderUri: string, sasToken: string, options?: KeyVaultBeginSelectiveKeyRestoreOptions): Promise<PollerLike<KeyVaultSelectiveKeyRestoreOperationState, KeyVaultSelectiveKeyRestoreResult>>

パラメーター

keyName

string

復元するキーの名前。

folderUri

string

以前に正常に完了した完全バックアップが格納された BLOB のフォルダー名を含む、BLOB ストレージ リソースの URL。

sasToken

string

SAS トークン。 SAS トークンが指定されていない場合は、ユーザー割り当てマネージド ID を使用して BLOB ストレージ リソースにアクセスします。

options
KeyVaultBeginSelectiveKeyRestoreOptions

省略可能なパラメーター。

戻り値