ollama - 💡(How to fix) Fix Allow Control List for AI Models Downloaded [3 comments, 3 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
ollama/ollama#14782Fetched 2026-04-08 00:31:43
View on GitHub
Comments
3
Participants
3
Timeline
6
Reactions
0
Author
Timeline (top)
commented ×3closed ×1labeled ×1subscribed ×1
RAW_BUFFERClick to expand / collapse

I work as a sys-admin at a University and there is a growing demand for using Ollama in computer labs for teaching. There are a few considerations we have for faciliating AI models in Labs.

  • Due to data governance policies, we have to consider what Student data is uploaded to cloud services. This limits the kind of models we use on local machines.
  • We need to ensure we are working inline with the licence terms of a given AI model, the licences seem to vary between models and we don't have the ability to control what model is downloaded.
  • To optimise performance, we would likely want to have the models installed locally on the machine rather than in user profiles.

This feels like a big ask and is more than one feature, but I was keen to better understand whether the following was a consideration for development:

  • Models stored on local disks rather than user profile (located on network shares). This would optimise read/write locally but also mean models aren't being downloaded from servers by individual users, reducing duplicating data and saving bandwidth.
  • ACL type feature to limit which models are downloaded and limit to approved models.

Thanks in advance

extent analysis

Fix Plan

To address the concerns, we can implement the following solutions:

  • Store models on local disks instead of user profiles to optimize performance and reduce bandwidth usage.
  • Implement an Access Control List (ACL) feature to limit which models can be downloaded and restrict access to approved models only.

Example Code

To store models on local disks, you can modify the model download script to save models to a local directory:

import os

# Define the local model directory
local_model_dir = '/path/to/local/models'

# Download the model and save it to the local directory
def download_model(model_name):
    model_path = os.path.join(local_model_dir, model_name)
    # Download the model using the API or other means
    # Save the model to the local directory
    with open(model_path, 'wb') as f:
        # Write the model data to the file
        pass

To implement the ACL feature, you can create a whitelist of approved models and check against it before downloading a model:

# Define the whitelist of approved models
approved_models = ['model1', 'model2', 'model3']

# Check if a model is approved before downloading
def is_model_approved(model_name):
    return model_name in approved_models

# Download a model only if it is approved
def download_model(model_name):
    if is_model_approved(model_name):
        # Download the model
        pass
    else:
        # Raise an error or deny access
        pass

Verification

To verify that the fixes work, you can:

  • Check that models are being stored on local disks instead of user profiles.
  • Test that only approved models can be downloaded and that access is denied for unapproved models.

Extra Tips

  • Make sure to update the model download script to handle errors and exceptions properly.
  • Consider implementing additional security measures, such as encryption and access controls, to protect the models and user data.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING