Documentation ¶
Overview ¶
Package maven @Link https://gitee.com/linngc/central-mirror @Copyright Copyright (c) 2024 central-mirror CLI @Author linngc @License
Package maven @Link https://gitee.com/linngc/central-mirror @Copyright Copyright (c) 2024 central-mirror CLI @Author linngc @License
Package maven @Link https://gitee.com/linngc/central-mirror @Copyright Copyright (c) 2024 central-mirror CLI @Author linngc @License
Package maven @Link https://gitee.com/linngc/central-mirror @Copyright Copyright (c) 2024 central-mirror CLI @Author linngc @License
Package maven @Link https://gitee.com/linngc/central-mirror @Copyright Copyright (c) 2024 central-mirror CLI @Author linngc @License
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type MavenConfig ¶
type MavenConfig struct { Public string `yaml:"public" default:"\"https://repo1.maven.org/maven2/\"" dc:"Mirrors中央仓库"` Mirror string `` /* 185-byte string literal not displayed */ Repository map[string]*Repository `yaml:"repository"` }
type MavenProxy ¶
func (*MavenProxy) DeployMapping ¶
func (c *MavenProxy) DeployMapping() (u *cacheModel.ObjectsInfo, err error)
DeployMapping maven pom.xml put请求时候入口 最终请求示例: http://127.0.0.1:10010/proxy/maven/public/org/springframework/boot/spring-boot/2.5.6/spring-boot-2.5.6.jar @param libName 示例 public @param moduleName 示例 org/springframework/boot/spring-boot/2.5.6/spring-boot-2.5.6.jar
func (*MavenProxy) Get ¶
func (c *MavenProxy) Get() (u *cacheModel.ObjectsInfo, err error)
Get maven pom.xml get/head请求时候入口 最终请求示例: http://127.0.0.1:10010/proxy/maven/public/org/springframework/boot/spring-boot/2.5.6/spring-boot-2.5.6.jar libName 示例 public @param jarPath 示例 org/springframework/boot/spring-boot/2.5.6/spring-boot-2.5.6.jar
func (*MavenProxy) GetLibNames ¶
func (c *MavenProxy) GetLibNames() (libs map[string]string, err error)
GetLibNames 获取已配置的仓库名称信息 最终请求示例:http://127.0.0.1:10010/api/maven/getRepository
type Repository ¶
type Repository struct { Id string `yaml:"id" dc:"仓库ID"` Name string `yaml:"name" dc:"仓库名字, 随意,唯一即可"` Mode int `yaml:"mode" default:"6" dc:"模式,默认为6,参数描述:0 无效 2 仅可写 4 仅可读 6 可读写"` Auth bool `yaml:"auth" dc:"是否鉴权, 默认鉴权,参数描述:true 鉴权 false不鉴权"` Cache bool `yaml:"cache" dc:"是否缓存镜像文件, 默认缓存,参数描述:true 缓存 false不缓存"` }