Skip to content

Latest commit

 

History

History
57 lines (43 loc) · 2.12 KB

File metadata and controls

57 lines (43 loc) · 2.12 KB

Kubernetes Configuration files

This folder is a quick copy of the grumpycat-config repository. It's here to make things easier for you to consume the app on OpenShift.

Preparation

There are precompiled images available on quay.io/wpernath/quarkus-grumpycat. You can either use latest tag or use one of the vx.y.z tags.

NOTE, for this approach, you need to have the following Operators installed in your OpenShift / Kubernetes cluster:

Installation

Simply log into your OpenShift cluster and then execute

oc apply -k kubernetes-config/overlays/<your stage|dev>

This will create a namespace called grumpycat and installs the latest grumpycat client, server and other dependencies in the namespace. You can delete the installation by executing

oc delete -k kubernetes-config/overlays/<your stage|dev>

NOTE, if you want to install the app in any other namespace than grumpycat, you have to change the following files and properties in there:

  • base/ns.yaml change the name of the namespace to be created
  • overlays/<your-target>/kustomization.yaml
    • Change namespace entry to your namespace
    • Change APPLICATION_BASESERVERURL to point to the corresponding URL:

Instead of:

# generate a configmap 
configMapGenerator:
  # Cat - Client ConfigMap, note that the client app runs entirely on the browser, 
  # so we need to use the external URL of the grumpycat server service
  # 
  - name: client-config
    literals:
      - APPLICATION_BASESERVERURL=http://cat-server-grumpycat.apps.work.ocp.lan/  

You should have something like:

# generate a configmap 
configMapGenerator:
  # Cat - Client ConfigMap, note that the client app runs entirely on the browser, 
  # so we need to use the external URL of the grumpycat server service
  # 
  - name: client-config
    literals:
      - APPLICATION_BASESERVERURL=http://cat-server-<my namespace>.apps.<my-domain>/