Experimental Go Cache program implementation using IBM Cloud Object Storage (COS) as cache backend.
This is a proof-of-concept tool and subject to change.
Log into your IBM Cloud account and create a new COS instance in a region that is close to your location to minimize time of objects spend in transit. Create a bucket in your COS instance to be used as the cache. Setup your shell to use go-cache-prog
by exporting the following environment variables:
export GO_CACHE_PROG_COS_APIKEY=<apikey-that-has-permission-to-access-cos>
export GO_CACHE_PROG_COS_ENDPOINT=s3.<region>.cloud-object-storage.appdomain.cloud
export GO_CACHE_PROG_COS_RESOURCEINSTANCEID=<crn-of-cos>
export GO_CACHE_PROG_COS_BUCKET=<bucket-name>
export GOCACHEPROG="go-cache-prog cos"
The endpoint, resource instance ID and bucket can alternatively be configured via command-line flags, too.
The homeport/tap
has macOS and GNU/Linux pre-built binaries available:
brew install homeport/tap/go-cache-prog
Prebuilt binaries can be downloaded from the GitHub Releases section.
There is a convenience script to download the latest release for Linux or macOS if you want to need it simple (you need curl
and jq
installed on your machine):
curl --silent --location https://raw.githubusercontent.com/homeport/go-cache-prog/refs/heads/main/hack/download.sh | bash
You can install go-cache-prog
from source using go install
:
go install github.com/homeport/go-cache-prog/cmd/go-cache-prog@latest
We are happy to have other people contributing to the project. If you decide to do that, here's how to:
- get Go (
go-cache-prog
requires Go version 1.23 or greater) - fork the project
- create a new branch
- make your changes
- open a PR.
Git commit messages should be meaningful and follow the rules nicely written down by Chris Beams:
The seven rules of a great Git commit message
- Separate subject from body with a blank line
- Limit the subject line to 50 characters
- Capitalize the subject line
- Do not end the subject line with a period
- Use the imperative mood in the subject line
- Wrap the body at 72 characters
- Use the body to explain what and why vs. how
Licensed under MIT License