インストールコマンドの取得
service.namespace および service.name が Splunk AppDynamics アプリケーション名と階層名にマップされます。コマンドを実行すると、新しい一時ディレクトリに移動します。次の API からコマンドを取得し、同じディレクトリから実行します。
形式:
GET /install/installCommand?sudo={true|false}&application={appName}&accessKey={accessKey}&serviceUrl={serviceUrl}&osType={windows|linux}&otelEnabled={true|false}&tracesExporter={tracesExporter}&metricsExporter={metricsExporter}&otlpEndpoint={collectorEndpoint}&simEnabled={true|false}&dotnetCompatibility={true|false}
リクエストの例:
- Linuxの場合:
-
curl --location --request GET 'https://demo.saas.appdynamics.com/zero/v1beta/install/installCommand?sudo=true&application=helloWorld&accessKey=fb19d1d6-6858-5fea-b6ed-302480e5c580&serviceUrl=https://demo.saas.appdynamics.com&osType=linux&otelEnabled=true&tracesExporter=otlp,logging&metricsExporter=otlp,logging&otlpEndpoint=https://demo.saas.appdynamics.com/otlp-collector&simEnabled=true' --header 'Authorization: Bearer {AuthToken}'
- Windowsの場合:
-
curl --location --request GET 'https://demo.saas.appdynamics.com/zero/v1beta/install/installCommand?application=helloWorld&accessKey=fb19d1d6-6858-5fea-b6ed-302480e5c580&serviceUrl=https://demo.saas.appdynamics.com&osType=windows&simEnabled=true&dotnetCompatibility=true' --header 'Authorization: Bearer {AuthToken}'
応答の例:
- Linuxの場合:
-
[ "sudo ./zero-agent.sh install --application 'helloWorld' --account 'demo' --access-key 'fb19d1d6-6858-5fea-b6ed-302480e5c580' --service-url 'https://demo.saas.appdynamics.com' --enable-sim 'true' --enable-otel 'true' --traces-exporter 'otlp,logging' --metrics-exporter 'otlp,logging' --otlp-endpoint 'https://demo.saas.appdynamics.com/otlp-collector'" ]
- Windowsの場合:
-
[ ".\\zero-agent.ps1 install --application 'helloWorld' --account 'demo' --access-key 'fb19d1d6-6858-5fea-b6ed-302480e5c580' --service-url 'https://demo.saas.appdynamics.com' --enable-sim 'true' --dotnet-compatibility 'true'" ]