Help us shape the future of Go! Take the 2026 Go Developer Survey

lfscache

command module
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 8, 2019 License: MIT Imports: 9 Imported by: 0

README

lfs-cache

lfs-cache is a caching proxy for Git LFS servers.

Usage

Docker
$ docker run --name lfscache --rm -d -v /my/cache/dir/lfs:/lfs saracen/lfscache:latest --url github.com/org/repo.git/info/lfs --http-addr :80  --directory /lfs
Binary

Download the correct binary for your system.

$ ./lfscache --url github.com/org/repo.git/info/lfs --directory /my/cache/dir/lfs --http-addr=:9876

--directory specifies the cache directory. The layout is the same used by the Git LFS client, so it might be a good idea to copy over your .git/lfs/objects directory to preload the cache (cp -r .git/lfs/objects /my/cache/dir/lfs). The tmp and incomplete directories do not need to be copied over.

Now you need to have your Git LFS client point to the proxy. One method of doing this is to replace the URL at a global level, so that it works whenever a repository references your target LFS server.

git config --global url.http://my-cache-proxy:9876/.insteadOf https://github.com/org/repo.git/info/lfs

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL