File tree Expand file tree Collapse file tree 4 files changed +11
-7
lines changed
apps/agentstack-server/src/agentstack_server Expand file tree Collapse file tree 4 files changed +11
-7
lines changed Original file line number Diff line number Diff line change @@ -231,6 +231,7 @@ class DockerConfigJson(BaseModel):
231231
232232
233233class ManagedProviderConfiguration (BaseModel ):
234+ disable_downscaling : bool = False
234235 manifest_template_dir : Path | None = None
235236 self_registration_use_local_network : bool = Field (
236237 default = False ,
Original file line number Diff line number Diff line change 2727
2828blueprint = Blueprint ()
2929
30+ if not get_configuration ().provider .disable_downscaling :
3031
31- @blueprint .periodic (cron = "*/1 * * * *" )
32- @blueprint .task (queueing_lock = "scale_down_providers" , queue = str (Queues .CRON_PROVIDER ))
33- @inject
34- async def scale_down_providers (timestamp : int , service : ProviderService ):
35- await service .scale_down_providers ()
32+ @blueprint .periodic (cron = "*/1 * * * *" )
33+ @blueprint .task (queueing_lock = "scale_down_providers" , queue = str (Queues .CRON_PROVIDER ))
34+ @inject
35+ async def scale_down_providers (timestamp : int , service : ProviderService ):
36+ await service .scale_down_providers ()
3637
3738
3839# TODO: Can't use DI here because it's not initialized yet
Original file line number Diff line number Diff line change @@ -273,8 +273,8 @@ spec:
273273 - name : AUTH__DISABLE_AUTH
274274 value : " true"
275275 {{- end }}
276- {{- if .Values.features.selfRegistration }}
277- - name : PROVIDER__AUTO_REMOVE_ENABLED
276+ {{- if .Values.disableProviderDownscaling }}
277+ - name : PROVIDER__DISABLE_DOWNSCALING
278278 value : " true"
279279 {{- end }}
280280 - name : GENERATE_CONVERSATION_TITLE__ENABLED
Original file line number Diff line number Diff line change @@ -83,6 +83,8 @@ providers: []
8383unmanagedProviders : [] # DEPRECATED: use providers instead
8484variables : {} # DEPRECATED: use server API to manage variables instead
8585
86+ disableProviderDownscaling : false
87+
8688# External registries in the format: [name: githubURL]
8789# for example
8890# github: "https://github.com/i-am-bee/[email protected] #path=agent-registry.yaml"
You can’t perform that action at this time.
0 commit comments