diff --git a/playbook/roles/bookinfo/tasks/main.yml b/playbook/roles/bookinfo/tasks/main.yml index 17cfb856..14765121 100755 --- a/playbook/roles/bookinfo/tasks/main.yml +++ b/playbook/roles/bookinfo/tasks/main.yml @@ -12,6 +12,7 @@ - bookinfo-reviews.yaml - bookinfo-details.yaml - bookinfo-ratings.yaml + - bookinfo-ingress.yaml - name: Setup bookinfo shell: "kubectl apply -f /tmp{{ item }}" @@ -22,3 +23,4 @@ - bookinfo-reviews.yaml - bookinfo-details.yaml - bookinfo-ratings.yaml + - bookinfo-ingress.yaml diff --git a/playbook/roles/bookinfo/templates/bookinfo-ingress.yaml b/playbook/roles/bookinfo/templates/bookinfo-ingress.yaml new file mode 100644 index 00000000..9944c090 --- /dev/null +++ b/playbook/roles/bookinfo/templates/bookinfo-ingress.yaml @@ -0,0 +1,18 @@ +apiVersion: networking.k8s.io/v1 +kind: Ingress +metadata: + name: bookinfo + namespace: default +spec: + ingressClassName: nginx + rules: + - host: bookinfo.onwalk.net + http: + paths: + - backend: + service: + name: productpage + port: + number: 9080 + path: / + pathType: Prefix