Skip to content

Commit

Permalink
Merge pull request #26 from wiremock/wiremock-3
Browse files Browse the repository at this point in the history
Update the Helm chart to include WireMock 3.0.0 and use the official image
  • Loading branch information
leeturner committed Mar 26, 2024
2 parents ac77400 + 5393388 commit 3b72a1f
Show file tree
Hide file tree
Showing 7 changed files with 29 additions and 20 deletions.
15 changes: 8 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,11 @@
# WireMock Helm Charts

Helm Chart for WireMock deployment to Kubernetes.
It allows deploying the official [WireMock Docker images](https://github.com/wiremock/wiremock-docker)
and also other charts that extend it,
in particular [holomekc/wiremock](https://github.com/holomekc/wiremock) with embedded UI.
It allows deploying the official [WireMock Docker images](https://github.com/wiremock/wiremock-docker) for both WireMock 2 and WireMock 3,
and also other charts that extend it.

Historically, [holomekc/wiremock](https://github.com/holomekc/wiremock) was suggested as a default image,
and the chart remains partially compatible with it.

# Quick Start

Expand All @@ -28,19 +30,18 @@ $ export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "ap
$ kubectl port-forward $POD_NAME 8080:{{ .Values.service.internalPort}}
```

## Verify Wiremock deployment
## Verify WireMock deployment

To verify a response using Wiremock, run
To verify a response using WireMock, run

```bash
$ curl -X POST http://127.0.0.1:8080/v1/hello
```

To check the web app when using `holomekc/wiremock`, visit http://127.0.0.1:8080/__admin/webapp on your browser.

# References:
## References

- [WireMock Java Library](https://github.com/tomakehurst/wiremock)
- [Official WireMock Docker Image](https://github.com/wiremock/wiremock-docker)
- [WireMock extended with Web UI](https://github.com/holomekc/wiremock), a project by [(@holomekc]https://github.com/holomekc)

4 changes: 2 additions & 2 deletions charts/wiremock/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
apiVersion: v1
appVersion: "2.32.0.2"
appVersion: "3.0.0.1"
description: A Helm chart for WireMock deployment on Kubernetes
name: wiremock
version: 0.1.4
version: 0.2.0
maintainers:
- name: "gitkent"
url: "https://github.com/gitkent"
Expand Down
2 changes: 1 addition & 1 deletion charts/wiremock/templates/NOTES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@
{{- else if contains "ClusterIP" .Values.service.type }}
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "wiremock.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
kubectl port-forward $POD_NAME 8080:{{ .Values.service.internalPort}}
echo "Visit http://127.0.0.1:8080/__admin/webapp to use your application"
echo "Visit http://127.0.0.1:8080/__admin/mappings to use your application"
run "curl -X POST http://127.0.0.1:8080/v1/hello"
{{- end }}
4 changes: 2 additions & 2 deletions charts/wiremock/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,12 @@ spec:
protocol: TCP
livenessProbe:
httpGet:
path: /__admin/webapp
path: /__admin/mappings
port: {{ .Values.service.internalPort }}
scheme: {{ .Values.scheme }}
readinessProbe:
httpGet:
path: /__admin/webapp
path: /__admin/mappings
port: {{ .Values.service.internalPort }}
scheme: {{ .Values.scheme }}
resources:
Expand Down
8 changes: 4 additions & 4 deletions charts/wiremock/values.yaml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# Default values for wiremock.
# Default values for WireMock.
# This is a YAML-formatted file.
# Declare variables to be passed into your templates.

replicaCount: 1

image:
repository: holomekc/wiremock-gui
tag: 2.32.0.2
repository: wiremock/wiremock
tag: 3.2.0-3
pullPolicy: IfNotPresent

initContainer:
Expand Down Expand Up @@ -37,7 +37,7 @@ ingress:
# hosts:
# - chart-example.local
env:
WIREMOCK_OPTIONS: "--port=9021,--max-request-journal=1000,--local-response-templating,--root-dir=/home/wiremock/storage"
WIREMOCK_OPTIONS: "--port=9021 --max-request-journal=1000 --local-response-templating --root-dir=/home/wiremock/storage"

resources: {}
# We usually recommend not to specify default resources and to leave this as a conscious
Expand Down
16 changes: 12 additions & 4 deletions index.yaml
Original file line number Diff line number Diff line change
@@ -1,14 +1,22 @@
apiVersion: v1
entries:
wiremock:
- apiVersion: v1
appVersion: 3.0.0.1
created: "2023-08-30T15:32:11.9806537+02:00"
description: A Helm chart for WireMock deployment on Kubernetes
digest: 23e14af94bbef9fce4a4456f93001ece953cc841a5d2b10dad3075a7a9ba1066
urls:
- https://wiremock.github.io/helm-charts/wiremock-0.2.0.tgz
version: 0.2.0
- apiVersion: v1
appVersion: 2.32.0.2
created: "2022-02-14T16:40:41.782464+11:00"
description: A Helm chart for Wiremock deployment on Kubernetes
digest: 151a4b365c18023a8fae0cb1eecba1f967e358866fcc6947f432f34afc65768d
name: wiremock
urls:
- https://gitkent.github.io/helm-charts/wiremock-0.1.3.tgz
- https://wiremock.github.io/helm-charts/wiremock-0.1.3.tgz
version: 0.1.3
- apiVersion: v1
appVersion: 2.26.3
Expand All @@ -17,7 +25,7 @@ entries:
digest: b2af1fa27466f3911eca2b7223d89c147853f54acb84c5cdd236a85fd3a696a5
name: wiremock
urls:
- https://gitkent.github.io/helm-charts/wiremock-0.1.2.tgz
- https://wiremock.github.io/helm-charts/wiremock-0.1.2.tgz
version: 0.1.2
- apiVersion: v1
appVersion: 2.26.3
Expand All @@ -26,7 +34,7 @@ entries:
digest: b168baf9814cd2f2589dbba78bf0e66d21a1c81cd497dca6bedf26aefadd81d4
name: wiremock
urls:
- https://gitkent.github.io/helm-charts/wiremock-0.1.1.tgz
- https://wiremock.github.io/helm-charts/wiremock-0.1.1.tgz
version: 0.1.1
- apiVersion: v1
appVersion: "1.0"
Expand All @@ -35,6 +43,6 @@ entries:
digest: 5a489e52a09536aac1d89a29ced5e34bee95b9992e200c0c47085f6b76ba74fe
name: wiremock
urls:
- https://gitkent.github.io/helm-charts/wiremock-0.1.0.tgz
- https://wiremock.github.io/helm-charts/wiremock-0.1.0.tgz
version: 0.1.0
generated: "2022-02-14T16:40:41.778584+11:00"
Binary file added wiremock-0.2.0.tgz
Binary file not shown.

0 comments on commit 3b72a1f

Please sign in to comment.