Skip to content

Commit

Permalink
Merge branch 'trustyai-explainability:main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
ruivieira authored Oct 15, 2024
2 parents c4baadf + 4893d79 commit e02ed79
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 4 deletions.
2 changes: 1 addition & 1 deletion config/base/params.env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
trustyaiServiceImage=quay.io/trustyai/trustyai-service:latest
trustyaiOperatorImage=quay.io/trustyai/trustyai-service-operator:latest
oauthProxyImage=quay.io/openshift/origin-oauth-proxy:4.14.0
kServeServerless=disabled
kServeServerless=enabled
2 changes: 1 addition & 1 deletion config/overlays/rhoai/params.env
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
trustyaiServiceImage=quay.io/trustyai/trustyai-service:latest
trustyaiOperatorImage=quay.io/trustyai/trustyai-service-operator:latest
oauthProxyImage=registry.redhat.io/openshift4/ose-oauth-proxy@sha256:ab112105ac37352a2a4916a39d6736f5db6ab4c29bad4467de8d613e80e9bb33
kServeServerless=disabled
kServeServerless=enabled
1 change: 0 additions & 1 deletion controllers/database.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import (
"sigs.k8s.io/controller-runtime/pkg/client"
)

// checkDatabaseAccessible checks if the TrustyAI service pod failed with database issues.
func (r *TrustyAIServiceReconciler) checkDatabaseAccessible(ctx context.Context, instance *trustyaiopendatahubiov1alpha1.TrustyAIService) (bool, error) {
deployment := &appsv1.Deployment{}
err := r.Get(ctx, types.NamespacedName{Name: instance.Name, Namespace: instance.Namespace}, deployment)
Expand Down
7 changes: 6 additions & 1 deletion controllers/statuses.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,12 @@ func (r *TrustyAIServiceReconciler) reconcileStatuses(ctx context.Context, insta
UpdateRouteAvailable(saved)

if instance.Spec.Storage.IsStorageDatabase() || instance.IsMigration() {
UpdateDBAvailable(saved)
if status.DBReady {
UpdateDBAvailable(saved)
} else {
UpdateDBConnectionError(saved)
return
}
}

UpdateTrustyAIServiceAvailable(saved)
Expand Down
14 changes: 14 additions & 0 deletions controllers/templates/service/deployment.tmpl.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,20 @@ spec:
- name: STORAGE_MIGRATION_CONFIG_FROM_FILENAME
value: {{ .Instance.Spec.Data.Filename }}
{{ end }}
readinessProbe:
httpGet:
path: /q/health/ready
port: 8080
initialDelaySeconds: 10
periodSeconds: 5
timeoutSeconds: 2
livenessProbe:
httpGet:
path: /q/health/live
port: 8080
initialDelaySeconds: 10
periodSeconds: 5
timeoutSeconds: 2
volumeMounts:
- name: {{ .Instance.Name }}-internal
readOnly: false
Expand Down

0 comments on commit e02ed79

Please sign in to comment.