importscfg

package
v0.0.0-...-864d242 Latest Latest
Warning

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

Go to latest
Published: Dec 3, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package importscfg contains code to work with imports.cfg.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Get

Get returns the config stored in context.

func GetWithMetadata

func GetWithMetadata(ctx context.Context) (*configspb.GroupImporterConfig, *config.Meta, error)

GetWithMetadata returns the config and its metadata stored in context.

func IsAuthorizedUploader

func IsAuthorizedUploader(ctx context.Context, email, tarballName string) (bool, error)

IsAuthorizedUploader returns whether the email is authorized to upload the specified tarball.

func SetConfig

func SetConfig(ctx context.Context, cfg *configspb.GroupImporterConfig) error

SetConfig installs the cfg into the context ctx.

func SetConfigWithMetadata

func SetConfigWithMetadata(ctx context.Context, cfg *configspb.GroupImporterConfig, meta *config.Meta) error

SetConfigWithMetadata installs the cfg with the given metadata into the context ctx.

func Update

func Update(ctx context.Context) (*config.Meta, error)

Update fetches the config and puts it into the datastore.

It is then used by all requests that go through Middleware.

Types

This section is empty.

Jump to

Keyboard shortcuts

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