Preparing to deploy customizations for existing applications

Before you can deploy customizations that you made to existing applications (like <order_hub_code_directory>/buc-app-order), you need to indicate which customizations to deploy. For example, you can be working on two new routes but you might want to deploy only one.

Procedure

  1. Update the package-customization.json file for every module that is customized.
    1. Open the <order_hub_code_directory>/<module-name>/package-customization.json file for each customized module.
      Where the Order Hub source code is available in the following location:
      • For containers, the default location is devtoolkit_docker/orderhub-code.
      • For traditional, this is the directory where the on-prem-source.tar file was extracted.

      After you have identified the location of the Order Hub source code in your environment, this location is denoted by <order_hub_code_directory>.

    2. In the routes object, add every route in the module that is customized.
      Each key in the routes object identifies the customized route package. The value is an object with a single key called type. Ensure that the type property is always set to "code".

      For example,

      {
          "repositoryName": "buc-app-order",
          "customizationContextRoot": "/order-management-customization",
          "routes": {
              "create-order": {
                  "type": "code"
              }
          }
      }
      The customizationContextRoot object is preset to /order-management-customization. Do not change the value.
  2. Update the package.json file for every route that is customized.
    1. Open the ../<module-name>/packages/<route-name>/package.json file for each customized route.
    2. Locate the build-merged script within the file.
    3. Add the following parameter to the script.
      --deploy-url=/order-management-customization/<module-name>/<route-name>/
      For example,
      "build-merged": "ng build create-order --configuration=merged-prod --deploy-url=/order-management-customization/buc-app-order/create-order/",

What to do next

Build customizations. For more information, see Building the customizations.