Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/env python3
# Based on: https://gist.github.com/nahushrk/5d980e676c4f2762ca385bd6fb9498a9
#
# The original script broke with newer Ollama versions due to hardcoded `library`
# namespace paths and a malformed tar archive structure. This rewrite fixes those
# issues and adds: namespaced/custom-registry model support, a `list` command,
# `--as` (import under a different name), `--force`, `--output`, tag defaulting
# to `latest`, auto-detection of the Ollama base path, and safe tarfile extraction
# for Python 3.12+.
"""
@nahushrk
nahushrk / ollama_model_manager.py
Created February 1, 2025 07:44
import and export ollama models between computers without downloading again
#!/usr/bin/env python3
"""
Ollama Model Manager
This script provides two modes of operation:
- export: Exports an installed Ollama model to a tarball.
- import: Imports an Ollama model from a tarball.
The export mode reads a manifest file located at:
<base_path>/manifests/registry.ollama.ai/library/<model_name>/<model_size>
@gitricko
gitricko / Makefile
Last active March 23, 2024 00:51
Epinio accelerator installer + test
SHELL := /bin/bash
export CLUSTER_NAME ?= epinio
export TMP_DIR ?= /tmp
IP_ADDR := $(shell ifconfig -a | grep "inet " | grep -v 127 | awk 'NR==1{print $$2}')
export DOMAIN ?= $(IP_ADDR).sslip.io
export EPINIO_SERVER_VERSION ?= 1.11.0
export ADM_USR ?= admin
export ADM_PWD ?= password
export ADM_PWD_ENCRYPT := '$(shell htpasswd -bnBC 10 "" ${ADM_PWD} | tr -d :)'
export DEV_USR ?= dev
@agracey
agracey / Epinio-bp-config.md
Last active July 8, 2022 18:15
Language specific buildpack configuration options
@gwangjinkim
gwangjinkim / install-and-start-postgresql-in-conda-locally
Last active February 17, 2026 10:06
How to install and run postgresql in conda
This gist I write, because I couldn't find any step by step instructions
how to install and start postgresql locally (using conda within a conda environment - with the result
that you can run it without sudo/admin rights on your machine!)
and not globally in the operating system (which requires sudo/admin rights on that machine).
I hope, this will help especially people new to postgresql
(and those who don't have sudo/admin rights on a specific machine but want
to run postgresql there)!
Prerequisite is to have miniconda already installed in your Computer.
@jsoverson
jsoverson / reddit-signup.js
Created December 3, 2018 17:46
Reddit signup script w/Puppeteer and 2Captcha
const puppeteer = require('puppeteer');
const request = require('request-promise-native');
const poll = require('promise-poller').default;
const siteDetails = {
sitekey: '6LeTnxkTAAAAAN9QEuDZRpn90WwKk_R1TRW_g-JC',
pageurl: 'https://old.reddit.com/login'
}
const getUsername = require('./get-username');
@nota-ja
nota-ja / README.md
Last active August 18, 2022 15:37
Multiple App Ports Demo on Cloud Foundry
@jvawdrey
jvawdrey / pcfdev-aws-deploy.md
Created June 24, 2016 04:55
pcf dev AWS deploy steps

Deploying MicroPCF on AWS

January 5th, 2016

Instructions for deploying micropcf to AWS.

I encountered several challenges relating to AWS configurations and the available Vagrantfile while deploying micropcf to AWS. This documentation details the steps taken to successfully deploy micropcf to AWS.

@vasanthk
vasanthk / System Design.md
Last active July 12, 2026 04:28
System Design Cheatsheet

System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?
@mattbennett
mattbennett / app.py
Last active June 3, 2024 14:14
Nameko celery integration
from flask import Flask, request
from nameko.standalone.rpc import ServiceRpcProxy
app = Flask(__name__)
@app.route('/')
def task_list():
return """
<html>