You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -131,6 +135,14 @@ The following steps will build the sample application and create a Docker image
131
135
## Part 1B: Upload the Docker image to OKD's internal registry
132
136
133
137
OKD provides an internal, integrated container image registry. For this lab, we will use this registry to host our application image.
138
+
**NOTE:** If you are running the lab on the same VM as OKD, run the following two commands and then skip to the next section.
139
+
1. Tag your docker image:
140
+
```bash
141
+
docker tag microservice-vote:1.0.0 docker-registry.default.svc:5000/myproject/microservice-vote:1.0.0
142
+
```
143
+
1. Your image is now available in the internal registry in OKD. You can verify this through the OKD's Registry Dashboard available at `https://registry-console-default.apps.<okd_ip>.nip.io/registry`. You can use the same username and password as the one used in `oc login` command.
144
+
145
+
Run the following steps **only** if you are running the lab on a system other than the OKD VM:
134
146
135
147
1. Ensure you are logged in to OKD. You can use OKD command line interface (CLI) to interact with the cluster. Replace `<username>`, `<password>` and `<okd_ip>` with appropriate values:
136
148
```console
@@ -152,7 +164,7 @@ OKD provides an internal, integrated container image registry. For this lab, we
1. Your image is now available in the internal registry in OKD. You can verify this through the OKD's Registry Dashboard available at `https://registry-console-default.apps.<okd_ip>.nip.io/registry`. You can use the same username and password as the one used in `oc login` command. You Should see
167
+
1. Your image is now available in the internal registry in OKD. You can verify this through the OKD's Registry Dashboard available at `https://registry-console-default.apps.<okd_ip>.nip.io/registry`. You can use the same username and password as the one used in `oc login` command.
156
168
157
169
## Part 2: Deploy Open Liberty operator and and CouchDB Helm chart
158
170
@@ -194,30 +206,35 @@ In this section, we will deploy CouchDB Helm chart. However, as OKD does not com
194
206
Rollout process might take a few minutes to complete. You can check the status of the deployment using `oc get deployment`.
195
207
1. If things go well, the following commands should run successfully and you will see version of both the client and the server:
196
208
```console
197
-
$ helm version
209
+
$ helm version --tiller-namespace=tiller
198
210
```
211
+
Since we did not install Tiller in its default namespace (`kube-system`), we had to specify `--tiller-namespace=tiller`. Alternatively, you can run `export TILLER_NAMESPACE=tiller` instead of specifying `--tiller-namespace=tiller` in your Helm commands.
199
212
1. Grant the Tiller server `edit` and `admin` access to the current project:
Ensure the CouchDB pod is up and running by executing `kubectl get pods` command. Your output will look similar to the following:
223
240
```console
@@ -241,6 +258,8 @@ Now that Helm is configured both locally and on OKD, you can deploy CouchDB Helm
241
258
$ kubectl apply -f deploy/
242
259
```
243
260
261
+
You would need to wait for the Open Liberty Operator installation to be completed. You can check the status using `kubectl get pods` and wait until the `open-liberty-operator` pod is ready.
262
+
244
263
#### Deploy application
245
264
246
265
1. Deploy the microservice application using the provided CR:
@@ -249,7 +268,7 @@ Now that Helm is configured both locally and on OKD, you can deploy CouchDB Helm
249
268
$ kubectl apply -f application-cr.yaml
250
269
```
251
270
1. You can view the status of your deployment by running `kubectl get deployments`. If the deployment is not coming up after a few minutes one way to debug what happened is to query the pods with `kubectl get pods` and then fetch the logs of the Liberty pod with `kubectl logs <pod>`.
252
-
1. We will access the application using NodePort service. To do that, simply find the NodePort port by finding out your service name with `kubectl get services` and then running the command `kubectl describe service <myservice> | grep NodePort | awk 'FNR == 2 {print $3;}' | awk -F '/' '{print $1;}'` and then inserting that port in your current URL using `http`, for example `http://9.8.7.6.nip.io:30698/openapi/ui/`. If those invocations are still taking long, please wait a few minutes for the deployment to fully initiate.
271
+
1. We will access the application using NodePort service. To do that, simply find the NodePort port by finding out your service name with `kubectl get services` and then running the command `kubectl describe service <myservice> | grep NodePort | awk 'FNR == 2 {print $3;}' | awk -F '/' '{print $1;}'` and then inserting that port in your current URL using `http`, for example `https://console.<okd_ip>.nip.io:30698/openapi/ui/`. If those invocations are still taking long, please wait a few minutes for the deployment to fully initiate.
253
272
1. Congratulations! You have successfully deployed a [MicroProfile](http://microprofile.io/) container into an OKD cluster using operators!
0 commit comments