|
| 1 | +# Weblogic Domain Helm Chart |
| 2 | +This chart creates a single Weblogic domain on a [Kubernetes](https://kubernetes.io/) cluster using the |
| 3 | +[Helm](https://github.com/kubernetes/helm) package manager. |
| 4 | + |
| 5 | +## Prerequisites |
| 6 | +- Kubernetes 1.7.5+ with Beta APIs enabled |
| 7 | + |
| 8 | +- Install [Helm](https://github.com/kubernetes/helm#install) |
| 9 | + |
| 10 | +- Initialize Helm by installing Tiller, the server portion of Helm, to your Kubernetes cluster |
| 11 | + |
| 12 | +```bash |
| 13 | +helm init |
| 14 | +``` |
| 15 | +- Install of the weblogic-operator helm chart |
| 16 | + |
| 17 | +## Creating a Namespace |
| 18 | +We recommend that you create a namespace to run your WebLogic Domain(s) in. |
| 19 | +You may wish to maintain a one to one relationship between WebLogic Domains |
| 20 | +and Kubernetes namespaces, but this is not required. You may run more than |
| 21 | +one WebLogic Domain in a single namespace if you wish to. |
| 22 | + |
| 23 | +To create a namespace named `my-namespace`: |
| 24 | + |
| 25 | +```bash |
| 26 | +kubectl create namespace my-namespace |
| 27 | +``` |
| 28 | + |
| 29 | +## Setting a Secret for the Admin Server |
| 30 | +You must setup the Admin Server `username` and `password` credentials as a Kubernetes secret. |
| 31 | + |
| 32 | +To create a secret named `my-secret` in the namespace `my-namespace`: |
| 33 | + |
| 34 | +```bash |
| 35 | +kubectl create secret generic my-secret --from-literal=username=ADMIN-USERNAME --from-literal=password=ADMIN-PASSWORD --namespace my-namespace |
| 36 | +``` |
| 37 | +In this command, you must replace the uppercase items with your |
| 38 | +own values. The secret name will be needed when installing the helm chart. |
| 39 | + |
| 40 | +## Installing the Chart |
| 41 | +Clone the git weblogic-operator repo: |
| 42 | + |
| 43 | +```bash |
| 44 | +git clone https://github.com/oracle/weblogic-kubernetes-operator.git |
| 45 | +``` |
| 46 | + |
| 47 | +Change directory to the cloned git weblogic-operator repo: |
| 48 | + |
| 49 | +```bash |
| 50 | +cd weblogic-operator/kubernetes/helm-charts |
| 51 | +``` |
| 52 | + |
| 53 | +To install the chart with the release `my-release`, namespace `my-namespace` and secret `my-secret' without creating a weblogic domain (such as when a WebLogic domain already exists): |
| 54 | + |
| 55 | +```bash |
| 56 | +helm install weblogic-domain --name my-release --namespace my-namespace --set secretName=my-secret --set createWeblogicDomain=false |
| 57 | +``` |
| 58 | + |
| 59 | +The command deploys weblogic-domain on the Kubernetes cluster in the default configuration. The [configuration](#configuration) section lists |
| 60 | +the parameters that can be configured during installation. |
| 61 | + |
| 62 | +> Note: if you do not pass the --name flag, a release name will be auto-generated. You can view releases by running helm list (or helm ls, for short). |
| 63 | +
|
| 64 | + |
| 65 | +## Uninstalling the Chart |
| 66 | +To uninstall/delete the `my-release` deployment: |
| 67 | + |
| 68 | +```bash |
| 69 | +helm delete --purge my-release |
| 70 | +``` |
| 71 | + |
| 72 | +The command removes all the Kubernetes components associated with the chart and deletes the release. |
| 73 | + |
| 74 | +## Configuration |
| 75 | +| Key | Description | Default | |
| 76 | +| -------------------------------|-----------------------------------|-----------------------| |
| 77 | +| createWeblogicDomain | Boolean indicating if a weblogic domain should be created | true | |
| 78 | +| adminNodePort | NodePort to expose for the admin server | 30701 | |
| 79 | +| adminPort | Port number for Admin Server | 7001 | |
| 80 | +| adminServerName | Name of the Admin Server | admin-server | |
| 81 | +| clusterName | Cluster name | cluster-1 | |
| 82 | +| createDomainScript | Script used to create the domain | /u01/weblogic/create-domain-script.sh | |
| 83 | +| domainName | Name of the WebLogic domain to create | base_domain | |
| 84 | +| domainUid | Unique id identifying a domain. The id must be unique across all domains in a Kubernetes cluster | domain1 | |
| 85 | +| exposeAdminT3Channel | Boolean to indicate if the channel should be exposed as a service | false | |
| 86 | +| exposeAdminNodePort | Boolean to indicate if the adminNodePort will be exposed | false | |
| 87 | +| imagePullSecretName | Name of the Kubernetes secret to access the Docker Store to pull the Weblogic Docker image | | |
| 88 | +| loadBalancer | Load balancer to deploy. Supported values are: traefik, none | traefik | |
| 89 | +| loadBalancerAdminPort | Load balancer admin port | 30315 | |
| 90 | +| loadBalancerWebPort| Load balancer web port | 30305 | |
| 91 | +| managedServerCount | Number of managed servers to generate for the domain | 2 | |
| 92 | +| managedServerStartCount | Number of managed severs to initially start for a domain | 2 | |
| 93 | +| managedServerNameBase | Base string used to generate managed server names | managed-server | |
| 94 | +| managedServerPort | Port number for each managed server | 8001 | |
| 95 | +| persistencePath | Physical path of the persistent volume storage | /scratch/k8s_dir/persistentVolume001 | |
| 96 | +| persistenceSize | Total storage allocated by the persistent volume | 10Gi | |
| 97 | +| productionModeEnabled | Boolean indicating if production mode is enabled for the domain | true | |
| 98 | +| secretName | Name of the Kubernetes secret for the Admin Server's username and password | domain1-weblogic-credentials | |
| 99 | +| t3ChannelPort | Port for the T3Channel of the NetworkAccessPoint | 30012 | |
| 100 | +| t3PublicAddress | Public address for T3Channel of the NetworkAccessPoint. This value should be set to the Kubernetes server address, which you can get by running "kubectl cluster-info". If this value is not set to that address, WLST will not be able to connect from outside the Kubernetes cluster | kubernetes | |
| 101 | + |
| 102 | +Specify parameters to override default values using the `--set key=value[,key=value]` argument to helm install. For example: |
| 103 | + |
| 104 | +```bash |
| 105 | +helm install weblogic-domain --name my-release --namespace my-namespace --set managedServerCount=3 |
| 106 | +``` |
| 107 | + |
| 108 | +Alternatively, a YAML file that specifies the values for the parameters can be provided while installing the chart. For example: |
| 109 | + |
| 110 | +```bash |
| 111 | +helm install weblogic-domain --name my-release --namespace my-namespace --values values.yaml |
| 112 | +``` |
0 commit comments