You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/en/conf24/1-zero-config-k8s/7-log-observer-connect/3-deploy.md
+77Lines changed: 77 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,22 +6,99 @@ weight: 3
6
6
7
7
To see the changes in effect, we need to redeploy the services, First, let's change the location of the images from the external repo to the local one by running the following script:
8
8
9
+
{{< tabs >}}
10
+
{{% tab title="Change deployment to local containers" %}}
11
+
9
12
```bash
10
13
.~/workshop/petclinic/scripts/set_local.sh
11
14
```
12
15
16
+
{{% /tab %}}
17
+
{{% tab title="Output" %}}
18
+
19
+
```text
20
+
Script execution completed. Modified content saved to /home/splunk/workshop/petclinic/petclinic-local.yaml
21
+
```
22
+
23
+
{{% /tab %}}
24
+
{{< /tabs >}}
25
+
13
26
The result is a new file on disk called `petclinic-local.yaml`. Switch to the local versions by using the new version of the deployment YAML. First delete the old containers from the original deployment with:
and now push the new container to the local registry, the others get skipped:
83
+
84
+
{{< tabs >}}
85
+
{{% tab title="Updating docker repo with RUM api-gateway" %}}
62
86
63
87
```bash
64
88
.~/workshop/petclinic/scripts/push_docker.sh
65
89
```
66
90
91
+
{{% /tab %}}
92
+
{{% tab title="Verifying only change to api-gateway gets pushed" %}}
93
+
94
+
```text
95
+
The push refers to repository [localhost:9999/spring-petclinic-api-gateway]
96
+
9a7b16677cf9: Pushed
97
+
f2e09ed98998: Layer already exists
98
+
291752eeb66b: Layer already exists
99
+
ac28fe526c24: Layer already exists
100
+
0a37fe4a02de: Layer already exists
101
+
4b1e7b998de9: Layer already exists
102
+
a2a8ef39e636: Layer already exists
103
+
86cb6a9eb3cd: Layer already exists
104
+
985fdc63de98: Layer already exists
105
+
4ab2850febd7: Layer already exists
106
+
2db7720a8970: Layer already exists
107
+
629ca62fb7c7: Layer already exists
108
+
```
109
+
110
+
{{% /tab %}}
111
+
{{< /tabs >}}
112
+
67
113
As soon as the container is pushed into the repository, just restart the `api-gateway` to apply the changes:
68
114
115
+
{{< tabs >}}
116
+
{{% tab title="Rollout restart api-gateway" %}}
117
+
69
118
```bash
70
119
kubectl rollout restart deployment api-gateway
71
120
```
72
121
122
+
{{% /tab %}}
123
+
{{% tab title=" Output" %}}
124
+
125
+
```text
126
+
deployment.apps/api-gateway restarted
127
+
```
128
+
129
+
{{% /tab %}}
130
+
{{< /tabs >}}
131
+
73
132
Validate that the application is running by visiting **http://<IP_ADDRESS>:81** (replace **<IP_ADDRESS>** with the IP address you obtained above). Make sure the application is working correctly by visiting the **All Owners****(1)** and select an owner, then add a **visit****(2)**. We will use this action when checking RUM
0 commit comments