Documentation
¶
Overview ¶
Package projects contains utilities for working with projects.
Index ¶
- Constants
- func CleanUpUnmanagedProjects(ctx context.Context, proj uuid.UUID, querier db.Querier, ...) error
- func DeleteProject(ctx context.Context, proj uuid.UUID, querier db.Querier, ...) error
- func ProvisionSelfEnrolledProject(ctx context.Context, authzClient authz.Client, qtx db.Querier, ...) (outproj *pb.Project, projerr error)
- type Metadata
Constants ¶
View Source
const (
// MinderMetadataVersion is the version of the metadata format.
MinderMetadataVersion = "v1alpha1"
)
Variables ¶
This section is empty.
Functions ¶
func CleanUpUnmanagedProjects ¶
func CleanUpUnmanagedProjects(ctx context.Context, proj uuid.UUID, querier db.Querier, authzClient authz.Client) error
CleanUpUnmanagedProjects deletes a project if it has no role assignments left
func DeleteProject ¶
func DeleteProject(ctx context.Context, proj uuid.UUID, querier db.Querier, authzClient authz.Client) error
DeleteProject deletes a project and authorization relationships
func ProvisionSelfEnrolledProject ¶
func ProvisionSelfEnrolledProject( ctx context.Context, authzClient authz.Client, qtx db.Querier, projectName string, userSub string, ) (outproj *pb.Project, projerr error)
ProvisionSelfEnrolledProject creates the default records, such as projects, roles and provider for the organization
Types ¶
type Metadata ¶
type Metadata struct {
Version string `json:"version"`
SelfEnrolled bool `json:"self_enrolled"`
Description string `json:"description"`
}
Metadata contains metadata relevant for a project.
func NewSelfEnrolledMetadata ¶
func NewSelfEnrolledMetadata() Metadata
NewSelfEnrolledMetadata returns a new Metadata object with the SelfEnrolled field set to true.
Click to show internal directories.
Click to hide internal directories.