pkgproxy

package
v0.0.0-...-e7354d2 Latest Latest
Warning

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

Go to latest
Published: Jan 12, 2026 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Overview

Copyright 2022 Reto Gantenbein SPDX-License-Identifier: Apache-2.0

Copyright 2022 Reto Gantenbein SPDX-License-Identifier: Apache-2.0

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadConfig

func LoadConfig(config *RepoConfig, path string) error

Types

type PkgProxy

type PkgProxy interface {
	Cache(echo.HandlerFunc) echo.HandlerFunc
	ForwardProxy(echo.HandlerFunc) echo.HandlerFunc
}

func New

func New(config *PkgProxyConfig) PkgProxy

type PkgProxyConfig

type PkgProxyConfig struct {
	CacheBasePath    string
	RepositoryConfig *RepoConfig

	// To customize the transport to remote.
	// Examples: If custom TLS certificates are required.
	Transport http.RoundTripper
}

type RepoConfig

type RepoConfig struct {
	Repositories map[string]Repository `yaml:"repositories"`
}

RepoConfig defines the upstream package repositories

type Repository

type Repository struct {
	CacheSuffixes []string `yaml:"suffixes"`
	Mirrors       []string `yaml:"mirrors"`
}

Jump to

Keyboard shortcuts

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