File tree Expand file tree Collapse file tree 4 files changed +17
-3
lines changed Expand file tree Collapse file tree 4 files changed +17
-3
lines changed Original file line number Diff line number Diff line change @@ -4,6 +4,8 @@ SpringBoot Demo with MySQL running on Kubernetes
4
4
5
5
## Build Demo App image
6
6
7
+ Skip this step if you just want to test the app on Kubernetes
8
+
7
9
``` shell
8
10
docker build --pull --no-cache --squash --rm --progress plain -f Dockerfile -t sbdemo .
9
11
```
@@ -32,6 +34,16 @@ kubectl create secret generic mysql-secrets \
32
34
--from-literal=database=DB
33
35
```
34
36
37
+ ### Clone the repo if using OCI CloudShell or local
38
+
39
+ ``` shell
40
+ git clone https://github.com/junior/springboot-demo-k8s-mysql.git
41
+ ```
42
+
43
+ ``` shell
44
+ cd springboot-demo-k8s-mysql/kubernetes
45
+ ```
46
+
35
47
### Deploy MySQL 5.7
36
48
37
49
#### Create PVC for MySQl on Oracle Cloud Infrastructure using CSI for Block Volume
@@ -44,6 +56,8 @@ kubectl apply -f mysql-pvc-oci-bv.yaml
44
56
45
57
#### Create Service for MySQL
46
58
59
+ Note: this step will create a new LoadBalancer on the infrastructure
60
+
47
61
``` shell
48
62
kubectl apply -f mysql-svc.yaml
49
63
```
Original file line number Diff line number Diff line change 54
54
volumes :
55
55
- name : mysql-persistent-storage
56
56
persistentVolumeClaim :
57
- claimName : mysql-pvc-manual
57
+ claimName : mysql-pvc
Original file line number Diff line number Diff line change 17
17
apiVersion : v1
18
18
kind : PersistentVolumeClaim
19
19
metadata :
20
- name : mysql-pvc-manual
20
+ name : mysql-pvc
21
21
spec :
22
22
storageClassName : manual
23
23
accessModes :
Original file line number Diff line number Diff line change 2
2
apiVersion : v1
3
3
kind : PersistentVolumeClaim
4
4
metadata :
5
- name : mysql-pvc-oci-bv
5
+ name : mysql-pvc
6
6
spec :
7
7
storageClassName : oci-bv
8
8
accessModes :
You can’t perform that action at this time.
0 commit comments