Windows 用の Enterprise Developer ビルド ツールで使用するアプリケーションを含むイメージの作成

このトピックでは、Windows 用の Enterprise Developer ビルド ツールで実行できる COBOL アプリケーションを含むイメージを作成するために Dockerfile で実行する必要がある手順について説明します。

このトピックの手順を実行する前に、Windows 用の Enterprise Developer ビルド ツールのベース イメージを作成しておく必要があります。Windows 用の Enterprise Developer ビルド ツールのベース イメージの作成については、「Windows 用の Enterprise Developer ビルド ツールを含むベース イメージの作成」参照してください。

注: Remember that Enterprise Developer is a development and test environment so not for use in production situations. If you want to run COBOL applications in containers in a production environment you must use containers that contain Enterprise Server.

Windows 用の Enterprise Developer ビルド ツールで使用するアプリケーションを含むイメージを作成する前に、次のものが用意されていることを確認する必要があります。

Windows 用の Enterprise Developer ビルド ツールで使用するアプリケーションを含むイメージを作成するには、Dockerfile で次の手順を実行する必要があります。

  1. 作成元となるベース イメージを指定します。これは、必要に応じて 32 ビットまたは 64 ビット用に作成された Windows 用の Enterprise Developer ビルド ツールのみを含むイメージである必要があり、追加のビルド機能を含んでおり、通常は microfocus/edbuildtools-build:win_5.0_x86 または microfocus/edbuildtools-build:win_5.0_x64 になります。

    詳細については、「Windows 用の Enterprise Developer ビルド ツールを含むベース イメージの作成」を参照してください。

  2. Define metadata for your image. This will make it easier to establish significant details of the image when you use the docker inspect command.
  3. Define any variables for filenames and folder locations.
    注: If you will be using this image to run applications under Enterprise Server, you need to set the MFDS_EXTERNAL_ADDR environment variable to specify a resolvable external address string. This is to enable client browsers to resolve the URLs used by ESMAC and other utilities in Enterprise Server Administration.

    The value that you specify for this environment variable is used to replace the internal container address in the URL.

  4. アプリケーションのソース ファイルをイメージのファイルシステム上のフォルダーにコピーし、Docker の作業ディレクトリをそのフォルダーに設定します。
  5. アプリケーションのソース ファイルに対して行う必要があるすべての処理を実行します。通常これはコンパイルおよびビルドになりますが、Windows 用の Enterprise Developer ビルド ツールで可能な任意の処理を実行できます。
  6. ビルドしたアプリケーション ファイルをイメージのファイルシステム上にある目的のフォルダーにコピーし、Docker の作業ディレクトリをそのフォルダーに設定します。
  7. アプリケーションがマネージ COBOL の場合は、必要なサポート ファイルがイメージに含まれていることを確認します。詳細については、「コンテナーで実行されるマネージ COBOL アプリケーションのデバッグ」を参照してください。
  8. Perform any required clean-up. This includes tasks such as resetting variables and deleting temporary folders.
  9. イメージの実行時に実行する実行可能ファイルの名前を指定します。

上記の手順は、Windows 用の Enterprise Developer ビルド ツールで使用できるアプリケーションのイメージを作成する Docker デモンストレーションで使用されています。関連するすべてのファイルおよび Dockerfile についての説明など、このデモンストレーションの詳細については、「The CICS Docker デモンストレーション」を参照してください。