このページは機械翻訳を使用して翻訳されました。最新版の英語を参照するには、ここをクリックします。
webapps-secrets
構文
説明
webapps-secrets remove
は vault からシークレット keyName
keyValue
[--scope scopeValue
]keyName
を削除します。
webapps-secrets set-attributes --secret-key
は、シークレット keyName
[attrName
attrValue
] [--scope scopeValue
] [--mode Add|Merge|Replace]keyName
の属性を設定します。オプションで、キーに新しい属性を追加するか、新しい属性と既存の属性をマージするか、既存のすべての属性を新しい属性に置き換えるかを構成できます。
webapps-secrets get-attributes --secret-key
は、keyName
[--scope scopeValue
]keyName
という名前のシークレットの属性を返します。
webapps-secrets list [--scope
は、スコープ scopeValue
]scopeValue
内で現在設定されているすべての秘密鍵を一覧表示します。
webapps-secrets listAll
は、すべてのスコープ内で現在設定されているすべての秘密鍵を一覧表示します。
webapps-secrets --help
はコマンドのヘルプ テキストを表示します。
webapps-secrets --version
はコマンドのバージョン情報を表示します。
例
特定の秘密鍵の値を設定する
特定の秘密鍵の値を設定するには、システム コマンド ラインで次のように入力します。
webapps-secrets set mypassword hunter2
Vault location:C:\ProgramData\MathWorks\webapps\R2025a\config\webapps_private\webapps_secrets.xml
MATLAB Web App Server secrets configuration has been updated.
シークレットが追加されたことを確認します。
webapps-secrets listAll
Vault location:C:\ProgramData\MathWorks\webapps\R2025a\config\webapps_private\webapps_secrets.xml
List of secret keys configured:
scope:<default>, secret key:mypassword
サーバーからシークレットを削除する
既存の秘密鍵 mypassword
をサーバーから削除するには、システム コマンド ラインで次のように入力します。
webapps-secrets remove mypassword
Vault location:C:\ProgramData\MathWorks\webapps\R2025a\config\webapps_private\webapps_secrets.xml
MATLAB Web App Server secrets configuration has been updated.
秘密鍵の属性を設定する
属性は、秘密鍵と暗号化された値とともに webapps_secrets
XML ファイルに保存される暗号化されていないメタデータです。
秘密鍵 myusername
の値を設定するには、システム コマンド ラインで次のように入力します。
webapps-secrets set myusername mluser
Vault location:C:\ProgramData\MathWorks\webapps\R2025a\config\webapps_private\webapps_secrets.xml
MATLAB Web App Server secrets configuration has been updated.
秘密鍵 myusername
の属性を設定するには、システム コマンド ラインで次のように入力します。
webapps-secrets set-attributes --secret-key myusername hostname myhost port 8080
Vault location:C:\ProgramData\MathWorks\webapps\R2025a\config\webapps_private\webapps_secrets.xml
MATLAB Web App Server secrets configuration has been updated.
--mode
演算子を使用して、秘密鍵の既存の属性を変更できます。
webapps-secrets set-attributes --secret-key myusername port 422 --mode Merge
Vault location:C:\ProgramData\MathWorks\webapps\R2025a\config\webapps_private\webapps_secrets.xml
MATLAB Web App Server secrets configuration has been updated.
秘密鍵の属性を取得する
秘密鍵 myusername
の属性を取得するには、システム コマンド ラインで次のように入力します。
webapps-secrets get-attributes --secret-key myusername
Vault location:C:\ProgramData\MathWorks\webapps\R2025a\config\webapps_private\webapps_secrets.xml
List of secret keys configured:
hostname --->myhost
port --->422
スコープ別にシークレットを一覧表示する
特定のスコープを持つシークレットを設定するには、システム コマンド ラインで次のように入力します。
webapps-secrets set mysecret2 97e846a4-a913-4a26 --scope $UserID
Vault location:C:\ProgramData\MathWorks\webapps\R2025a\config\webapps_private\webapps_secrets.xml
MATLAB Web App Server secrets configuration has been updated.
スコープ $UserID
を持つ現在設定されているすべての秘密鍵を一覧表示するには、システム コマンド ラインで次のように入力します。
webapps-secrets list --scope $UserID
Vault location:C:\ProgramData\MathWorks\webapps\R2025a\config\webapps_private\webapps_secrets.xml
List of secret keys configured:
scope:$UserID, secret key:mysecret2
すべてのシークレットを一覧表示する
現在設定されているすべての秘密鍵を一覧表示するには、システム コマンド ラインで次のように入力します。
webapps-secrets listAll
Vault location:C:\ProgramData\MathWorks\webapps\R2025a\config\webapps_private\webapps_secrets.xml
List of secret keys configured:
scope:<default>, secret key:myusername
scope:$UserID, secret key:mysecret2
ヘルプテキストを表示
webapps-secrets
ヘルプ テキストを印刷するには、システム コマンド ラインで次のように入力します。
webapps-secrets -h
Usage: webapps-secrets [--help | -h] Display this help message webapps-secrets [--version | -v] Display the version of MATLAB Web App Server webapps-secrets list [--scope <value>] List currently configured secret keys webapps-secrets listAll List all currently configured secret keys in all scopes webapps-secrets set <key> <value> [--scope <value>] [--mode Overwrite|FailIfExists] Set a secret to MATLAB Web App Server webapps-secrets remove <key> [--scope <value>] Remove a secret key from MATLAB Web App Server webapps-secrets set-attributes --secret-key <secret_key> [<attr_key> <attr_value>] [--scope <value>] [--mode Add|Merge|Replace] Set attributes of a secret to MATLAB Web App Server webapps-secrets get-attributes --secret-key <secret_key> [--scope <value>] Get attributes of a secret from MATLAB Web App Server
表示バージョン
MATLAB® Web App Server™ のバージョン情報を出力するには、システム コマンド ラインで次のように入力します。
webapps-secrets -v
MATLAB Web App Server (R2025a)
入力引数
詳細
バージョン履歴
R2024a で導入