Skip to content

Make ollama container tag/version configurable #675

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
feO2x opened this issue May 7, 2025 · 1 comment
Closed

Make ollama container tag/version configurable #675

feO2x opened this issue May 7, 2025 · 1 comment

Comments

@feO2x
Copy link

feO2x commented May 7, 2025

Related to an existing integration?

Yes

Existing integration

CommunityToolkit.Aspire.Hosting.Ollama

Overview

Version 9.4.1-beta.280 of CommunityToolkit.Aspire.Hosting.Ollama does not allow to set the specific version of Ollama that should be run inside a container. It's hardcoded to Ollama 0.6.0 - the newest version is 0.6.8. This results in newer models like mistral-small31:32b not being executable with CommunityToolkit.Aspire.Hosting.Ollama because it requires a newer Ollama version than 0.6.0.

Usage example

We could add a method overload that takes an additional tag parameter:

distributedApplicationBuilder.AddOllama("ollama", tag: "0.6.8");

Or an additional method on the IResourceBuilder<OllamaResource>:

distributedApplicationBuilder
    .AddOllama("ollama")
    .WithImageTag("0.6.8");

Breaking change?

No

Alternatives

As the tag value is a constant value in OllamaContainerImageTags, I don't see any alternatives.

Additional context

This could also come in handy when implementing #608. Imagine if there was another parameter where we specify that Ollama shouldn't be run in a container but simply accessed via a dedicated HTTP/HTTPS URL, the CommunityToolkit.Aspire.Hosting.Ollama could know this way which version is used (although we could also call ollama version).

Help us help you

Yes, I'd like to be assigned to work on this item

@Alirexaa
Copy link
Member

Alirexaa commented May 7, 2025

You can use WithImageTag to override the tag.

@Alirexaa Alirexaa closed this as completed May 7, 2025
@Alirexaa Alirexaa reopened this May 7, 2025
@Alirexaa Alirexaa closed this as not planned Won't fix, can't repro, duplicate, stale May 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants