Skip to content

Commit 044a662

Browse files
CasLubbersotomi-admin
andauthored
fix: restart otomiApi deploy after 4.7.0 upgrade (#2280)
Co-authored-by: otomi-admin <[email protected]>
1 parent 375054b commit 044a662

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

src/common/runtime-upgrades/runtime-upgrades.ts

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { OtomiDebugger } from '../debug'
2-
import { k8s } from '../k8s'
2+
import { k8s, restartOtomiApiDeployment } from '../k8s'
33
import { detectAndRestartOutdatedIstioSidecars } from './restart-istio-sidecars'
44

55
export interface RuntimeUpgradeContext {
@@ -28,6 +28,15 @@ export const runtimeUpgrades: RuntimeUpgrades = [
2828
{
2929
version: '4.7.0',
3030
applications: {
31+
'keycloak-keycloak': {
32+
post: async (context: RuntimeUpgradeContext) => {
33+
try {
34+
await restartOtomiApiDeployment(k8s.app())
35+
} catch (error) {
36+
context.debug.error('Failed to check and restart otomi-api:', error)
37+
}
38+
},
39+
},
3140
'istio-system-istiod': {
3241
post: async (context: RuntimeUpgradeContext) => {
3342
try {

0 commit comments

Comments
 (0)