Skip to content

Commit b807195

Browse files
committed
More updates
1 parent ea0757a commit b807195

File tree

5 files changed

+71
-89
lines changed

5 files changed

+71
-89
lines changed
Lines changed: 9 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -1,59 +1,11 @@
1-
== Demonstrating Retail example applications
1+
---
2+
title: Demonstrating Retail example applications
3+
weight: 10
4+
aliases: /retail/application-demos/
5+
---
26

3-
=== Background
7+
:toc:
8+
:imagesdir: /images
9+
:_content-type: ASSEMBLY
10+
include::modules/comm-attributes.adoc[]
411

5-
Up until now the Retail validated pattern has focused primarily on
6-
successfully deploying the architectural pattern. Now it is time to see
7-
the actual applications running as we have deployed them.
8-
9-
If you have already deployed the hub cluster, then you have already seen
10-
several applications deployed in the OpenShift GitOps console. If you
11-
haven’t done this then we recommend you deploy the hub after you have
12-
setup the Quay repositories described below.
13-
14-
=== Ordering Items at the Coffeeshop
15-
16-
The easiest way to get to the coffeeshop store page is from the
17-
OpenShift Console Menu Landing Page entry:
18-
19-
link:/images/retail/retail-v1-console-menu.png[image:/images/retail/retail-v1-console-menu.png[retail-v1-console-menu]]
20-
21-
Clicking on the Quarkus Coffeeshop Landing Page link will bring you to
22-
this page:
23-
24-
link:/images/retail/retail-v1-landing-page.png[image:/images/retail/retail-v1-landing-page.png[retail-v1-landing-page]]
25-
26-
And clicking on either the "`Store Web Page`" or "`TEST Store Web Page`"
27-
links will bring you to a screen that looks like this:
28-
29-
link:/images/retail/retail-v1-store-page.png[image:/images/retail/retail-v1-store-page.png[retail-v1-store-page]]
30-
31-
_NOTE_: The applications are initially identical. The "`TEST`" site is
32-
deployed to the `+quarkuscoffeeshop-demo+` namespace; the regular Store
33-
site is deployed to the `+quarkuscoffeeshop-store+` namespace.
34-
35-
Each store requires supporting services, in PostgreSQL and Kafka. In our
36-
pattern, PostgreSQL is provided by the Crunchy PostgreSQL operator, and
37-
Kafka is provided by the Red Hat AMQ Streams operator. Each instance,
38-
the regular instance and the TEST instance, has its own instance of each
39-
of these supporting services it uses.
40-
41-
To order, click on the "`Place an Order`" button on the front page. The
42-
menu should look like this:
43-
44-
link:/images/retail/retail-v1-store-web-menu.png[image:/images/retail/retail-v1-store-web-menu.png[retail-v1-store-web-menu]]
45-
46-
Click the "`Add`" button next to a menu item; the item name will appear.
47-
Add a name for the order:
48-
49-
link:/images/retail/retail-v1-order-p1.png[image:/images/retail/retail-v1-order-p1.png[retail-v1-order-p1]]
50-
51-
You can add as many orders as you want. On your last item, click the
52-
"`Place Order`" button on the item dialog:
53-
54-
link:/images/retail/retail-v1-place-order.png[image:/images/retail/retail-v1-place-order.png[retail-v1-place-order]]
55-
56-
As the orders are serviced by the barista and kitchen services, you can
57-
see their status in the "`Orders`" section of the page:
58-
59-
link:/images/retail/retail-v1-orders-status.png[image:/images/retail/retail-v1-orders-status.png[retail-v1-orders-status]]

content/patterns/retail/getting-started.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Getting Started
33
weight: 10
4-
aliases: /travelops/getting-started/
4+
aliases: /retail/getting-started/
55
---
66

77
:toc:

content/patterns/retail/store.adoc

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ include::modules/comm-attributes.adoc[]
1616
A store ("`ATLANTA`") is installed on the hub cluster by default. This feature is interesting if you want to see how ACM can manage a remote
1717
cluster to install the same application on a different cluster.
1818

