repository

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Oct 27, 2021 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const URLNamePlaceholder string = "repository_name"

Variables

This section is empty.

Functions

func AddHandler

func AddHandler(s addService) http.Handler

AddHandler handles a repo add/update request swagger:operation PUT /repositories/{repository_name} repository addOperation

Add/Update a chart repository to the server. The endpoint is idempotent and a repository can be updated by using the force_update parameter to true --- produces: - application/json parameters:

  • name: repository_name in: path required: true type: string format: string
  • name: Body in: body required: true schema: "$ref": "#/definitions/addRepoRequestBody"

schemes: - http responses:

'200':
 description: "The repository was added successfully"
 schema:
  $ref: "#/definitions/addRepoEntry"
'400':
 description: "Invalid Request"
 schema:
  $ref: "#/definitions/addRepoErrorResponseBody"
'500':
 description: "Something went with the server"
 schema:
  $ref: "#/definitions/addRepoErrorResponseBody"

Types

type AddErrorResponse

type AddErrorResponse struct {
	Error string `json:"error"`
}

AddErrorResponse body of non 2xx response swagger:model addRepoErrorResponseBody

type AddRequest

type AddRequest struct {
	Name     string `json:"-"`
	URL      string `json:"url"`
	Username string `json:"username"`
	Password string `json:"password"`

	// example: false
	ForceUpdate bool `json:"force_update"`

	// example: false
	InsecureSkipTLSverify bool `json:"skip_tls_verify"`
}

AddRequest is the body for PUT request to repository swagger:model addRepoRequestBody

type Entry

type Entry struct {
	Name     string `json:"name"`
	URL      string `json:"url"`
	Username string `json:"username"`
	Password string `json:"password"`
}

Entry contains metadata about a helm repository entry object swagger:model addRepoEntry

type Service

type Service struct {
	// contains filtered or unexported fields
}

func NewService

func NewService(cli repository.Client) Service

func (Service) Add

func (s Service) Add(ctx context.Context, req AddRequest) (Entry, error)

Jump to

Keyboard shortcuts

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