feat: beta deploys all services with pipeline toggle defaulting to OFF
- pipelineEnabled: true in beta so all pods run (Kargo happy) - PIPELINE_DEFAULT_OFF=true in beta config — scheduler initializes the Redis toggle to OFF on first boot - Shared Ollama (10.1.1.12:2701) between beta and paper - Flip pipeline ON from the UI when testing, OFF when done - Optimistic UI update for the toggle button
This commit is contained in:
@@ -537,7 +537,13 @@ export function usePipelineToggle() {
|
||||
const qc = useQueryClient();
|
||||
return useMutation({
|
||||
mutationFn: (enabled: boolean) => apiPost<{ pipeline_enabled: boolean }>('query', '/api/ops/pipeline/toggle', { enabled }),
|
||||
onSuccess: () => qc.invalidateQueries({ queryKey: ['pipeline-health'] }),
|
||||
onMutate: async (enabled) => {
|
||||
await qc.cancelQueries({ queryKey: ['pipeline-health'] });
|
||||
qc.setQueriesData<Record<string, unknown>>({ queryKey: ['pipeline-health'] }, (old) =>
|
||||
old ? { ...old, pipeline_enabled: enabled } : old,
|
||||
);
|
||||
},
|
||||
onSettled: () => qc.invalidateQueries({ queryKey: ['pipeline-health'] }),
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user