diff --git a/simple/am-single/README.md b/simple/am-single/README.md index abab3c45..2206337a 100644 --- a/simple/am-single/README.md +++ b/simple/am-single/README.md @@ -1,12 +1,11 @@ -# Helm Chart for deployment of WSO2 API Manager with WSO2 API Manager Analytics +# Helm Chart for deployment of WSO2 API Manager -Resources for building a Helm chart for deployment of [All-In-One WSO2 API Manager with WSO2 API Manager Analytics -support](https://apim.docs.wso2.com/en/latest/install-and-setup/setup/deployment-patterns/#pattern-1-single-node-all-in-one-deployment). +Resources for building a Helm chart for deployment of [Single Node API Manager](https://apim.docs.wso2.com/en/latest/install-and-setup/setup/single-node/all-in-one-deployment-overview/#single-node-deployment). -![WSO2 API Manager pattern 1 deployment](https://apim.docs.wso2.com/en/latest/assets/img/setup-and-install/1-single-node-deployment.png) +![WSO2 API Manager pattern 1 deployment](https://apim.docs.wso2.com/en/latest/assets/img/setup-and-install/single-node-apim-deployment.png) For advanced details on the deployment pattern, please refer to the official -[documentation](https://apim.docs.wso2.com/en/latest/install-and-setup/setup/single-node/configuring-an-active-active-deployment/). +[documentation](https://apim.docs.wso2.com/en/latest/install-and-setup/setup/single-node/all-in-one-deployment-overview/#active-active-deployment). ## Contents @@ -58,7 +57,7 @@ You can install the relevant Helm chart either from [WSO2 Helm Chart Repository] Helm version 2 ``` - helm install --name wso2/am-pattern-1 --version 3.2.0-1 --namespace + helm install --name wso2/am-single-node --version 4.0.0-1 --namespace ``` Helm version 3 @@ -66,7 +65,7 @@ You can install the relevant Helm chart either from [WSO2 Helm Chart Repository] - Deploy the Kubernetes resources using the Helm Chart ``` - helm install wso2/am-pattern-1 --version 3.2.0-1 --namespace --create-namespace + helm install wso2/am-single-node --version 4.0.0-1 --namespace --create-namespace ``` The above steps will deploy the deployment pattern using WSO2 product Docker images available at DockerHub. @@ -77,7 +76,7 @@ please provide your WSO2 Subscription credentials via input values (using `--set Please see the following example. ``` - helm install --name wso2/am-pattern-1 --version 3.2.0-1 --namespace --set wso2.subscription.username= --set wso2.subscription.password= + helm install --name wso2/am-single-node --version 4.0.0-1 --namespace --set wso2.subscription.username= --set wso2.subscription.password= ``` #### Install Chart From Source @@ -85,7 +84,7 @@ Please see the following example. >In the context of this document,
>* `KUBERNETES_HOME` will refer to a local copy of the [`wso2/kubernetes-apim`](https://github.com/wso2/kubernetes-apim/) Git repository.
->* `HELM_HOME` will refer to `/advanced`.
+>* `HELM_HOME` will refer to `/simple`.
##### Clone the Helm Resources for WSO2 API Manager Git repository. @@ -98,7 +97,7 @@ git clone https://github.com/wso2/kubernetes-apim.git Helm version 2 ``` - helm install --dep-up --name /am-pattern-1 --version 3.2.0-1 --namespace + helm install --dep-up --name /am-single --version 4.0.0-1 --namespace ``` Helm version 3 @@ -106,7 +105,7 @@ git clone https://github.com/wso2/kubernetes-apim.git - Deploy the Kubernetes resources using the Helm Chart ``` - helm install /am-pattern-1 --version 3.2.0-1 --namespace --dependency-update --create-namespace + helm install /am-single --version 4.0.0-1 --namespace --dependency-update --create-namespace ``` The above steps will deploy the deployment pattern using WSO2 product Docker images available at DockerHub. @@ -117,8 +116,19 @@ please provide your WSO2 Subscription credentials via input values (using `--set Please see the following example. ``` - helm install --name /am-pattern-1 --version 3.2.0-1 --namespace --set wso2.subscription.username= --set wso2.subscription.password= + helm install --name /am-single --version 4.0.0-1 --namespace --set wso2.subscription.username= --set wso2.subscription.password= ``` +### Choreo Analytics + +If you need to enable Choreo Analytics with WSO2 API Manager, please follow the documentation on [Register for Analytics](https://apim.docs.wso2.com/en/latest/observe/api-manager-analytics/configure-analytics/register-for-analytics/) to obtain the on-prem key for Analytics. + +The following example shows how to enable Analytics with the helm charts. + +``` +helm install --name wso2/am-single-node --version 4.0.0-1 --namespace --set wso2.choreoAnalytics.enabled=true --set wso2.choreoAnalytics.endpoint= --set wso2.choreoAnalytics.onpremKey= +``` + +You will be able to see the Analytics data when you log into Choreo Analytics Portal. ### 2. Obtain the external IP @@ -132,25 +142,23 @@ The output under the relevant column stands for the following. API Manager Publisher-DevPortal -- NAME: Metadata name of the Kubernetes Ingress resource (defaults to `wso2am-pattern-1-am-ingress`) +- NAME: Metadata name of the Kubernetes Ingress resource (defaults to `wso2am-single-node-am-ingress`) - HOSTS: Hostname of the WSO2 API Manager service (``) - ADDRESS: External IP (`EXTERNAL-IP`) exposing the API Manager service to outside of the Kubernetes environment - PORTS: Externally exposed service ports of the API Manager service API Manager Gateway -- NAME: Metadata name of the Kubernetes Ingress resource (defaults to `wso2am-pattern-1-am-gateway-ingress`) +- NAME: Metadata name of the Kubernetes Ingress resource (defaults to `wso2am-single-node-am-gateway-ingress`) - HOSTS: Hostname of the WSO2 API Manager's Gateway service (``) - ADDRESS: External IP (`EXTERNAL-IP`) exposing the API Manager's Gateway service to outside of the Kubernetes environment - PORTS: Externally exposed service ports of the API Manager' Gateway service -API Manager Analytics Dashboard - -- NAME: Metadata name of the Kubernetes Ingress resource (defaults to `wso2am-pattern-1-am-analytics-dashboard-ingress`) -- HOSTS: Hostname of the WSO2 API Manager Analytics Dashboard service (``) -- ADDRESS: External IP (`EXTERNAL-IP`) exposing the API Manager Analytics Dashboard service to outside of the Kubernetes environment -- PORTS: Externally exposed service ports of the API Manager Analytics Dashboard service - +API Manager WebSub +- NAME: Metadata name of the Kubernetes Ingress resource (defaults to `wso2am-single-node-am-websub-ingress`) +- HOSTS: Hostname of the WSO2 API Manager's Gateway (WebSub) service (``) +- ADDRESS: External IP (`EXTERNAL-IP`) exposing the API Manager's Gateway service to outside of the Kubernetes environment +- PORTS: Externally exposed service ports of the API Manager' Gateway (WebSub) service ### 3. Add a DNS record mapping the hostnames and the external IP If the defined hostnames (in the previous step) are backed by a DNS service, add a DNS record mapping the hostnames and @@ -160,7 +168,7 @@ If the defined hostnames are not backed by a DNS service, for the purpose of eva hostnames and the external IP in the `/etc/hosts` file at the client-side. ``` - + ``` ### 4. Access Management Consoles @@ -169,9 +177,6 @@ hostnames and the external IP in the `/etc/hosts` file at the client-side. - API Manager DevPortal: `https:///devportal` -- API Manager Analytics Dashboard: `https:///analytics-dashboard` - - ## Configuration The following tables lists the configurable parameters of the chart and their default values. @@ -182,6 +187,9 @@ The following tables lists the configurable parameters of the chart and their de |-----------------------------------------------------------------------------|-------------------------------------------------------------------------------------------|-----------------------------| | `wso2.subscription.username` | Your WSO2 Subscription username | - | | `wso2.subscription.password` | Your WSO2 Subscription password | - | +| `wso2.choreoAnalytics.enabled` | Chorero Analytics enabled or not | false | +| `wso2.choreoAnalytics.endpoint` | Choreo Analytics endpoint | https://analytics-event-auth.choreo.dev/auth/v1 | +| `wso2.choreoAnalytics.onpremKey` | On-prem key for Choreo Analytics | - | If you do not have an active WSO2 subscription, **do not change** the parameters `wso2.subscription.username` and `wso2.subscription.password`. @@ -209,7 +217,7 @@ If you do not have an active WSO2 subscription, **do not change** the parameters |-----------------------------------------------------------------------------|-------------------------------------------------------------------------------------------|-----------------------------| | `wso2.deployment.am.dockerRegistry` | Registry location of the Docker image to be used to create API Manager instances | - | | `wso2.deployment.am.imageName` | Name of the Docker image to be used to create API Manager instances | `wso2am` | -| `wso2.deployment.am.imageTag` | Tag of the image used to create API Manager instances | 3.2.0 | +| `wso2.deployment.am.imageTag` | Tag of the image used to create API Manager instances | 4.0.0 | | `wso2.deployment.am.imagePullPolicy` | Refer to [doc](https://kubernetes.io/docs/concepts/containers/images#updating-images) | `Always` | | `wso2.deployment.am.livenessProbe.initialDelaySeconds` | Initial delay for the live-ness probe for API Manager node | 180 | | `wso2.deployment.am.livenessProbe.periodSeconds` | Period of the live-ness probe for API Manager node | 10 | @@ -224,50 +232,12 @@ If you do not have an active WSO2 subscription, **do not change** the parameters | `wso2.deployment.am.ingress.management.annotations` | Ingress resource annotations for API Manager management consoles | Community NGINX Ingress controller annotations | | `wso2.deployment.am.ingress.gateway.hostname` | Hostname for API Manager Gateway | `gateway.am.wso2.com` | | `wso2.deployment.am.ingress.gateway.annotations` | Ingress resource annotations for API Manager Gateway | Community NGINX Ingress controller annotations | +| `wso2.deployment.am.ingress.websub.hostname` | Hostname for API Manager Gateway WebSub service | `gateway.am.wso2.com` | +| `wso2.deployment.am.ingress.websub.annotations` | Ingress resource annotations for API Manager Gateway WebSub | Community NGINX Ingress controller annotations | **Note**: The above mentioned default, minimum resource amounts for running WSO2 API Manager server profiles are based on its [official documentation](https://apim.docs.wso2.com/en/latest/install-and-setup/install/installation-prerequisites/). -###### Analytics Dashboard Runtime Configurations - -| Parameter | Description | Default Value | -|-------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------|-----------------------------| -| `wso2.deployment.analytics.dashboard.dockerRegistry` | Registry location of the Docker image to be used to create an API Manager Analytics instance | - | -| `wso2.deployment.analytics.dashboard.imageName` | Name of the Docker image to be used to create an API Manager Analytics instance | `wso2am-analytics-dashboard` | -| `wso2.deployment.analytics.dashboard.imageTag` | Tag of the image used to create an API Manager Analytics instance | 3.2.0 | -| `wso2.deployment.analytics.dashboard.imagePullPolicy` | Refer to [doc](https://kubernetes.io/docs/concepts/containers/images#updating-images) | `Always` | -| `wso2.deployment.analytics.dashboard.replicas` | Number of replicas of API Manager Analytics to be started | 1 | -| `wso2.deployment.analytics.dashboard.strategy.rollingUpdate.maxSurge` | Refer to [doc](https://v1-14.docs.kubernetes.io/docs/reference/generated/kubernetes-api/v1.14/#deploymentstrategy-v1-apps) | 1 | -| `wso2.deployment.analytics.dashboard.strategy.rollingUpdate.maxUnavailable` | Refer to [doc](https://v1-14.docs.kubernetes.io/docs/reference/generated/kubernetes-api/v1.14/#deploymentstrategy-v1-apps) | 0 | -| `wso2.deployment.analytics.dashboard.livenessProbe.initialDelaySeconds` | Initial delay for the live-ness probe for API Manager Analytics node | 20 | -| `wso2.deployment.analytics.dashboard.livenessProbe.periodSeconds` | Period of the live-ness probe for API Manager Analytics node | 10 | -| `wso2.deployment.analytics.dashboard.readinessProbe.initialDelaySeconds` | Initial delay for the readiness probe for API Manager Analytics node | 20 | -| `wso2.deployment.analytics.dashboard.readinessProbe.periodSeconds` | Period of the readiness probe for API Manager Analytics node | 10 | -| `wso2.deployment.analytics.dashboard.resources.requests.memory` | The minimum amount of memory that should be allocated for a Pod | 4Gi | -| `wso2.deployment.analytics.dashboard.resources.requests.cpu` | The minimum amount of CPU that should be allocated for a Pod | 2000m | -| `wso2.deployment.analytics.dashboard.resources.limits.memory` | The maximum amount of memory that should be allocated for a Pod | 4Gi | -| `wso2.deployment.analytics.dashboard.resources.limits.cpu` | The maximum amount of CPU that should be allocated for a Pod | 2000m | -| `wso2.deployment.analytics.dashboard.config` | Custom deployment configuration file (`/conf/dashboard/deployment.yaml`) | - | -| `wso2.deployment.analytics.dashboard.ingress.hostname` | Hostname for API Manager Analytics Dashboard | `analytics.am.wso2.com` | -| `wso2.deployment.analytics.dashboard.ingress.annotations` | Ingress resource annotations for API Manager Analytics Dashboard | Community NGINX Ingress controller annotations | - -###### Analytics Worker Runtime Configurations - -| Parameter | Description | Default Value | -|----------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------|-----------------------------| -| `wso2.deployment.analytics.worker.dockerRegistry` | Registry location of the Docker image to be used to create an API Manager Analytics instance | - | -| `wso2.deployment.analytics.worker.imageName` | Name of the Docker image to be used to create an API Manager Analytics instance | `wso2am-analytics-worker` | -| `wso2.deployment.analytics.worker.imageTag` | Tag of the image used to create an API Manager Analytics instance | 3.2.0 | -| `wso2.deployment.analytics.worker.imagePullPolicy` | Refer to [doc](https://kubernetes.io/docs/concepts/containers/images#updating-images) | `Always` | -| `wso2.deployment.analytics.worker.livenessProbe.initialDelaySeconds` | Initial delay for the live-ness probe for API Manager Analytics node | 20 | -| `wso2.deployment.analytics.worker.livenessProbe.periodSeconds` | Period of the live-ness probe for API Manager Analytics node | 10 | -| `wso2.deployment.analytics.worker.readinessProbe.initialDelaySeconds` | Initial delay for the readiness probe for API Manager Analytics node | 20 | -| `wso2.deployment.analytics.worker.readinessProbe.periodSeconds` | Period of the readiness probe for API Manager Analytics node | 10 | -| `wso2.deployment.analytics.worker.resources.requests.memory` | The minimum amount of memory that should be allocated for a Pod | 4Gi | -| `wso2.deployment.analytics.worker.resources.requests.cpu` | The minimum amount of CPU that should be allocated for a Pod | 2000m | -| `wso2.deployment.analytics.worker.resources.limits.memory` | The maximum amount of memory that should be allocated for a Pod | 4Gi | -| `wso2.deployment.analytics.worker.resources.limits.cpu` | The maximum amount of CPU that should be allocated for a Pod | 2000m | - -###### Kubernetes Specific Configurations +## Kubernetes Specific Configurations | Parameter | Description | Default Value | |---------------------------------------------------------------|-------------------------------------------------------------------------------------------|---------------------------------| diff --git a/simple/am-single/templates/NOTES.txt b/simple/am-single/templates/NOTES.txt index bb9b557e..63bb20c5 100644 --- a/simple/am-single/templates/NOTES.txt +++ b/simple/am-single/templates/NOTES.txt @@ -1,6 +1,6 @@ Thank you for installing WSO2 API Manager. -Please follow these steps to access API Manager Publisher, DevPortal consoles and Analytics Dashboard. +Please follow these steps to access API Manager Publisher, DevPortal consoles. 1. Obtain the external IP (`EXTERNAL-IP`) of the API Manager Ingress resources, by listing down the Kubernetes Ingresses. diff --git a/simple/am-single/templates/am/instance/wso2am-single-node-am-conf.yaml b/simple/am-single/templates/am/instance/wso2am-single-node-am-conf.yaml index f4b52e74..50dedcda 100644 --- a/simple/am-single/templates/am/instance/wso2am-single-node-am-conf.yaml +++ b/simple/am-single/templates/am/instance/wso2am-single-node-am-conf.yaml @@ -123,11 +123,18 @@ data: #[apim.cache.tags] #expiry_time = "2m" - + + {{ if .Values.wso2.choreoAnalytics.enabled }} + [apim.analytics] + enable = true + config_endpoint = "{{ .Values.wso2.choreoAnalytics.endpoint }}" + auth_token = "{{ .Values.wso2.choreoAnalytics.onpremKey }}" + {{ else }} [apim.analytics] enable = false - config_endpoint = "https://localhost:8080/auth/v1" + config_endpoint = "https://analytics-event-auth.choreo.dev/auth/v1" auth_token = "" + {{ end }} #[apim.key_manager] #service_url = "https://localhost:${mgt.transport.https.port}/services/" diff --git a/simple/am-single/values.yaml b/simple/am-single/values.yaml index b6de1a8d..ecd00ddb 100644 --- a/simple/am-single/values.yaml +++ b/simple/am-single/values.yaml @@ -20,6 +20,11 @@ wso2: username: "" password: "" + choreoAnalytics: + enabled: false + endpoint: "" + onpremKey: "" + deployment: dependencies: # The configuration should be set to be 'true' if a MySQL database should be spawned as a pod within the cluster @@ -50,9 +55,9 @@ wso2: am: # Container image configurations # If a custom image must be used, uncomment 'dockerRegistry' and provide its value - dockerRegistry: "192.168.1.5:5000" + # dockerRegistry: "" imageName: "wso2am" - imageTag: "4.0.0-rc" + imageTag: "4.0.0" # Refer to the Kubernetes documentation on updating images (https://kubernetes.io/docs/concepts/containers/images/#updating-images) imagePullPolicy: Always