...
No. | Use Cases | Configure the app | Conceptual diagram | ||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | If you want to containerize an app that has already been developed using i-PRO CAMERA SDK | An existing app is simply containerized, creating one app with one container configuration |
| ||||||||||||||||||||||||||||||||||||
2 | If you want to port an AI app developed for a device other than the i-PRO camera to the i-PRO camera | One app with one container configuration, replacing the AI functions and video acquisition parts of the existing app with the ADAM API | |||||||||||||||||||||||||||||||||||||
3 | If you want to easily port an app that does not have AI functions and has been developed for devices other than the i-PRO camera to the i-PRO camera | One app that consists of two containers: one with management functions for i-PRO cameras and one that runs existing apps. |
| ||||||||||||||||||||||||||||||||||||
4 | If you want to port an app with multiple container configurations, such as OSS, that has been developed for devices other than the i-PRO camera to the i-PRO camera | A container with management functions for i-PRO cameras and one application with multiple existing container configurations |
| ||||||||||||||||||||||||||||||||||||
5 | If you want to port two loosely related apps that do not communicate directly between each other and are developed by different companies to an i-PRO camera | Two apps |
| ||||||||||||||||||||||||||||||||||||
6 | If you have multiple apps that want to use the ADAM API | Two apps |
2.2
...
Configuration for developing apps with multiple containers
The docker_multi_images included in the SDK is a sample app that can be used as a reference if you choose use case 3 or 4 in Chapter 2.1. The docker_multi_images sample app consists of two Docker images.
docker_multi_images イメージ
カメラ本体からアプリの開始停止やキープアライブメッセージの応答を行うために存在します。本ドキュメントでは「メインイメージ」と呼びます。また、このイメージから生成されたコンテナを「メインコンテナ」と呼びます。サンプルアプリでは、イベントループを回して待機のみ実施しています。i-PRO CAMERA SDKでビルドします。web イメージ
DockerHubで公開されている 軽量版のnginx をベースにデフォルトの設定ファイル (default.conf) のみを置き換えたイメージとなります。本ドキュメントでは「サブイメージ」と呼びます。また、このイメージから生成されたコンテナを「サブコンテナ」と呼びます。nginxのTCP 80ポートを外部にTCP 8081ポートとして公開し、外部機器からのhttpリクエストを受け付けます。Container AdamAppを作成する際には、事前にDockerイメージとしてビルドされている必要があります。
...
image
It exists to start and stop the application from the camera body and to respond to keep-alive messages. In this document, it is called the "main image." Also, the container generated from this image is called the "main container." The sample application only runs an event loop and waits. It is built with i-PRO CAMERA SDK.web image
This image is based on the lightweight version of nginx published on DockerHub, with only the default configuration file (default.conf) replaced. This document calls it a "subimage." Also, a container generated from this image is called a "subcontainer." It exposes nginx's TCP 80 port to the outside as TCP 8081 port and accepts http requests from external devices. When creating Container AdamApp, it must be built as a Docker image in advance.
If you want to run an existing container on an i-PRO camera, you can add the docker_multi_images image for management from the camera, and the existing container can be run on the camera with minimal changes.
Drawio | ||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
2.3
...
i-PROカメラ上で既存コンテナを動作させる場合、主に以下三点を考慮する必要があります。
Porting Considerations
When running an existing container on an i-PRO camera, you need to consider the following three points:
Are there enough RAM/ROM/ CPUリソースが足りるか
i-PROカメラのセキュリティポリシーに合致しているか
ADAM APIを使用するコンテナは一つだけか
...
CPU resources?
Does it comply with the i-PRO camera security policy?
Is there only one container that uses the ADAM API?
These are explained below.
2.3.1 RAM / ROM / CPUリソース について
...