19-
The way we apply this is through the managedClusterGroups block in `values-hub.yaml`:
19+
The way we apply this is through the `managedClusterGroups` block in `values-hub.yaml`:
2020
+
2121
[source,yaml]
2222
----
@@ -37,16 +37,16 @@ The way we apply this is through the managedClusterGroups block in `values-hub.y
3737
- OpenShift
3838
----
3939

40-
Any cluster joined with the label `clusterGroup=store-raleigh` will be assigned the policies that deploy the store app to them.
40+
Any cluster joined with the label `clusterGroup=store-raleigh` is assigned the policies that deploy the store app to them.
4141

4242
[id="attach-managed-cluster"]
43-
= Attach a managed cluster (edge) to the management hub
43+
=== Attaching a managed cluster (edge) to the management hub
4444

45-
The use of this Multicloud GitOps pattern depends on having at least one running Red Hat OpenShift cluster.
45+
The use of this pattern depends on having at least one running Red Hat OpenShift cluster.
4646

47-
When you install the multi-cloud GitOps pattern, a hub cluster is setup. The hub cluster serves as the central point for managing and deploying applications across multiple clusters.
47+
When you install the retail GitOps pattern, a hub cluster is setup. The hub cluster serves as the central point for managing and deploying applications across multiple clusters.
4848

49-
include::modules/mcg-understanding-rhacm-requirements.adoc[leveloffset=+1]
49+
include::modules/retail-understanding-rhacm-requirements.adoc[leveloffset=+1]
5050

5151
include::modules/mcg-deploying-managed-cluster-using-rhacm.adoc[leveloffset=+1]
5252

@@ -70,7 +70,7 @@ It might take a while for the RHACM agent and `agent-addons` to launch.
7070

7171
==== You’re done
7272

73-
That’s it! Go to your store (edge) OpenShift console and check for the open-cluster-management-agent pod being launched. Be patient, it will
74-
take a while for the ACM agent and agent-addons to launch. After that, the operator OpenShift GitOps will run. When it’s finished coming up
73+
That is it! Go to your store (edge) OpenShift console and check for the open-cluster-management-agent pod being launched. Be patient, it will
74+
take a while for the ACM agent and agent-addons to launch. After that, the operator OpenShift GitOps will run. When it is finished coming up
7575
launch the OpenShift GitOps (ArgoCD) console from the top right of the
7676
OpenShift console.

modules/retail-about.adoc

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,12 @@ It is derived from the https://quarkuscoffeeshop.github.io[Quarkus Coffeeshop De
1010

1111
This demo pulls together several different strands of the demo and allows for multiple stores to be installed on remote clusters via ACM if the user desires.
1212

13-
The demo allows users to go to the store’s web page, order drinks and food items, and see those items `made` and served by the microservices in real time.
14-
15-
The pattern includes build pipelines and a demo space, so that changes to the applications can be tested prior to `production` deployments.
13+
The demo allows users to go to the store’s web page, order drinks and food items, and see those items `made` and served by the microservices in real time. The pattern includes build pipelines and a demo space, so that changes to the applications can be tested prior to `production` deployments.
1614

1715
[id="solution-elements"]
1816
== Solution elements
1917

20-
* How to use a GitOps approach to keep in control of configuration and
21-
operations
18+
* How to use a GitOps approach to keep in control of configuration and operations
2219
* How to centrally manage multiple clusters, including workloads
2320
* How to build and deploy workloads across clusters using modern CI/CD
2421
* How to architect a modern application using microservices and Kafka in Java

modules/retail-deploying.adoc

Lines changed: 51 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,43 @@
88

99
* An OpenShift cluster
1010
** To create an OpenShift cluster, go to the https://console.redhat.com/[Red Hat Hybrid Cloud console].
11-
** Select *Services \-> Containers \-> Create cluster*.
12-
** The cluster must have a dynamic `StorageClass` to provision `PersistentVolumes`. See link:../../multicloud-gitops/mcg-cluster-sizing[sizing your cluster].
11+
** Select *OpenShift \-> Red Hat OpenShift Container Platform \-> Create cluster*.
12+
** The cluster must have a dynamic `StorageClass` to provision `PersistentVolumes`. Verify that a dynamic StorageClass exists before creating one by running the following command:
13+
+
14+
[source,terminal]
15+
----
16+
$ oc get storageclass -o custom-columns=NAME:.metadata.name,PROVISIONER:.provisioner,DEFAULT:.metadata.annotations."storageclass\.kubernetes\.io/is-default-class"
17+
----
18+
+
19+
.Example output
20+
+
21+
[source,terminal]
22+
----
23+
NAME PROVISIONER DEFAULT
24+
gp2-csi ebs.csi.aws.com <none>
25+
gp3-csi ebs.csi.aws.com true
26+
----
27+
+
28+
For more information about creating a dynamic `StorageClass`, see the https://docs.openshift.com/container-platform/latest/storage/dynamic-provisioning.html[Dynamic provisioning] documentation.
29+
1330
* Optional: A second OpenShift cluster for multicloud demonstration.
1431
//Replaced git and podman prereqs with the tooling dependencies page
32+
* Optional: A quay account that can update images; this is if you want to use the pipelines to customize the applications.
33+
* Optional: A quay account with the following repositories set as public, and which you can write to:
34+
** quay.io/your-quay-username/quarkuscoffeeshop-barista
35+
** quay.io/your-quay-username/quarkuscoffeeshop-counter
36+
** quay.io/your-quay-username/quarkuscoffeeshop-inventory
37+
** quay.io/your-quay-username/quarkuscoffeeshop-web
38+
** quay.io/your-quay-username/quarkuscoffeeshop-customerloyalty
39+
** quay.io/your-quay-username/quarkuscoffeeshop-kitchen
40+
** quay.io/your-quay-username/quarkuscoffeeshop-majestic-monolith
41+
** quay.io/your-quay-username/quarkuscoffeeshop-monolith
42+
+
43+
[NOTE]
44+
====
45+
These repos contain the demo's microservices. The public repos (`quay.io/hybridcloudpatterns/*`) provide pre-built images used by default, allowing the demo to run without rebuilding the apps. Creating your own quay copies offers transparency and lets you reproduce results or customize the apps.
46+
====
47+
1548
* https://validatedpatterns.io/learn/quickstart/[Install the tooling dependencies].
1649

1750
The use of this pattern depends on having at least one running Red Hat OpenShift cluster. However, consider creating a cluster for deploying the GitOps management hub assets and a separate cluster for the managed cluster.
@@ -26,20 +59,20 @@ If you do not have a running Red Hat OpenShift cluster, you can start one on a p
2659
+
2760
[source,terminal]
2861
----
29-
git clone [email protected]:your-username/retail.git
62+
$ git clone [email protected]:your-username/retail.git
3063
----
3164

3265
. Create a local copy of the secret values file that can safely include credentials. Run the following commands:
3366
+
3467
[source,terminal]
3568
----
36-
cp values-secret.yaml.template ~/values-secret.yaml
69+
$ cp values-secret.yaml.template ~/values-secret.yaml
3770
----
3871

3972
. Edit `values-secret.yaml` populating with your quay `username` and `password`.
4073
+
4174
[source,yaml]
42-
---
75+
----
4376
# NEVER COMMIT THESE VALUES TO GIT
4477
version: "2.0"
4578
secrets:
@@ -53,7 +86,7 @@ secrets:
5386
value: "my-quay-password"
5487
----
5588
+
56-
[WARNING]
89+
[NOTE]
5790
====
5891
Do not commit this file. You do not want to push personal credentials to GitHub.
5992
====
@@ -74,9 +107,9 @@ $ git switch -c my-branch
74107
$ vi values-global.yaml
75108
----
76109
+
77-
The values that you need to change are under the `imageregistry` key, to use your own account and hostname. If you like, you can change the `git` settings of `account`, `email` and `hostname` to reflect your own account settings.
78-
79-
If you plan to customize the build of the applications themselves, there are `revision` and `imageTag` settings for each of them. The defaults should suffice if you just want to see the apps running.
110+
The defaults should suffice if you just want to see the apps running. The values that you might change are under the `imageregistry`, if you copied the images to your own quay account and hostname. If you like, you can change the `git` settings of `account`, `email` and `hostname` to reflect your own account settings.
111+
+
112+
If you plan to customize the build of the applications themselves, there are `revision` and `imageTag` settings for each of them.
80113

81114
.. Stage the changes to the `values-hub.yaml` file by running the following commands:
82115
+
@@ -140,30 +173,30 @@ $ ./pattern.sh make install
140173

141174
.. Set your project to `All Projects` and verify the operators are installed and have a status of `Succeeded`.
142175
+
143-
link:/images/retail/retail-v1-operators.png[image:/images/retail/retail-v1-operators.png[retail-v1-operators]]
176+
link:/images/retail/retail-v1-operators.png[image:/images/retail/retail-v1-operators.png[retail-v1-operators]
144177

145-
. Track the progress through the Hub ArgoCD UI from the nines menu.:
178+
. Track the progress through the Hub ArgoCD UI from the nines menu:
146179
+
147-
link:/images/retail/retail-v1-console-menu.png[image:/images/retail/retail-v1-console-menu.png[retail-v1-console-menu]]
180+
link:/images/retail/retail-v1-console-menu.png[image:/images/retail/retail-v1-console-menu.png[retail-v1-console-menu]
148181

149-
Ensure that the Hub ArgoCD instance shows all of its apps in Healthy and Synced status once all of the images have been built:
182+
. Ensure that the Hub ArgoCD instance shows all of its apps in Healthy and Synced status once all of the images have been built:
150183
+
151-
link:/images/retail/retail-v1-argo-apps-p1.png[image:/images/retail/retail-v1-argo-apps-p1.png[retail-v1-argo-apps-p1]]
184+
link:/images/retail/retail-v1-argo-apps-p1.png[image:/images/retail/retail-v1-argo-apps-p1.png[retail-v1-argo-apps-p1]
152185

153186
. Check on the pipelines, if you chose to run them. They should all complete successfully:
154187
+
155-
link:/images/retail/retail-v1-pipelines.png[image:/images/retail/retail-v1-pipelines.png[retail-v1-pipelines]]
188+
link:/images/retail/retail-v1-pipelines.png[image:/images/retail/retail-v1-pipelines.png[retail-v1-pipelines]
156189

157190
. Go to the *Quarkus Coffeeshop Landing Page* where you are presented with the applications in the pattern:
158191
+
159-
link:/images/retail/retail-v1-landing-page.png[image:/images/retail/retail-v1-landing-page.png[retail-v1-landing-page]]
192+
link:/images/retail/retail-v1-landing-page.png[image:/images/retail/retail-v1-landing-page.png[retail-v1-landing-page]
160193

161194
. Click the *Store Web Page* to open the Quarkus Coffeeshop Demo:
162195
+
163-
link:/images/retail/retail-v1-store-page.png[image:/images/retail/retail-v1-store-page.png[retail-v1-store-page]]
196+
link:/images/retail/retail-v1-store-page.png[image:/images/retail/retail-v1-store-page.png[retail-v1-store-page]
164197

165198
. Click the *TEST Store Web Page* to open a separate copy of the same demo.
166199

167200
. Clicking the respective *Kafdrop* links to go to a Kafdrop instance that allows inspection of each of the respective environments.
168201
+
169-
link:/images/retail/retail-v1-kafdrop.png[image:/images/retail/retail-v1-kafdrop.png[retail-v1-kafdrop]]
202+
link:/images/retail/retail-v1-kafdrop.png[image:/images/retail/retail-v1-kafdrop.png[retail-v1-kafdrop]

0 commit comments

Comments
 (0)