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
- Locate the next-generation Order Hub source code. The default location is
devtoolkit_docker/orderhub-code.
-
Update the package-customization.json file for every module that is
customized.
-
Open the
<order_hub_code_directory>/<module-name>/package-customization.json
file for each customized module.
-
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 that is called
type. Make sure 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.
-
Update the package.json file for every route that is customized.
-
Open the ../<module-name>/packages/<route-name>/package.json file
for each customized route.
-
Locate the build-merged script within the file.
-
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 your customizations. For more information, see Building customizations in next-generation Order Hub.