Skip to content
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

[DO NOT MERGE] Using parent devfile for Ollama #401

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 3 additions & 52 deletions stacks/ollama/devfile.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,55 +11,6 @@ metadata:
- Starcoder2
projectType: universal
language: Polyglot
version: 1.0.0
projects:
- name: cde-ollama-continue
git:
remotes:
origin: 'https://github.com/redhat-developer-demos/cde-ollama-continue'
checkoutFrom:
revision: main
components:
- name: udi
container:
image: quay.io/devfile/universal-developer-image:ubi8-98224a3
memoryLimit: 4Gi
memoryRequest: 2Gi
cpuLimit: 4000m
cpuRequest: 1000m
mountSources: true
sourceMapping: /projects
- name: ollama
attributes:
container-overrides:
resources:
limits:
cpu: 4000m
memory: 12Gi
# nvidia.com/gpu: 1 # Uncomment this if the pod shall be scheduled only on a GPU node
requests:
cpu: 1000m
memory: 8Gi
# nvidia.com/gpu: 1 # Uncomment this if the pod shall be scheduled only on a GPU node
container:
image: docker.io/ollama/ollama:0.1.34
mountSources: true
sourceMapping: /.ollama
commands:
- id: pullmodel
exec:
component: ollama
commandLine: "ollama pull llama3:8b"
- id: pullautocompletemodel
exec:
component: ollama
commandLine: "ollama pull starcoder2:3b"
- id: copyconfig
exec:
component: udi
commandLine: "mkdir /home/user/.continue && cp /projects/cde-ollama-continue/continue-config.json /home/user/.continue/config.json"
events:
postStart:
- pullmodel
- pullautocompletemodel
- copyconfig
version: 1.0.1
parent:
uri: https://raw.githubusercontent.com/redhat-developer-demos/cde-ollama-continue/main/devfile.yaml
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think here it would be better to use a specific commit instead of the main branch. Wdyt?

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This makes sense given that we are versioning the devfile (in this case, 1.0.1). We might want to instead have a branch in the parent devfile repo for each devfile version, and "release" new versions of the devfile, rather than having a rolling release. This is definitely something to gather consensus for devfile/api#1579.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes +1 I think is important to create some guidelines regarding the versioning of every parent devfile too. This is one of the reasons the spike was opened. For using a release branch I think it also makes sense.

cc @devfile/devfile-services-team in case someone else has input for the usage of a release branch.

Loading