Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DefaultInstallationName ¶
DefaultInstallationName derives a human-readable app name from a GitHub repository name. Example: preview-env-github-digitalocean -> Preview Env Github Digitalocean
func FetchCanvas ¶
func FetchCanvas(repo *Repository) (*pb.Canvas, string, error)
FetchCanvas loads and parses canvas.yaml from a public GitHub repository.
Types ¶
type InstallRequest ¶
type InstallResult ¶
type Preview ¶
type Preview struct {
Repo string `json:"repo"`
Owner string `json:"owner"`
Repository string `json:"repository"`
Ref string `json:"ref"`
Title string `json:"title"`
Description string `json:"description"`
CanvasName string `json:"canvasName"`
DefaultName string `json:"defaultName"`
}
Preview describes an installable GitHub app before the user confirms installation.
func BuildPreview ¶
BuildPreview loads app metadata from GitHub and prepares install defaults.
type Repository ¶
type Repository struct {
Owner string
Name string
// Ref is the git ref used when fetching app files (main or master).
Ref string
}
Repository identifies a public GitHub repository hosting a SuperPlane app.
func ParseRepository ¶
func ParseRepository(raw string) (*Repository, error)
ParseRepository accepts github.com/owner/repo and common variants.
func (*Repository) String ¶
func (r *Repository) String() string
type Service ¶
type Service struct {
Registry *registry.Registry
Encryptor crypto.Encryptor
AuthService authorization.Authorization
WebhooksBaseURL string
UsageService usage.Service
}
func (*Service) Install ¶
func (s *Service) Install(ctx context.Context, req InstallRequest) (*InstallResult, error)
Click to show internal directories.
Click to hide internal directories.