1.6.3. CLI を使用したデバイスへのアプリケーションのデプロイ
CLI を使用して OCI レジストリーからデバイスにアプリケーションパッケージをデプロイします。
以下の手順を実行します。
デプロイするアプリケーションパッケージを
Deviceリソースのspec.applicationsフィールドに指定します。apiVersion: flightctl.io/v1alpha1 kind: Device metadata: name: <device_name> spec: [...] applications: - name: wordpress1 image: quay.io/rhem-demos/wordpress-app:latest2 envVars:3 WORDPRESS_DB_HOST: <database_host> WORDPRESS_DB_USER: <user_name> WORDPRESS_DB_PASSWORD: <password> [...]注記: デバイス仕様の
applicationsセクションでアプリケーションごとに、対応するデバイスステータス情報を確認できます。デバイスのステータス情報を確認して、デバイスへのアプリケーションデプロイメントのステータスを確認します。以下のコマンドを実行します。
flightctl get device/<your_device_id> -o yaml以下の出力例を参照してください。
[...] spec: applications: - name: example-app image: quay.io/flightctl-demos/example-app:v1 status: applications: - name: example-app ready: 3/3 restarts: 0 status: Running applicationsSummary: info: All application workloads are healthy. status: Healthy [...]