Skip to content
This repository was archived by the owner on Jun 26, 2024. It is now read-only.

Commit fbf7ff4

Browse files
committed
Added petclinic deployment for mysql and mysqlcluster-deployment for creating instance of PerconaXtraDBCluster
Signed-off-by: Kartikey Mamgain <[email protected]>
1 parent 0dd86ce commit fbf7ff4

File tree

2 files changed

+72
-0
lines changed

2 files changed

+72
-0
lines changed
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
apiVersion: pxc.percona.com/v1-10-0
2+
kind: PerconaXtraDBCluster
3+
metadata:
4+
name: minimal-cluster
5+
spec:
6+
crVersion: 1.10.0
7+
secretsName: minimal-cluster-secrets
8+
allowUnsafeConfigurations: true
9+
upgradeOptions:
10+
apply: 8.0-recommended
11+
schedule: "0 4 * * *"
12+
pxc:
13+
size: 1
14+
image: percona/percona-xtradb-cluster:8.0.23-14.1
15+
volumeSpec:
16+
persistentVolumeClaim:
17+
resources:
18+
requests:
19+
storage: 6G
20+
haproxy:
21+
enabled: true
22+
size: 1
23+
image: perconalab/percona-xtradb-cluster-operator:main-haproxy
24+
logcollector:
25+
enabled: true
26+
image: perconalab/percona-xtradb-cluster-operator:main-logcollector
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
---
2+
# tag::app-deployment[]
3+
apiVersion: apps/v1
4+
kind: Deployment
5+
metadata:
6+
name: spring-petclinic
7+
labels:
8+
app: spring-petclinic
9+
spec:
10+
replicas: 1
11+
selector:
12+
matchLabels:
13+
app: spring-petclinic
14+
template:
15+
metadata:
16+
labels:
17+
app: spring-petclinic
18+
spec:
19+
containers:
20+
- name: app
21+
image: quay.io/service-binding/spring-petclinic:latest
22+
imagePullPolicy: Always
23+
env:
24+
- name: SPRING_PROFILES_ACTIVE
25+
value: mysql
26+
ports:
27+
- name: http
28+
containerPort: 8080
29+
# end::app-deployment[]
30+
---
31+
# tag::app-service[]
32+
apiVersion: v1
33+
kind: Service
34+
metadata:
35+
labels:
36+
app: spring-petclinic
37+
name: spring-petclinic
38+
spec:
39+
type: NodePort
40+
ports:
41+
- port: 80
42+
protocol: TCP
43+
targetPort: 8080
44+
selector:
45+
app: spring-petclinic
46+
# end::app-service[]

0 commit comments

Comments
 (0)