Deploying CDP JavaScript SDK
This section provides detailed instructions on how to deploy HCL CDP JavaScript SDK using the Devtron in the OpenShift.
Before you begin
Make sure to create the cdp-javascript-sdk secret in the HashiCorp vault before deploying the cdp-javascript-sdk.

To create the cdp-javascript-sdk secret in the HashiCorp Vault, follow the steps below:
- Create a cdp-javascript-sdk secret sample key and value in the cdp-javascript-sdk
secret shown below, and update the actual values.
{ "CDN_KEY": "", "CDN_PURGE_AUTH_KEY": "", "CF_BucketName": "cdn", "CF_CLOUDFRONT_DISTRIBUTION_ID": "<cloudfront distribution id>", "CF_PATH": "testing", "DATABASE_HOST": "", "DATABASE_PASSWORD": "<database password>", "DATABASE_USERNAME": "cdpapp_ro" } - Create a Kubernetes Secret with Vault credentials to fetch the secrets from the
HashiCorp vault Secret
manager.
apiVersion: v1 kind: Secret metadata: name: vault-creds namespace: cdp-dev-app type: Opaque data: username: <vault username> password: <vault password> - Create separate service account say cdp-dev-app-sa, with appropriate roles and permissions, and update ConfigMaps data with actual values.
Procedure
-
Navigate to the Devtron Chart Store, and select the cdp-javascript-sdk
chart to deploy.

-
Configure and deploy the cdp-javascript-sdk charts.
-
In the YAML section, update the ConfigMap using below details and deploy
the charts.
AWS_ACCESS_KEY: "" AWS_REGION: ap-south-1 AWS_SECRET_ACCESS_KEY: "" BUCKET_TYPE: minio CDN_HOST: "" CDN_KEY_NAME: "" CDN_PATH: "" CDN_PREFIX: "" CDN_SMT_HANDLER: "" DATABASE_DIALECT: mysql DATABASE_NAME: vrm DATABASE_PORT: "3306" ENDPOINT_URL: http://minio.minio-operator:80 MODE: DEVELOPMENT -
On successful deployment, validate the deployment as shown below.