Documentation ¶
Index ¶
Constants ¶
View Source
const ( VERSION = 1.5 DEFAULT_POOL_SIZE = 100000 WEBP_HEADER = "image/webp" JPEG = "image/jpeg" PNG = "image/png" AZURE_ACCOUNT_NAME = "AZURE_ACCOUNT_NAME" AZURE_ACCOUNT_KEY = "AZURE_ACCOUNT_KEY" AWS_REGION = "AWS_REGION" AWS_ACCESS_KEY_ID = "AWS_ACCESS_KEY_ID" AWS_SECRET_ACCESS_KEY = "AWS_SECRET_ACCESS_KEY" ONLY_CACHE_HEADER = "X-Cache-Only" NO_CACHE_HEADER = "X-No-Cache" CACHE_DESTINATION_HEADER = "X-Cache-Destination" )
Variables ¶
View Source
var ( DEBUG = false WARNING = false ClientConfirmed = false DEFAULT_QUALITY = 80 Crop = map[string]vips.Gravity{ "top": vips.NORTH, "right": vips.EAST, "bottom": vips.SOUTH, "left": vips.WEST, } ResizableImageTypes = []string{"image/jpeg", "image/png"} Version bool ListenAddr string AllowedMedia string AllowedSizes string CacheDir string S3BucketName string AzureContainerName string Default404 string DirsToSearch string Mark string NoCacheKey string Nodes string Quality int ChanPool chan int Cache *cache.Cache Options vips.Options GlobalSettings Settings AzureClient storage.BlobStorageClient S3Client *s3.S3 )
Functions ¶
func FetchImage ¶
func FetchImage(rw http.ResponseWriter, req *http.Request)
Types ¶
type Context ¶
type RegexpHandler ¶
type RegexpHandler struct {
// contains filtered or unexported fields
}
func (*RegexpHandler) HandleFunc ¶
func (h *RegexpHandler) HandleFunc(pattern *regexp.Regexp, handler func(http.ResponseWriter, *http.Request))
func (*RegexpHandler) ServeHTTP ¶
func (h *RegexpHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)
Click to show internal directories.
Click to hide internal directories.