Skip to content

Instantly share code, notes, and snippets.

@imaitland
Last active September 9, 2024 18:45
Show Gist options
  • Select an option

  • Save imaitland/de4b86bd758518ebf5ca802e02ea2330 to your computer and use it in GitHub Desktop.

Select an option

Save imaitland/de4b86bd758518ebf5ca802e02ea2330 to your computer and use it in GitHub Desktop.
sciserver install ollama
#!/bin/bash
# Step 1: Create a directory called "ollama"
mkdir -p ollama
# Step 2: Inside the "ollama" directory, create a directory called "models"
mkdir -p ollama/models
# Step 3: Download the file into the "ollama" directory
cd ollama
curl -L https://ollama.com/download/ollama-linux-amd64.tgz -o ollama-linux-amd64.tgz
# Step 4: Install ollama by extracting the tar file in the current directory
tar -C ./ -xzf ollama-linux-amd64.tgz
# Step 5: Download the 'update_ollama_vars.sh' script directly
curl -L https://gist.githubusercontent.com/imaitland/4408f82852c41484712c287b778f07f8/raw/da9c040bc55e88b34bd677f5061d5e709440b72b/sciserver_update_ollama_vars.sh -o update_ollama_vars.sh
# Step 6: Source the 'update_ollama_vars.sh' script
source update_ollama_vars.sh
# End of script
@imaitland
Copy link
Author

imaitland commented Sep 9, 2024

note: this install script copies the script located here to update env vars so you can run ollama's installed binary from the CLI, even though it's at an exotic path.

@imaitland
Copy link
Author

Screenshot 2024-09-09 at 2 38 05 PM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment