Installing Watson Language Translator

A project administrator can install the Watson Language Translator service on IBM® Cloud Pak for Data.

Prerequisites

Required role: To complete this task, you must be an administrator of the project (namespace) where you will deploy Watson Language Translator.

Before you install Watson Language Translator, ensure that:

Common core services Watson Language Translator requires the Cloud Pak for Data common core services. The common core services are installed once in a given Red Hat OpenShift project. If the common core services are not installed in the project where you plan to install Watson Language Translator, the common core services will be automatically installed when you install Watson Language Translator. If the common core services need to be installed, it might take longer to install Watson Language Translator. For more information on the common core services, see:

If you are installing multiple services on your cluster, you must run the installations one at a time and wait until the installation completes before installing another service. You cannot run the installations in parallel.

Tip: For a list of all available options, enter the following command:
./cpd-cli install --help

Procedure

  1. Complete the appropriate steps to install Watson Language Translator on your environment:
  2. Verifying that the installation completed successfully
  3. Complete the tasks listed in What to do next

Installing on clusters connected to the internet

From your installation node:

  1. Change to the directory where you placed the Cloud Pak for Data command-line interface and the repo.yaml file.
  2. Log in to your Red Hat OpenShift cluster as a project administrator:
    oc login OpenShift_URL:port
  3. To install Watson Language Translator, you must run the installer multiple times to install the following assemblies in this order:
    edb-operator
    Installs a EnterpriseDB PostgreSQL server that is used by the Watson Language Translator service. Specify the following additional parameter with the installation command:
    --optional-modules edb-pg-base:x86_64
    For example, the following parameters are required, and you might need additional parameters depending on your environment:
    cpd-cli install --assembly edb-operator --optional-modules edb-pg-base:x86_64 \
    --namespace Project
    minio-operator
    Installs the Minio feature that is used by the Watson Language Translator service. For example, the following parameters are required, and you might need additional parameters depending on your environment:
    cpd-cli install -assembly ibm-minio-operator -namespace Project \
     --storageclass portworx-db-gp2-sc \
    --accept-all-licenses

    Run the following command to see a preview of what will be installed when you install the service.

    Important: If you are using the internal Red Hat OpenShift registry and you are using the default self-signed certificate, specify the --insecure-skip-tls-verify flag to prevent x509 errors.
    ./cpd-cli install \
    --repo ./repo.yaml \
    --assembly watson-language-translator \
    --arch Cluster_architecture \  
    --namespace Project \
    --storageclass Storage_class_name \
    --transfer-image-to Registry_location \
    --cluster-pull-prefix Registry_from_cluster \
    --optional-modules Modules \
    --override Filepath_to_override.yaml \
    --ask-push-registry-credentials \
    --latest-dependency \
    --dry-run
    
    Important: By default, this command gets the latest version of the assembly. If you want to install a specific version of Watson Language Translator, add the following line to your command after the --assembly flag:
    --version Assembly_version \

    The --latest-dependency flag gets the latest version of the dependent assemblies. If you remove the --latest-dependency flag, the installer will get the minimum version of the dependent assemblies.

    Ensure that you use the same flags that your cluster administrator used when they completed Setting up the cluster for Watson Language Translator. If your cluster administrator used the --version flag, ensure that you specify the same version of the assembly.

    When defining the --optional-modules parameter, specify {modules} as a comma separated list of the one or more modules required to support the languages defined in the override file.
    • watson-language-pak-1,watson-language-pak-2,watson-language-pak-3

    Replace the following values:

    Variable Replace with
    Assembly_version
    The version of Watson Language Translator that you want to install. The assembly versions are listed in System requirements for services.
    Cluster_architecture Specify the architecture of your cluster hardware:
    • For x86-64 hardware, remove this flag or specify x86_64
    Project Use the value provided by your cluster administrator. You should have obtained this information when you completed Preparing to install and upgrade services.
    Storage class name Use the value provided by your cluster administrator. You should have obtained this information when you completed Preparing to install and upgrade services.
    Registry_location Use the value provided by your cluster administrator. You should have obtained this information when you completed Preparing to install and upgrade services.
    Registry from cluster Use the value provided by your cluster administrator. You should have obtained this information when you completed Preparing to install and upgrade services.
    Label the namespace:
    oc label --overwrite namespace cpd ns=cpd
  4. Rerun the previous command without the --dry-run flag to install the service.

Installing on air-gapped clusters

From your installation node:

  1. Change to the directory where you placed the Cloud Pak for Data command-line interface.
  2. Log in to your Red Hat OpenShift cluster as a project administrator:
    oc login OpenShift_URL:port
  3. To install Watson Language Translator, you must run the installer multiple times to install the following assemblies in this order:
    edb-operator
    Installs a EnterpriseDB PostgreSQL server that is used by the Watson Language Translator service. Specify the following additional parameter with the installation command:
    --optional-modules edb-pg-base:x86_64
    For example, the following parameters are required, and you might need additional parameters depending on your environment:
    cpd-cli install --assembly edb-operator --optional-modules edb-pg-base:x86_64 \
    --namespace Project
    minio-operator
    Installs the Minio feature that is used by the Watson Language Translator service. For example, the following parameters are required, and you might need additional parameters depending on your environment:
    cpd-cli install -assembly ibm-minio-operator -namespace Project \
     --storageclass portworx-db-gp2-sc \
    --accept-all-licenses

    Run the following command to see a preview of what will be installed when you install the service.

    Important: If you are using the internal Red Hat OpenShift registry:
    • Do not specify the --ask-pull-registry-credentials parameter.
    • If you are using the default self-signed certificate, specify the --insecure-skip-tls-verify flag to prevent x509 errors.
    ./cpd-cli install \
    --assembly watson-language-translator \
    --arch Cluster_architecture \
    --namespace Project \
    --storageclass Storage_class_name \
    --cluster-pull-prefix Registry_from_cluster \
    --optional-modules Modules \
    --override Filepath_to_override.yaml \
    --ask-pull-registry-credentials \
    --load-from Image_directory_location \
    --latest-dependency \
    --dry-run
    
    Note: If the assembly was downloaded using the delta-images command, remove the --latest-dependency flag from the command. If you don't remove the --latest-dependency flag you will get an error indicating that the flag cannot be used.

    Ask your cluster administrator whether they specified the --latest-dependency flag when they completed Setting up the cluster for Watson Language Translator. If they ran the adm command with the --latest-dependency flag, you must also run the install command with the flag.

    When defining the --optional-modules parameter, specify {modules} as a comma separated list of the one or more modules required to support the languages defined in the override file.
    • watson-language-pak-1,watson-language-pak-2,watson-language-pak-3

    Replace the following values:

    Variable Replace with
    Cluster_architecture Specify the architecture of your cluster hardware:
    • For x86-64 hardware, remove this flag or specify x86_64
    Project Use the value provided by your cluster administrator. You should have obtained this information when you completed Preparing to install and upgrade services.
    Storage class name Use the value provided by your cluster administrator. You should have obtained this information when you completed Preparing to install and upgrade services.
    Registry from cluster Use the value provided by your cluster administrator. You should have obtained this information when you completed Preparing to install and upgrade services.
    Image_directory_location The location of the cpd-cli-workspace directory.
  4. Rerun the previous command without the --dry-run flag to install the service.

Verifying that the installation completed successfully

From your installation node:

  1. Run the following command:
    ./cpd-cli status \
    --assembly watson-language-translator \
    --namespace Project

    Replace Project with the value you used in when you installed Watson Language Translator.

    • If the installation completed successfully, the status of the assembly and the modules in the assembly is Ready.
    • If the installation failed, see .

What to do next

  • The service is ready to use, provision an instance of the service, set access levels, and create required connections. For usage details, see the service documentation for more information.