Documentation
¶
Index ¶
- Constants
- Variables
- func AddConnectivityRule(rule ConnectivityRule) error
- func AddConnectivityRuleAt(dataDir string, rule ConnectivityRule) error
- func ApplicationBackendNetworkName(m Manifest) string
- func ApplicationBackendNetworkNameForProject(project string) string
- func ApplicationExposureNetworkName(m Manifest) string
- func ApplicationExposureNetworkNameForProject(project string) string
- func ApplyDevelopmentManagementUICredentials(ctx context.Context, issuer serviceaccess.Issuer, files RuntimeFiles, ...) error
- func AvailabilityIntent(m Manifest) availability.Intent
- func CacheInstanceNames(m Manifest) []string
- func CapabilityBindings(m Manifest) ([]capability.Binding, error)
- func CheckAdditionalProviderResources(m Manifest, additional []capability.Resource) error
- func CheckAdditionalProviderResourcesAt(dataDir string, m Manifest, additional []capability.Resource) error
- func CheckApplicationConnectivityReleased(m Manifest) error
- func CheckApplicationConnectivityReleasedAt(dataDir string, m Manifest) error
- func CheckControlPlaneDestroySafe() error
- func CheckControlPlaneDestroySafeAt(dataDir string) error
- func CheckManagedRuntimeDefinition(files RuntimeFiles, m Manifest) error
- func CheckReferenceProviderRegistry(m Manifest) error
- func CheckReferenceProviderRegistryAt(dataDir string, m Manifest) error
- func CheckRuntimePermissions(files RuntimeFiles) error
- func CheckSupportedRuntimeServices(m Manifest) error
- func ConfiguredRuntimeAPIURL() (string, bool, error)
- func ConnectivityNetworkName(rule ConnectivityRule) string
- func ConnectivityRuleID(rule ConnectivityRule) string
- func ConnectivityTargetAlias(rule ConnectivityRule) string
- func ConsumptionBindingID(producer LogicalProducerReference) string
- func DefaultProviderPlacement(provider capability.ProviderKind) (capability.ProviderPlacement, error)
- func DestroyAllSharedBackendsAt(ctx context.Context, compose bhruntime.RuntimeProvider, ...) error
- func DevelopmentWorkloadAlias(m Manifest) string
- func DevelopmentWorkloadNetworkNameForProject(project string) string
- func DocumentDatabaseInstanceNames(m Manifest) []string
- func EnsureApplicationManagementUIs(ctx context.Context, issuer serviceaccess.Issuer, files RuntimeFiles, ...) error
- func EnsureBackendServiceAccess(ctx context.Context, issuer serviceaccess.Issuer, files RuntimeFiles, ...) error
- func EnsureRuntimeIdentity(m Manifest, files RuntimeFiles) (string, error)
- func EnsureRuntimeServiceIdentities(m Manifest, files RuntimeFiles) (map[string]string, error)
- func ExpectedPersistentRuntimeResources(m Manifest) []bhruntime.ProjectResource
- func ExpectedPersistentRuntimeResourcesForProject(m Manifest, project string) []bhruntime.ProjectResource
- func ExpectedPostgresRuntimeResources(m Manifest) []bhruntime.ProjectResource
- func ExpectedRuntimeResources(m Manifest) []bhruntime.ProjectResource
- func ExpectedRuntimeResourcesForIdentity(m Manifest, composeProject, resourceProject string) []bhruntime.ProjectResource
- func ExpectedRuntimeResourcesForProject(m Manifest, project string) []bhruntime.ProjectResource
- func ExternalOTLPEndpoint() string
- func FindRepositoryManifest(start string) (string, error)
- func GenerateSecretValue(generation SecretGeneration) ([]byte, error)
- func HasApplicationScopedRuntimeServices(m Manifest) bool
- func HasExplicitWorkload(m Manifest) bool
- func HasIdentity(m Manifest) bool
- func HasLogsCollection(m Manifest) bool
- func HasManagedRuntimeServices(m Manifest) bool
- func HasMetricsSources(m Manifest) bool
- func HasOTLPTelemetry(m Manifest) bool
- func HasObjectStorage(m Manifest) bool
- func HasRepositoryApplication(start string) (bool, error)
- func HasRequiredFileSecrets(m Manifest) bool
- func HasRuntimeCapabilityPermission(m Manifest, capabilityID string) bool
- func HasRuntimeMetricsPermissions(m Manifest) bool
- func HasSharedBackends(m Manifest) bool
- func HasTraceSignal(m Manifest) bool
- func IdentityProviderForDeployment() (capability.Provider, error)
- func IdentityProviderNetworkName(m Manifest, namespace string) (string, error)
- func InspectExternalProvider(id string) (externalprovider.Registration, error)
- func InspectOwnedRuntimeResources(ctx context.Context, compose bhruntime.RuntimeProvider, m Manifest) ([]bhruntime.ProjectResource, error)
- func InspectOwnedRuntimeResourcesForFiles(ctx context.Context, compose bhruntime.RuntimeProvider, m Manifest, ...) ([]bhruntime.ProjectResource, error)
- func KeyValueInstanceNames(m Manifest) []string
- func ListExternalProviders() ([]externalprovider.Registration, error)
- func LogsCollectionEnabled(m Manifest) (bool, error)
- func ManagedRuntimeProviderServiceNames(m Manifest) []string
- func ManagedSecretsSecureBinding(m Manifest) capability.SecureBinding
- func ManagedWorkloadEnvironment(m Manifest, files RuntimeFiles) (map[string]string, error)
- func MaterializeIdentityBinding(m Manifest, files RuntimeFiles, provider string, discovery IdentityDiscovery, ...) error
- func MaterializeIdentityBindingMaterial(m Manifest, files RuntimeFiles, provider string, discovery IdentityDiscovery, ...) error
- func MaterializeIdentityBindingWithWorkloadDiscovery(m Manifest, files RuntimeFiles, provider string, ...) error
- func MaterializeIdentityBindingWithWorkloadDiscoveryMaterial(m Manifest, files RuntimeFiles, provider string, ...) error
- func MaterializeOTLPBinding(m Manifest, files RuntimeFiles, provider capability.ProviderKind, ...) error
- func MaterializeOTLPTLSBinding(m Manifest, files RuntimeFiles, caFile, clientCertFile, clientKeyFile string) error
- func MaterializeOTLPTLSBindingMaterial(m Manifest, files RuntimeFiles, caData, clientCertData, clientKeyData []byte) error
- func MaterializeObjectStorageBinding(m Manifest, files RuntimeFiles, ...) error
- func MaterializeObjectStorageBindingMaterial(m Manifest, files RuntimeFiles, ...) error
- func MaterializeRuntimeIdentityWorkloadOverride(m Manifest, workload WorkloadFiles, files RuntimeFiles, ...) (string, bool, error)
- func MessagingPubSubInstanceNames(m Manifest) []string
- func MessagingQueueInstanceNames(m Manifest) []string
- func MessagingStreamInstanceNames(m Manifest) []string
- func MetricsCollectionEnabled(m Manifest) (bool, error)
- func MetricsProviderNetworkName(m Manifest) string
- func MetricsProviderNetworkNameForNamespace(m Manifest, namespace string) string
- func MetricsRuntimeTargetVolumeName(m Manifest) string
- func MetricsRuntimeTargetVolumeNameForNamespace(m Manifest, namespace string) string
- func MetricsTargetAlias(m Manifest, service string) string
- func MetricsTargetAliasFor(applicationName, environment, service string) string
- func MongoDBHAPrimary(ctx context.Context, runtime mongoDBHAProbeRuntime, m Manifest, ...) (string, error)
- func MongoDBManagementUIRouteName(instance string) string
- func MustNewApplicationID() string
- func NewApplicationID() (string, error)
- func ObjectStorageBucketNames(m Manifest) []string
- func ObjectStorageSecureBinding(m Manifest, bucket string) capability.SecureBinding
- func OptionalSecretNames(m Manifest) []string
- func ProviderExternalReferenceEnv(provider capability.ProviderKind) string
- func ProviderPlacementNameToken(value string) string
- func ProviderScopeEnv(provider capability.ProviderKind) string
- func ProviderSharingBoundaryEnv(provider capability.ProviderKind) string
- func RabbitMQInstanceNames(m Manifest) []string
- func RabbitMQManagementUIRouteName(instance string) string
- func ReallocateRuntimePorts(m Manifest, files RuntimeFiles) error
- func ReconcileMongoDBHA(ctx context.Context, runtime mongoDBHAProbeRuntime, m Manifest, ...) error
- func ReconcileRabbitMQCredentials(ctx context.Context, runtime rabbitMQCredentialRuntime, m Manifest, ...) error
- func ReconcileReferenceProviderRegistry(m Manifest, additional ...capability.Resource) error
- func ReconcileReferenceProviderRegistryAt(dataDir string, m Manifest, additional ...capability.Resource) error
- func ReconcileRuntimeComponentObservability(m Manifest, component RuntimeComponentObservability) error
- func ReconcileSharedBackends(ctx context.Context, compose bhruntime.RuntimeProvider, ...) (bool, error)
- func RegisterExternalProvider(reg externalprovider.Registration) error
- func RegisterExternalProviderAt(dataDir string, reg externalprovider.Registration) error
- func RegisteredProviderPlacement(m Manifest, provider capability.ProviderKind) (capability.ProviderPlacement, bool, error)
- func RegisteredProviderPlacementAt(dataDir string, m Manifest, provider capability.ProviderKind) (capability.ProviderPlacement, bool, error)
- func ReleaseApplicationProviderRegistry(m Manifest) error
- func ReleaseApplicationProviderRegistryAt(dataDir string, m Manifest) error
- func ReleaseSharedBackendApplication(ctx context.Context, compose bhruntime.RuntimeProvider, ...) error
- func RemoveConnectivityRule(rule ConnectivityRule) error
- func RemoveConnectivityRuleAt(dataDir string, rule ConnectivityRule) error
- func RemoveExternalProvider(id string) error
- func RemoveExternalProviderAt(dataDir, id string) error
- func ReplaceObjectStorageCredentials(m Manifest, files RuntimeFiles, bucket string, ...) error
- func RepositoryEnvironmentStateRoot(selection RepositoryEnvironmentSelection) string
- func RequiredSecretNames(m Manifest) []string
- func RequiredSecretUsesFileBinding(name string) bool
- func RequiresRuntimeBroker(m Manifest) bool
- func ResolveCapabilityResources(contract PortableContract) ([]capability.Resource, error)
- func ResolveProviderPlacement(m Manifest, provider capability.ProviderKind) (capability.ProviderPlacement, error)
- func ResolveWorkloadCompose(repositoryRoot string) (string, bool, error)
- func ResolveWorkloadComposeSource(repositoryRoot, sourcePath string) (string, error)
- func ResourceExists(resources []bhruntime.ProjectResource, kind string) bool
- func ResourceNamedExists(resources []bhruntime.ProjectResource, wanted bhruntime.ProjectResource) bool
- func RestorePostgresInstances(ctx context.Context, runtime PostgresBackupRuntime, m Manifest, ...) error
- func RestorePostgresInstancesAt(ctx context.Context, runtime PostgresBackupRuntime, m Manifest, ...) error
- func RevokeRuntimeIdentity(m Manifest, files RuntimeFiles) error
- func RotateManagedProviderPKI(ctx context.Context, runtime bhruntime.RuntimeProvider, ...) error
- func RotateMongoDBCredential(ctx context.Context, runtime bhruntime.RuntimeProvider, m Manifest, ...) error
- func RotateRabbitMQCredential(ctx context.Context, runtime bhruntime.RuntimeProvider, m Manifest, ...) error
- func RotateRuntimeIdentity(m Manifest, files RuntimeFiles) error
- func RotateValkeyCredential(ctx context.Context, runtime bhruntime.RuntimeProvider, ...) error
- func RuntimeAuthorizedServices(m Manifest) []string
- func RuntimeComposeProjectNameForStore(store Store, m Manifest) string
- func RuntimeComposeYAML(m Manifest) (string, error)
- func RuntimeComposeYAMLForProject(m Manifest, resourceProject string) (string, error)
- func RuntimeEnvironment(files RuntimeFiles) (map[string]string, error)
- func RuntimeIdentityRevoked(files RuntimeFiles) bool
- func RuntimeIdentityRevokedPath(files RuntimeFiles) string
- func RuntimeIdentityTokenPath(files RuntimeFiles) string
- func RuntimeMTLSHostDir(files RuntimeFiles) string
- func RuntimePermissionFor(m Manifest, capabilityID, operation string) bool
- func RuntimeProjectName(m Manifest) string
- func RuntimeProjectNameForStore(store Store, m Manifest) string
- func RuntimeServiceIdentityDir(files RuntimeFiles) string
- func RuntimeServiceIdentityTokenPath(files RuntimeFiles, service string) string
- func SQLInstanceNames(m Manifest) []string
- func SecretFileContainerPath(name string) string
- func SecretFileHostDir(files RuntimeFiles) string
- func SecretFileHostPath(files RuntimeFiles, name string) string
- func SelectedWorkloadServices(repositoryRoot string, m Manifest) ([]string, string, bool, error)
- func SelectedWorkloadServicesFromCompose(repositoryRoot, sourcePath string, m Manifest) ([]string, string, error)
- func SharedBackendNetworkName(namespace, environment string) string
- func TelemetryProviderForDeployment() capability.Provider
- func TracesCollectionEnabled(m Manifest) (bool, error)
- func UsesSharedPostgreSQL(m Manifest) bool
- func UsesSharedValkey(m Manifest) bool
- func ValidateApplicationID(id string) error
- func ValidateManagementAuthenticationClass(class ManagementAuthenticationClass) error
- func ValidateManagementRoleMappings(mappings []ManagementRoleMapping) error
- func ValidatePostgresBackupSet(m Manifest, backups []PostgresBackup) error
- func ValkeyHAMaster(ctx context.Context, runtime valkeyHAProbeRuntime, m Manifest, ...) (string, error)
- func ValkeyInstanceNames(m Manifest) []string
- func VerifyApplicationManagementUIs(ctx context.Context, m Manifest, files RuntimeFiles) error
- func VerifyExternalProvider(ctx context.Context, id string) (externalprovider.Verification, error)
- func VerifyIdentityBinding(m Manifest, files RuntimeFiles) error
- func VerifyManagedProviderInteractions(ctx context.Context, runtime bhruntime.RuntimeProvider, m Manifest, ...) error
- func VerifyMongoDBHACluster(ctx context.Context, runtime mongoDBHAProbeRuntime, m Manifest, ...) error
- func VerifyMongoDBRuntime(ctx context.Context, m Manifest, files RuntimeFiles) error
- func VerifyPostgresProvider(ctx context.Context, executor BackendProbeExecutor, m Manifest) error
- func VerifyPostgresRuntime(ctx context.Context, runtime bhruntime.RuntimeProvider, m Manifest, ...) error
- func VerifyRabbitMQHACluster(ctx context.Context, runtime rabbitMQHAProbeRuntime, m Manifest, ...) error
- func VerifyRabbitMQRuntime(ctx context.Context, m Manifest, files RuntimeFiles) error
- func VerifySharedBackends(ctx context.Context, compose bhruntime.RuntimeProvider, ...) error
- func VerifySharedPostgreSQL(ctx context.Context, compose bhruntime.RuntimeProvider, ...) error
- func VerifySharedValkey(ctx context.Context, compose bhruntime.RuntimeProvider, ...) error
- func VerifyValkeyHACluster(ctx context.Context, runtime valkeyHAProbeRuntime, m Manifest, ...) error
- func VerifyValkeyProvider(ctx context.Context, executor BackendProbeExecutor, m Manifest) error
- func VerifyValkeyRuntime(ctx context.Context, runtime bhruntime.RuntimeProvider, m Manifest, ...) error
- func VerifyWorkloadServiceBindings(m Manifest, files RuntimeFiles) error
- func WorkloadComponentNames(m Manifest) []string
- func WorkloadProjectName(m Manifest) string
- func WorkloadProjectNameForNamespace(m Manifest, namespace string) string
- func WorkloadProjectNameForRuntime(m Manifest, runtime RuntimeFiles) string
- func WorkloadServiceBindingProjectionDir(files RuntimeFiles) string
- type Action
- type AvailabilityResolution
- type BackendProbe
- type BackendProbeExecutor
- type BackendProbeKind
- type BackendTLSLifecycleObservation
- type BackupMetadata
- type CapabilityKind
- type CapabilityRequirement
- type ConnectivityEndpoint
- type ConnectivityRule
- type ConsumptionRequirement
- type EffectiveIdentityPolicy
- type HTTPExposureRequirement
- type IdentityAuthenticationRequirements
- type IdentityDiscovery
- type IdentityRequirements
- type LogicalProducerReference
- type LogsDeploymentPolicy
- type LogsRequirements
- type LogsSourceClass
- type ManagedProviderPKIKind
- type ManagementAuthenticationClass
- type ManagementRole
- type ManagementRoleMapping
- type ManagementRoleMappingLevel
- type ManagementUICheckResult
- type ManagementUISurface
- type Manifest
- func LoadManifestFile(path string) (Manifest, error)
- func New(name, environment string, sql, cache, secrets bool) Manifest
- func ParseYAML(input string) (Manifest, error)
- func WithAvailabilityOverride(m Manifest, component string, ha *bool, instances int) Manifest
- func WithCacheInstances(m Manifest, names ...string) Manifest
- func WithDocumentDatabaseInstances(m Manifest, names ...string) Manifest
- func WithGeneratedSecret(m Manifest, name, generationType string, size int) Manifest
- func WithHA(m Manifest, enabled bool) Manifest
- func WithHTTPExposure(m Manifest, name, service string, port int, protocol string) Manifest
- func WithIdentity(m Manifest) Manifest
- func WithIdentityAuthentication(m Manifest, mfa string, methods []string, passwordless bool) Manifest
- func WithIdentityCallbackPath(m Manifest, path string) Manifest
- func WithIdentityLogoutPath(m Manifest, path string) Manifest
- func WithKeyValueInstances(m Manifest, names ...string) Manifest
- func WithLogsCollection(m Manifest, sources ...string) Manifest
- func WithMessagingPubSubInstances(m Manifest, names ...string) Manifest
- func WithMessagingQueueInstances(m Manifest, names ...string) Manifest
- func WithMessagingStreamInstances(m Manifest, names ...string) Manifest
- func WithMetricsSource(m Manifest, name, service string, port int, path string) Manifest
- func WithOTLPTelemetry(m Manifest, signals ...string) Manifest
- func WithObjectStorageBuckets(m Manifest, names ...string) Manifest
- func WithOptionalGeneratedSecret(m Manifest, name, generationType string, size int) Manifest
- func WithOptionalSecrets(m Manifest, names ...string) Manifest
- func WithRequiredSecrets(m Manifest, names ...string) Manifest
- func WithRuntimePermission(m Manifest, capabilityID string, services []string, operations ...string) Manifest
- func WithSQLInstances(m Manifest, names ...string) Manifest
- func WithWorkloadComponents(m Manifest, components ...string) Manifest
- type MetricsDeploymentPolicy
- type MetricsRequirements
- type MetricsSourceClass
- type MetricsSourceRequirement
- type OTLPRequirement
- type ObjectStorageCredentials
- type Plan
- type PortableContract
- type PostgresBackup
- type PostgresBackupRuntime
- type ProviderInterfacePurpose
- type RecoveryContributorMetadata
- type RecoveryMetadata
- type RepositoryEnvironmentSelection
- type ResolvedConsumption
- type RuntimeBackendProbeExecutor
- type RuntimeComponentObservability
- type RuntimeContract
- type RuntimeFiles
- func EnsurePostgresRuntime(ctx context.Context, issuer serviceaccess.Issuer, store Store, m Manifest) (RuntimeFiles, error)
- func EnsureRuntime(ctx context.Context, issuer serviceaccess.Issuer, store Store, m Manifest) (RuntimeFiles, error)
- func ExistingRuntimeFiles(store Store, m Manifest) (RuntimeFiles, error)
- func RuntimeFilesFor(store Store, m Manifest) RuntimeFiles
- type RuntimeOTLPBinding
- type RuntimePermission
- type RuntimeRequirements
- type SecretContract
- type SecretGeneration
- type SecretRequirement
- type SecretRequirements
- type ServiceBinding
- type ServiceInstance
- type Services
- type SharedBackendFiles
- type SharedPostgresResourceObservation
- type StatusCheck
- type StatusResult
- type Store
- func (s Store) Create(m Manifest) (string, error)
- func (s Store) Delete(name string) error
- func (s Store) LastBackup(applicationName string) (BackupMetadata, error)
- func (s Store) LastRecovery(applicationName string) (RecoveryMetadata, error)
- func (s Store) LastUpdate(applicationName string) (UpdateMetadata, error)
- func (s Store) List() ([]Manifest, error)
- func (s Store) Load(name string) (Manifest, string, error)
- func (s Store) RecordLastBackup(metadata BackupMetadata) error
- func (s Store) RecordLastRecovery(metadata RecoveryMetadata) error
- func (s Store) RecordLastUpdate(metadata UpdateMetadata) error
- func (s Store) Sync(m Manifest) (string, error)
- type TelemetryRequirements
- type TracesDeploymentPolicy
- type TracesSourceClass
- type UpdateMetadata
- type WorkloadBindingPlan
- type WorkloadConfig
- type WorkloadFiles
- type WorkloadSecurityDecision
- type WorkloadSecurityFinding
- type WorkloadSecurityPolicy
- type WorkloadSecurityReport
Constants ¶
const ( IdentityBindingName = "identity" IdentityWorkloadClientSecretFile = "/run/baseharbor/service-bindings/identity/client-secret" )
const ( IdentityMFAEnv = "BASEHARBOR_IDENTITY_MFA" IdentityMethodsEnv = "BASEHARBOR_IDENTITY_METHODS" IdentityPasswordlessEnv = "BASEHARBOR_IDENTITY_PASSWORDLESS" )
const ( LogsEnabledEnv = "BASEHARBOR_LOGS_ENABLED" LogsCollectSourcesEnv = "BASEHARBOR_LOGS_COLLECT" )
const ( PostgresUIHostPortEnv = "BASEHARBOR_POSTGRES_UI_HOST_PORT" PostgresUIEmailEnv = "BASEHARBOR_POSTGRES_UI_EMAIL" PostgresUIPasswordEnv = "BASEHARBOR_POSTGRES_UI_PASSWORD" CacheUIHostPortEnv = "BASEHARBOR_CACHE_UI_HOST_PORT" CacheUIUserEnv = "BASEHARBOR_CACHE_UI_USER" CacheUIPasswordEnv = "BASEHARBOR_CACHE_UI_PASSWORD" MongoDBUIUserEnv = "BASEHARBOR_MONGODB_UI_USER" MongoDBUIPasswordEnv = "BASEHARBOR_MONGODB_UI_PASSWORD" PostgresUIImage = "docker.io/dpage/pgadmin4:9.18" CacheUIImage = "ghcr.io/joeferner/redis-commander:0.9.1" MongoDBUIImage = "docker.io/huggingface/mongoku:2.11.3" UIProxyImage = "docker.io/library/caddy:2.11.4-alpine" )
const ( MetricsEnabledEnv = "BASEHARBOR_METRICS_ENABLED" MetricsCollectSourcesEnv = "BASEHARBOR_METRICS_COLLECT" )
const ( S3TLSHostCAEnv = "S3_TLS_CA_FILE" S3TLSContainerCA = "/run/baseharbor/bindings/object-storage/ca.pem" )
const ( DefaultRuntimeAPIURL = "https://baseharbor-runtime:8443" RuntimeIdentityContainerTokenPath = "/run/secrets/baseharbor-runtime-token" RuntimeIdentityContainerCAPath = "/run/secrets/baseharbor-runtime-ca" RuntimeIdentityContainerClientCertPath = "/run/secrets/baseharbor-runtime-client-cert" RuntimeIdentityContainerClientKeyPath = "/run/secrets/baseharbor-runtime-client-key" RuntimeIdentityContainerTLSCertPath = "/run/secrets/baseharbor-tls-cert" RuntimeIdentityContainerTLSKeyPath = "/run/secrets/baseharbor-tls-key" SecretFileBindingContainerDir = "/run/baseharbor/bindings/secrets" )
const ( OTLPProviderEnv = "BASEHARBOR_OTLP_PROVIDER" OTLPEndpointEnv = "BASEHARBOR_OTLP_ENDPOINT" )
const ( OTLPTLSHostCAEnv = "OTLP_TLS_CA_FILE" OTLPTLSHostClientCertEnv = "OTLP_TLS_CLIENT_CERT_FILE" OTLPTLSHostClientKeyEnv = "OTLP_TLS_CLIENT_KEY_FILE" OTLPTLSContainerCA = "/run/baseharbor/bindings/telemetry/ca.pem" OTLPTLSContainerClientCert = "/run/baseharbor/bindings/telemetry/client-cert.pem" OTLPTLSContainerClientKey = "/run/baseharbor/bindings/telemetry/client-key.pem" )
const ( TracesEnabledEnv = "BASEHARBOR_TRACES_ENABLED" TracesCollectSourcesEnv = "BASEHARBOR_TRACES_COLLECT" )
const ( WorkloadSecurityModeEnv = "BASEHARBOR_WORKLOAD_SECURITY_MODE" WorkloadSecurityAllowEnv = "BASEHARBOR_WORKLOAD_SECURITY_ALLOW" )
const CurrentVersion = 1
const (
LastBackupMetadataVersion = 2
)
const (
LastRecoveryMetadataVersion = 2
)
const (
LastUpdateMetadataVersion = 1
)
const MaxPostgresBackupBytes int64 = 512 << 20
const MongoDBImage = "docker.io/library/mongo:7.0.43"
const RepositoryManifestName = "baseharbor.yaml"
Variables ¶
var ErrExists = errors.New("application already exists")
var ErrNoBackupMetadata = errors.New("no application backup metadata recorded")
var ErrNoRecoveryMetadata = errors.New("no application recovery metadata recorded")
var ErrNoUpdateMetadata = errors.New("no application update metadata recorded")
var ErrRepositoryManifestNotFound = errors.New("repository manifest not found")
var ErrRuntimeAPIURL = errors.New("application runtime API URL is invalid")
var ErrRuntimeDefinitionChanged = errors.New("application runtime definition differs from the BaseHarbor-managed definition")
var ErrRuntimeNotApplied = errors.New("application runtime has not been applied")
var ErrUnsupportedService = errors.New("application contains services that are not yet supported by apply")
var ErrWorkloadComposeAmbiguous = errors.New("multiple application Compose files found")
var ErrWorkloadComposeNotFound = errors.New("application Compose file not found")
Functions ¶
func AddConnectivityRule ¶ added in v0.4.8
func AddConnectivityRule(rule ConnectivityRule) error
func AddConnectivityRuleAt ¶ added in v0.4.15
func AddConnectivityRuleAt(dataDir string, rule ConnectivityRule) error
func ApplicationBackendNetworkName ¶
ApplicationBackendNetworkName returns the legacy stable network name.
func ApplicationBackendNetworkNameForProject ¶ added in v0.4.15
func ApplicationExposureNetworkName ¶ added in v0.4.4
ApplicationExposureNetworkName returns the legacy exposure network name.
func ApplicationExposureNetworkNameForProject ¶ added in v0.4.15
func ApplyDevelopmentManagementUICredentials ¶ added in v0.4.17
func ApplyDevelopmentManagementUICredentials(ctx context.Context, issuer serviceaccess.Issuer, files RuntimeFiles, m Manifest, username, password string) error
func AvailabilityIntent ¶ added in v0.4.21
func AvailabilityIntent(m Manifest) availability.Intent
func CacheInstanceNames ¶ added in v0.4.15
func CapabilityBindings ¶ added in v0.4.1
func CapabilityBindings(m Manifest) ([]capability.Binding, error)
func CheckAdditionalProviderResources ¶ added in v0.4.9
func CheckAdditionalProviderResources(m Manifest, additional []capability.Resource) error
func CheckAdditionalProviderResourcesAt ¶ added in v0.4.15
func CheckAdditionalProviderResourcesAt(dataDir string, m Manifest, additional []capability.Resource) error
func CheckApplicationConnectivityReleased ¶ added in v0.4.8
func CheckApplicationConnectivityReleasedAt ¶ added in v0.4.15
func CheckControlPlaneDestroySafe ¶ added in v0.4.4
func CheckControlPlaneDestroySafe() error
func CheckControlPlaneDestroySafeAt ¶ added in v0.4.15
func CheckManagedRuntimeDefinition ¶
func CheckManagedRuntimeDefinition(files RuntimeFiles, m Manifest) error
CheckManagedRuntimeDefinition prevents destructive operations from trusting a locally modified Compose file. BaseHarbor may only mutate the runtime shape it originally generated and understands for the current manifest.
func CheckReferenceProviderRegistry ¶ added in v0.4.4
CheckReferenceProviderRegistry validates the protected provider registry and simulates the desired application reconciliation without writing it. Lifecycle callers use this during preflight so invalid provider metadata fails before any runtime or workload mutation.
func CheckReferenceProviderRegistryAt ¶ added in v0.4.15
func CheckRuntimePermissions ¶
func CheckRuntimePermissions(files RuntimeFiles) error
func ConfiguredRuntimeAPIURL ¶
func ConnectivityNetworkName ¶ added in v0.4.8
func ConnectivityNetworkName(rule ConnectivityRule) string
func ConnectivityRuleID ¶ added in v0.4.8
func ConnectivityRuleID(rule ConnectivityRule) string
func ConnectivityTargetAlias ¶ added in v0.4.8
func ConnectivityTargetAlias(rule ConnectivityRule) string
func ConsumptionBindingID ¶ added in v0.4.21
func ConsumptionBindingID(producer LogicalProducerReference) string
func DefaultProviderPlacement ¶ added in v0.4.8
func DefaultProviderPlacement(provider capability.ProviderKind) (capability.ProviderPlacement, error)
func DestroyAllSharedBackendsAt ¶ added in v0.4.17
func DevelopmentWorkloadAlias ¶ added in v0.4.17
func DevelopmentWorkloadNetworkNameForProject ¶ added in v0.4.17
func DocumentDatabaseInstanceNames ¶ added in v0.4.19
func EnsureApplicationManagementUIs ¶ added in v0.4.17
func EnsureApplicationManagementUIs(ctx context.Context, issuer serviceaccess.Issuer, files RuntimeFiles, m Manifest) error
func EnsureBackendServiceAccess ¶ added in v0.4.15
func EnsureBackendServiceAccess(ctx context.Context, issuer serviceaccess.Issuer, files RuntimeFiles, m Manifest) error
func EnsureRuntimeIdentity ¶
func EnsureRuntimeIdentity(m Manifest, files RuntimeFiles) (string, error)
func EnsureRuntimeServiceIdentities ¶ added in v0.4.8
func EnsureRuntimeServiceIdentities(m Manifest, files RuntimeFiles) (map[string]string, error)
func ExpectedPersistentRuntimeResources ¶
func ExpectedPersistentRuntimeResources(m Manifest) []bhruntime.ProjectResource
func ExpectedPersistentRuntimeResourcesForProject ¶ added in v0.4.15
func ExpectedPersistentRuntimeResourcesForProject(m Manifest, project string) []bhruntime.ProjectResource
func ExpectedPostgresRuntimeResources ¶
func ExpectedPostgresRuntimeResources(m Manifest) []bhruntime.ProjectResource
ExpectedPostgresRuntimeResources is kept for compatibility with the first runtime milestone. New lifecycle code should use ExpectedRuntimeResources.
func ExpectedRuntimeResources ¶
func ExpectedRuntimeResources(m Manifest) []bhruntime.ProjectResource
func ExpectedRuntimeResourcesForIdentity ¶ added in v0.4.16
func ExpectedRuntimeResourcesForIdentity(m Manifest, composeProject, resourceProject string) []bhruntime.ProjectResource
func ExpectedRuntimeResourcesForProject ¶ added in v0.4.15
func ExpectedRuntimeResourcesForProject(m Manifest, project string) []bhruntime.ProjectResource
func ExternalOTLPEndpoint ¶ added in v0.4.7
func ExternalOTLPEndpoint() string
func FindRepositoryManifest ¶
FindRepositoryManifest returns the nearest baseharbor.yaml from start upward. This lets developers run baha from nested directories inside an application repository.
func GenerateSecretValue ¶
func GenerateSecretValue(generation SecretGeneration) ([]byte, error)
func HasApplicationScopedRuntimeServices ¶ added in v0.4.17
func HasExplicitWorkload ¶ added in v0.3.0
HasExplicitWorkload reports whether portable application intent declares logical workload components. Source-format metadata is not required here.
func HasIdentity ¶ added in v0.4.17
func HasLogsCollection ¶ added in v0.4.11
func HasManagedRuntimeServices ¶ added in v0.3.0
HasManagedRuntimeServices reports whether BaseHarbor owns a materialized PostgreSQL, Valkey, RabbitMQ or MongoDB runtime for the application. Shared object storage uses its own lazy provider runtime and is intentionally not part of this project.
func HasMetricsSources ¶ added in v0.4.8
func HasOTLPTelemetry ¶ added in v0.4.7
func HasObjectStorage ¶ added in v0.4.6
HasObjectStorage reports whether the application explicitly requests at least one logical S3 bucket.
func HasRepositoryApplication ¶ added in v0.4.13
HasRepositoryApplication reports whether start is inside a repository that carries either the compatibility root manifest or one or more complete environment manifests. It intentionally does not select an environment.
func HasRequiredFileSecrets ¶
func HasRuntimeCapabilityPermission ¶ added in v0.4.8
func HasRuntimeMetricsPermissions ¶ added in v0.4.8
func HasSharedBackends ¶ added in v0.4.17
func HasTraceSignal ¶ added in v0.4.10
func IdentityProviderForDeployment ¶ added in v0.4.17
func IdentityProviderForDeployment() (capability.Provider, error)
func IdentityProviderNetworkName ¶ added in v0.4.17
func InspectExternalProvider ¶ added in v0.4.19
func InspectExternalProvider(id string) (externalprovider.Registration, error)
func InspectOwnedRuntimeResources ¶
func InspectOwnedRuntimeResources(ctx context.Context, compose bhruntime.RuntimeProvider, m Manifest) ([]bhruntime.ProjectResource, error)
func InspectOwnedRuntimeResourcesForFiles ¶ added in v0.4.15
func InspectOwnedRuntimeResourcesForFiles(ctx context.Context, compose bhruntime.RuntimeProvider, m Manifest, files RuntimeFiles) ([]bhruntime.ProjectResource, error)
func KeyValueInstanceNames ¶ added in v0.4.19
func ListExternalProviders ¶ added in v0.4.19
func ListExternalProviders() ([]externalprovider.Registration, error)
func LogsCollectionEnabled ¶ added in v0.4.9
func ManagedRuntimeProviderServiceNames ¶ added in v0.4.16
func ManagedSecretsSecureBinding ¶ added in v0.4.5
func ManagedSecretsSecureBinding(m Manifest) capability.SecureBinding
ManagedSecretsSecureBinding describes the existing BaseHarbor runtime identity/secret-delivery semantics without exposing OpenBao paths, AppRoles, policies, tokens, private keys, or provider-specific object names.
func ManagedWorkloadEnvironment ¶ added in v0.4.16
func ManagedWorkloadEnvironment(m Manifest, files RuntimeFiles) (map[string]string, error)
func MaterializeIdentityBinding ¶ added in v0.4.17
func MaterializeIdentityBinding(m Manifest, files RuntimeFiles, provider string, discovery IdentityDiscovery, clientID, clientSecret, trustBundlePath string) error
func MaterializeIdentityBindingMaterial ¶ added in v0.4.19
func MaterializeIdentityBindingMaterial(m Manifest, files RuntimeFiles, provider string, discovery IdentityDiscovery, clientID, clientSecret string, trustBundle []byte) error
func MaterializeIdentityBindingWithWorkloadDiscovery ¶ added in v0.4.17
func MaterializeIdentityBindingWithWorkloadDiscovery(m Manifest, files RuntimeFiles, provider string, discovery, workloadDiscovery IdentityDiscovery, clientID, clientSecret, trustBundlePath string) error
func MaterializeIdentityBindingWithWorkloadDiscoveryMaterial ¶ added in v0.4.19
func MaterializeIdentityBindingWithWorkloadDiscoveryMaterial(m Manifest, files RuntimeFiles, provider string, discovery, workloadDiscovery IdentityDiscovery, clientID, clientSecret string, trustBundle []byte) error
func MaterializeOTLPBinding ¶ added in v0.4.7
func MaterializeOTLPBinding(m Manifest, files RuntimeFiles, provider capability.ProviderKind, hostEndpoint, containerEndpoint string) error
func MaterializeOTLPTLSBinding ¶ added in v0.4.15
func MaterializeOTLPTLSBinding(m Manifest, files RuntimeFiles, caFile, clientCertFile, clientKeyFile string) error
func MaterializeOTLPTLSBindingMaterial ¶ added in v0.4.19
func MaterializeOTLPTLSBindingMaterial(m Manifest, files RuntimeFiles, caData, clientCertData, clientKeyData []byte) error
func MaterializeObjectStorageBinding ¶ added in v0.4.6
func MaterializeObjectStorageBinding(m Manifest, files RuntimeFiles, logicalBucket, physicalBucket, endpoint, containerEndpoint, caFile string) error
MaterializeObjectStorageBinding updates the standard application-facing environment/file binding after the selected provider has materialized its concrete endpoint and bucket identity.
func MaterializeObjectStorageBindingMaterial ¶ added in v0.4.19
func MaterializeObjectStorageBindingMaterial(m Manifest, files RuntimeFiles, logicalBucket, physicalBucket, endpoint, containerEndpoint string, caData []byte) error
func MaterializeRuntimeIdentityWorkloadOverride ¶
func MaterializeRuntimeIdentityWorkloadOverride(m Manifest, workload WorkloadFiles, files RuntimeFiles, plan WorkloadBindingPlan) (string, bool, error)
MaterializeRuntimeIdentityWorkloadOverride adds only the protected bindings that selected application services actually consume. Runtime identity is injected through ordinary environment file paths plus Compose secret mounts; applications do not configure certificates, keys or broker topology.
func MessagingPubSubInstanceNames ¶ added in v0.4.19
func MessagingQueueInstanceNames ¶ added in v0.4.19
func MessagingStreamInstanceNames ¶ added in v0.4.19
func MetricsCollectionEnabled ¶ added in v0.4.8
MetricsCollectionEnabled is deployment policy, not portable application intent. Local development enables collection by default; test/staging/production require an explicit operator opt-in unless overridden with BASEHARBOR_METRICS_ENABLED.
func MetricsProviderNetworkName ¶ added in v0.4.8
func MetricsProviderNetworkNameForNamespace ¶ added in v0.4.15
func MetricsRuntimeTargetVolumeName ¶ added in v0.4.8
func MetricsRuntimeTargetVolumeNameForNamespace ¶ added in v0.4.15
func MetricsTargetAlias ¶ added in v0.4.8
func MetricsTargetAliasFor ¶ added in v0.4.8
func MongoDBHAPrimary ¶ added in v0.4.21
func MongoDBManagementUIRouteName ¶ added in v0.4.19
func MustNewApplicationID ¶ added in v0.4.19
func MustNewApplicationID() string
func NewApplicationID ¶ added in v0.4.19
func ObjectStorageBucketNames ¶ added in v0.4.6
func ObjectStorageSecureBinding ¶ added in v0.4.6
func ObjectStorageSecureBinding(m Manifest, bucket string) capability.SecureBinding
ObjectStorageSecureBinding describes one application-owned S3 bucket without exposing concrete credentials or provider-specific identity/policy objects.
func OptionalSecretNames ¶ added in v0.4.15
func ProviderExternalReferenceEnv ¶ added in v0.4.8
func ProviderExternalReferenceEnv(provider capability.ProviderKind) string
func ProviderPlacementNameToken ¶ added in v0.4.8
func ProviderScopeEnv ¶ added in v0.4.8
func ProviderScopeEnv(provider capability.ProviderKind) string
func ProviderSharingBoundaryEnv ¶ added in v0.4.8
func ProviderSharingBoundaryEnv(provider capability.ProviderKind) string
func RabbitMQInstanceNames ¶ added in v0.4.19
func RabbitMQManagementUIRouteName ¶ added in v0.4.19
func ReallocateRuntimePorts ¶
func ReallocateRuntimePorts(m Manifest, files RuntimeFiles) error
ReallocateRuntimePorts replaces only the generated host-port assignments for an already materialized application runtime. Credentials, databases, volumes and other persisted runtime values are left unchanged. This is used when the container runtime proves that a probed loopback port was claimed between allocation and the actual container bind.
func ReconcileMongoDBHA ¶ added in v0.4.21
func ReconcileMongoDBHA(ctx context.Context, runtime mongoDBHAProbeRuntime, m Manifest, files RuntimeFiles) error
ReconcileMongoDBHA bootstraps a managed MongoDB replica set after all members are running. It is idempotent and leaves an already initialized set intact.
func ReconcileRabbitMQCredentials ¶ added in v0.4.21
func ReconcileRabbitMQCredentials(ctx context.Context, runtime rabbitMQCredentialRuntime, m Manifest, files RuntimeFiles) error
func ReconcileReferenceProviderRegistry ¶ added in v0.4.2
func ReconcileReferenceProviderRegistry(m Manifest, additional ...capability.Resource) error
func ReconcileReferenceProviderRegistryAt ¶ added in v0.4.15
func ReconcileReferenceProviderRegistryAt(dataDir string, m Manifest, additional ...capability.Resource) error
func ReconcileRuntimeComponentObservability ¶ added in v0.4.15
func ReconcileRuntimeComponentObservability(m Manifest, component RuntimeComponentObservability) error
func ReconcileSharedBackends ¶ added in v0.4.17
func ReconcileSharedBackends(ctx context.Context, compose bhruntime.RuntimeProvider, issuer serviceaccess.Issuer, dataDir, namespace string, m Manifest, files RuntimeFiles) (bool, error)
func RegisterExternalProvider ¶ added in v0.4.19
func RegisterExternalProvider(reg externalprovider.Registration) error
func RegisterExternalProviderAt ¶ added in v0.4.19
func RegisterExternalProviderAt(dataDir string, reg externalprovider.Registration) error
func RegisteredProviderPlacement ¶ added in v0.4.8
func RegisteredProviderPlacement(m Manifest, provider capability.ProviderKind) (capability.ProviderPlacement, bool, error)
func RegisteredProviderPlacementAt ¶ added in v0.4.15
func RegisteredProviderPlacementAt(dataDir string, m Manifest, provider capability.ProviderKind) (capability.ProviderPlacement, bool, error)
func ReleaseApplicationProviderRegistry ¶ added in v0.4.2
func ReleaseApplicationProviderRegistryAt ¶ added in v0.4.15
func ReleaseSharedBackendApplication ¶ added in v0.4.17
func RemoveConnectivityRule ¶ added in v0.4.8
func RemoveConnectivityRule(rule ConnectivityRule) error
func RemoveConnectivityRuleAt ¶ added in v0.4.15
func RemoveConnectivityRuleAt(dataDir string, rule ConnectivityRule) error
func RemoveExternalProvider ¶ added in v0.4.19
func RemoveExternalProviderAt ¶ added in v0.4.19
func ReplaceObjectStorageCredentials ¶ added in v0.4.21
func ReplaceObjectStorageCredentials(m Manifest, files RuntimeFiles, bucket string, credentials ObjectStorageCredentials) error
ReplaceObjectStorageCredentials replaces one logical bucket credential pair in the managed runtime state. Callers must re-project the object-storage binding after this mutation so workloads observe the new credential atomically.
func RepositoryEnvironmentStateRoot ¶ added in v0.4.13
func RepositoryEnvironmentStateRoot(selection RepositoryEnvironmentSelection) string
RepositoryEnvironmentStateRoot keeps the v0.4.12 state path for the unchanged single-environment compatibility case and isolates every explicit/multi-env deployment below a stable environment scope.
func RequiredSecretNames ¶
func RequiresRuntimeBroker ¶ added in v0.4.8
RequiresRuntimeBroker reports whether the application currently needs the per-application Application Runtime Broker. Keep broker lifecycle decisions centralized here so new authorized runtime capabilities can extend the requirement without duplicating lifecycle conditionals throughout the CLI.
func ResolveCapabilityResources ¶ added in v0.4.1
func ResolveCapabilityResources(contract PortableContract) ([]capability.Resource, error)
func ResolveProviderPlacement ¶ added in v0.4.8
func ResolveProviderPlacement(m Manifest, provider capability.ProviderKind) (capability.ProviderPlacement, error)
ResolveProviderPlacement resolves deployment/operator placement for a provider. Portable application intent never participates in this decision. Defaults are deliberately simple; advanced users can override supported placement fields through the generic provider policy namespace.
func ResolveWorkloadCompose ¶
func ResolveWorkloadComposeSource ¶ added in v0.4.20
func ResourceExists ¶
func ResourceExists(resources []bhruntime.ProjectResource, kind string) bool
func ResourceNamedExists ¶
func ResourceNamedExists(resources []bhruntime.ProjectResource, wanted bhruntime.ProjectResource) bool
func RestorePostgresInstances ¶
func RestorePostgresInstances(ctx context.Context, runtime PostgresBackupRuntime, m Manifest, files RuntimeFiles, backups []PostgresBackup) error
func RestorePostgresInstancesAt ¶ added in v0.4.17
func RestorePostgresInstancesAt(ctx context.Context, runtime PostgresBackupRuntime, m Manifest, files RuntimeFiles, dataDir, namespace string, backups []PostgresBackup) error
func RevokeRuntimeIdentity ¶
func RevokeRuntimeIdentity(m Manifest, files RuntimeFiles) error
func RotateManagedProviderPKI ¶ added in v0.4.21
func RotateManagedProviderPKI(ctx context.Context, runtime bhruntime.RuntimeProvider, issuer serviceaccess.Issuer, m Manifest, files RuntimeFiles, kind ManagedProviderPKIKind, instance string) error
func RotateMongoDBCredential ¶ added in v0.4.21
func RotateMongoDBCredential(ctx context.Context, runtime bhruntime.RuntimeProvider, m Manifest, files RuntimeFiles, instance string) error
func RotateRabbitMQCredential ¶ added in v0.4.21
func RotateRabbitMQCredential(ctx context.Context, runtime bhruntime.RuntimeProvider, m Manifest, files RuntimeFiles, instance string) error
func RotateRuntimeIdentity ¶
func RotateRuntimeIdentity(m Manifest, files RuntimeFiles) error
func RotateValkeyCredential ¶ added in v0.4.21
func RotateValkeyCredential(ctx context.Context, runtime bhruntime.RuntimeProvider, issuer serviceaccess.Issuer, m Manifest, files RuntimeFiles, instance string) error
func RuntimeAuthorizedServices ¶ added in v0.4.8
func RuntimeComposeProjectNameForStore ¶ added in v0.4.16
func RuntimeComposeYAML ¶
func RuntimeComposeYAMLForProject ¶ added in v0.4.16
func RuntimeEnvironment ¶ added in v0.4.15
func RuntimeEnvironment(files RuntimeFiles) (map[string]string, error)
func RuntimeIdentityRevoked ¶
func RuntimeIdentityRevoked(files RuntimeFiles) bool
func RuntimeIdentityRevokedPath ¶
func RuntimeIdentityRevokedPath(files RuntimeFiles) string
func RuntimeIdentityTokenPath ¶
func RuntimeIdentityTokenPath(files RuntimeFiles) string
func RuntimeMTLSHostDir ¶
func RuntimeMTLSHostDir(files RuntimeFiles) string
func RuntimePermissionFor ¶ added in v0.4.8
func RuntimeProjectName ¶
func RuntimeProjectNameForStore ¶ added in v0.4.15
func RuntimeServiceIdentityDir ¶ added in v0.4.8
func RuntimeServiceIdentityDir(files RuntimeFiles) string
func RuntimeServiceIdentityTokenPath ¶ added in v0.4.8
func RuntimeServiceIdentityTokenPath(files RuntimeFiles, service string) string
func SQLInstanceNames ¶ added in v0.4.15
func SecretFileContainerPath ¶
func SecretFileHostDir ¶
func SecretFileHostDir(files RuntimeFiles) string
func SecretFileHostPath ¶
func SecretFileHostPath(files RuntimeFiles, name string) string
func SelectedWorkloadServices ¶ added in v0.4.9
func SelectedWorkloadServicesFromCompose ¶ added in v0.4.20
func SharedBackendNetworkName ¶ added in v0.4.17
func TelemetryProviderForDeployment ¶ added in v0.4.7
func TelemetryProviderForDeployment() capability.Provider
func TracesCollectionEnabled ¶ added in v0.4.10
func UsesSharedPostgreSQL ¶ added in v0.4.17
func UsesSharedValkey ¶ added in v0.4.17
func ValidateApplicationID ¶ added in v0.4.19
func ValidateManagementAuthenticationClass ¶ added in v0.4.21
func ValidateManagementAuthenticationClass(class ManagementAuthenticationClass) error
func ValidateManagementRoleMappings ¶ added in v0.4.21
func ValidateManagementRoleMappings(mappings []ManagementRoleMapping) error
func ValidatePostgresBackupSet ¶
func ValidatePostgresBackupSet(m Manifest, backups []PostgresBackup) error
func ValkeyHAMaster ¶ added in v0.4.21
func ValkeyInstanceNames ¶ added in v0.4.19
func VerifyApplicationManagementUIs ¶ added in v0.4.17
func VerifyApplicationManagementUIs(ctx context.Context, m Manifest, files RuntimeFiles) error
func VerifyExternalProvider ¶ added in v0.4.19
func VerifyExternalProvider(ctx context.Context, id string) (externalprovider.Verification, error)
func VerifyIdentityBinding ¶ added in v0.4.17
func VerifyIdentityBinding(m Manifest, files RuntimeFiles) error
func VerifyManagedProviderInteractions ¶ added in v0.4.15
func VerifyManagedProviderInteractions(ctx context.Context, runtime bhruntime.RuntimeProvider, m Manifest, files RuntimeFiles, sources []observability.SignalSource) error
func VerifyMongoDBHACluster ¶ added in v0.4.21
func VerifyMongoDBHACluster(ctx context.Context, runtime mongoDBHAProbeRuntime, m Manifest, files RuntimeFiles) error
func VerifyMongoDBRuntime ¶ added in v0.4.19
func VerifyMongoDBRuntime(ctx context.Context, m Manifest, files RuntimeFiles) error
func VerifyPostgresProvider ¶ added in v0.4.19
func VerifyPostgresProvider(ctx context.Context, executor BackendProbeExecutor, m Manifest) error
func VerifyPostgresRuntime ¶
func VerifyPostgresRuntime(ctx context.Context, runtime bhruntime.RuntimeProvider, m Manifest, files RuntimeFiles) error
func VerifyRabbitMQHACluster ¶ added in v0.4.21
func VerifyRabbitMQHACluster(ctx context.Context, runtime rabbitMQHAProbeRuntime, m Manifest, files RuntimeFiles) error
func VerifyRabbitMQRuntime ¶ added in v0.4.19
func VerifyRabbitMQRuntime(ctx context.Context, m Manifest, files RuntimeFiles) error
func VerifySharedBackends ¶ added in v0.4.17
func VerifySharedPostgreSQL ¶ added in v0.4.17
func VerifySharedValkey ¶ added in v0.4.17
func VerifyValkeyHACluster ¶ added in v0.4.21
func VerifyValkeyHACluster(ctx context.Context, runtime valkeyHAProbeRuntime, m Manifest, files RuntimeFiles) error
func VerifyValkeyProvider ¶ added in v0.4.19
func VerifyValkeyProvider(ctx context.Context, executor BackendProbeExecutor, m Manifest) error
func VerifyValkeyRuntime ¶
func VerifyValkeyRuntime(ctx context.Context, runtime bhruntime.RuntimeProvider, m Manifest, files RuntimeFiles) error
func VerifyWorkloadServiceBindings ¶ added in v0.4.16
func VerifyWorkloadServiceBindings(m Manifest, files RuntimeFiles) error
func WorkloadComponentNames ¶ added in v0.4.20
func WorkloadProjectName ¶
func WorkloadProjectNameForNamespace ¶ added in v0.4.15
func WorkloadProjectNameForRuntime ¶ added in v0.4.15
func WorkloadProjectNameForRuntime(m Manifest, runtime RuntimeFiles) string
func WorkloadServiceBindingProjectionDir ¶ added in v0.4.17
func WorkloadServiceBindingProjectionDir(files RuntimeFiles) string
Types ¶
type AvailabilityResolution ¶ added in v0.4.21
type AvailabilityResolution struct {
Results []availability.NegotiationResult `json:"results"`
}
AvailabilityResolution is the provider/runtime-neutral requested/resolved availability truth used by CLI, JSON and MCP callers.
func ResolveAvailability ¶ added in v0.4.21
func ResolveAvailability(m Manifest, runtimeProvider string, runtimeSupport availability.Support) (AvailabilityResolution, error)
type BackendProbe ¶ added in v0.4.19
type BackendProbe struct {
Kind BackendProbeKind
Instance string
Database string
}
type BackendProbeExecutor ¶ added in v0.4.19
type BackendProbeExecutor interface {
ProbeBackend(context.Context, BackendProbe) (string, error)
}
type BackendProbeKind ¶ added in v0.4.19
type BackendProbeKind string
const ( BackendProbeSQLSelectOne BackendProbeKind = "sql.select-one" BackendProbeCachePing BackendProbeKind = "cache.ping" BackendProbeDurableKeyValueRW BackendProbeKind = "database.key-value.write-read" )
type BackendTLSLifecycleObservation ¶ added in v0.4.15
type BackendTLSLifecycleObservation struct {
Kind string `json:"kind"`
Instance string `json:"instance"`
Lifecycle serviceaccess.LifecycleObservation `json:"lifecycle"`
}
func InspectBackendTLSLifecycle ¶ added in v0.4.15
func InspectBackendTLSLifecycle(files RuntimeFiles, m Manifest) ([]BackendTLSLifecycleObservation, error)
func InspectSharedBackendTLSLifecycleAt ¶ added in v0.4.17
func InspectSharedBackendTLSLifecycleAt(dataDir, namespace string, m Manifest) ([]BackendTLSLifecycleObservation, error)
type BackupMetadata ¶ added in v0.3.0
type BackupMetadata struct {
Version int `json:"version"`
ApplicationID string `json:"application_id"`
DeploymentID string `json:"deployment_id"`
Application string `json:"application"`
Environment string `json:"environment"`
CreatedAt time.Time `json:"created_at"`
ArchivePath string `json:"archive_path"`
PostgresResources []string `json:"postgres_resources,omitempty"`
IncludesSecrets bool `json:"includes_secrets"`
Recovery []RecoveryContributorMetadata `json:"recovery,omitempty"`
}
func (BackupMetadata) Validate ¶ added in v0.3.0
func (m BackupMetadata) Validate() error
type CapabilityKind ¶ added in v0.4.0
type CapabilityKind = capability.Kind
CapabilityKind and CapabilityRequirement remain aliases in the application package so existing v0.4 callers keep their source-compatible contract while the reusable capability domain moves into the shared core.
const ( CapabilitySQL CapabilityKind = capability.SQL CapabilityKeyValue CapabilityKind = capability.KeyValue CapabilityDurableKeyValue CapabilityKind = capability.DurableKeyValue CapabilityDocumentDatabase CapabilityKind = capability.DocumentDatabase CapabilityExposureHTTP CapabilityKind = capability.ExposureHTTP CapabilityObjectStorageS3 CapabilityKind = capability.ObjectStorageS3 CapabilityTelemetryOTLP CapabilityKind = capability.TelemetryOTLP CapabilityMetrics CapabilityKind = capability.Metrics CapabilityLogs CapabilityKind = capability.Logs CapabilityIdentity CapabilityKind = capability.Identity CapabilityMessagingQueue CapabilityKind = capability.MessagingQueue CapabilityMessagingPubSub CapabilityKind = capability.MessagingPubSub CapabilityMessagingStream CapabilityKind = capability.MessagingStream )
type CapabilityRequirement ¶ added in v0.4.0
type CapabilityRequirement = capability.Requirement
type ConnectivityEndpoint ¶ added in v0.4.8
type ConnectivityEndpoint struct {
Application string `json:"application"`
Environment string `json:"environment"`
Service string `json:"service"`
Port int `json:"port,omitempty"`
}
func (ConnectivityEndpoint) Validate ¶ added in v0.4.8
func (e ConnectivityEndpoint) Validate() error
type ConnectivityRule ¶ added in v0.4.8
type ConnectivityRule struct {
Source ConnectivityEndpoint `json:"source"`
Target ConnectivityEndpoint `json:"target"`
}
func LoadConnectivityRules ¶ added in v0.4.8
func LoadConnectivityRules() ([]ConnectivityRule, error)
func LoadConnectivityRulesAt ¶ added in v0.4.15
func LoadConnectivityRulesAt(dataDir string) ([]ConnectivityRule, error)
func (ConnectivityRule) Validate ¶ added in v0.4.8
func (r ConnectivityRule) Validate() error
type ConsumptionRequirement ¶ added in v0.4.21
type ConsumptionRequirement struct {
Name string `json:"name"`
ApplicationID string `json:"application_id,omitempty"`
Component string `json:"component"`
Interface string `json:"interface"`
Protocol string `json:"protocol,omitempty"`
}
ConsumptionRequirement is portable application intent for one logical application/component interface consumed by this application.
It deliberately contains no runtime address, namespace, container, Pod, node, replica or provider product identity.
func (ConsumptionRequirement) Producer ¶ added in v0.4.21
func (r ConsumptionRequirement) Producer(currentApplicationID string) (LogicalProducerReference, error)
func (ConsumptionRequirement) Validate ¶ added in v0.4.21
func (r ConsumptionRequirement) Validate(currentApplicationID string) error
type EffectiveIdentityPolicy ¶ added in v0.4.17
type EffectiveIdentityPolicy struct {
MFA string `json:"mfa"`
Methods []string `json:"methods,omitempty"`
Passwordless bool `json:"passwordless"`
Sources []string `json:"sources,omitempty"`
}
func ResolveIdentityPolicy ¶ added in v0.4.17
func ResolveIdentityPolicy(m Manifest) (EffectiveIdentityPolicy, error)
type HTTPExposureRequirement ¶ added in v0.4.4
type HTTPExposureRequirement struct {
Name string
Service string
Port int
Protocol string
Visibility string
}
HTTPExposureRequirement is provider-neutral public HTTP exposure intent. Hostname, host port, TLS source paths and reverse-proxy implementation are deployment/provider state and deliberately absent.
type IdentityAuthenticationRequirements ¶ added in v0.4.17
type IdentityDiscovery ¶ added in v0.4.17
type IdentityRequirements ¶ added in v0.4.17
type IdentityRequirements struct {
CallbackPaths []string
LogoutPaths []string
Scopes []string
Claims []string
Authentication IdentityAuthenticationRequirements
}
type LogicalProducerReference ¶ added in v0.4.21
type LogsDeploymentPolicy ¶ added in v0.4.9
type LogsDeploymentPolicy struct {
Enabled bool
Collect map[LogsSourceClass]bool
}
func LogsPolicy ¶ added in v0.4.9
func LogsPolicy(m Manifest) (LogsDeploymentPolicy, error)
type LogsRequirements ¶ added in v0.4.11
type LogsRequirements struct {
Collect []string
}
type LogsSourceClass ¶ added in v0.4.9
type LogsSourceClass string
const ( LogsSourceApplication LogsSourceClass = "application" LogsSourceApplicationProvider LogsSourceClass = "application-provider" LogsSourcePlatformProvider LogsSourceClass = "platform-provider" )
type ManagedProviderPKIKind ¶ added in v0.4.21
type ManagedProviderPKIKind string
const ( ManagedProviderPKIValkey ManagedProviderPKIKind = "valkey" ManagedProviderPKIRabbitMQ ManagedProviderPKIKind = "rabbitmq" ManagedProviderPKIMongoDB ManagedProviderPKIKind = "mongodb" )
type ManagementAuthenticationClass ¶ added in v0.4.21
type ManagementAuthenticationClass string
const ( ManagementAuthNativeOIDC ManagementAuthenticationClass = "native-oidc" ManagementAuthStandardsAdapter ManagementAuthenticationClass = "standards-auth-adapter" ManagementAuthNativeCredential ManagementAuthenticationClass = "native-credential" ManagementAuthUnsupported ManagementAuthenticationClass = "unsupported" )
type ManagementRole ¶ added in v0.4.21
type ManagementRole string
const ( ManagementRoleAdmin ManagementRole = "admin" ManagementRoleEdit ManagementRole = "edit" ManagementRoleView ManagementRole = "view" ManagementRoleAudit ManagementRole = "audit" )
type ManagementRoleMapping ¶ added in v0.4.21
type ManagementRoleMapping struct {
Role ManagementRole `json:"role"`
Level ManagementRoleMappingLevel `json:"level"`
Native string `json:"native,omitempty"`
}
func NativeCredentialRoleMappings ¶ added in v0.4.21
func NativeCredentialRoleMappings(adminNative, userNative string) []ManagementRoleMapping
func OIDCManagementRoleMappings ¶ added in v0.4.21
func OIDCManagementRoleMappings() []ManagementRoleMapping
type ManagementRoleMappingLevel ¶ added in v0.4.21
type ManagementRoleMappingLevel string
const ( ManagementRoleMappingExact ManagementRoleMappingLevel = "exact" ManagementRoleMappingLimited ManagementRoleMappingLevel = "limited" ManagementRoleMappingUnsupported ManagementRoleMappingLevel = "unsupported" )
type ManagementUICheckResult ¶ added in v0.4.17
func VerifyApplicationManagementUIChecks ¶ added in v0.4.17
func VerifyApplicationManagementUIChecks(ctx context.Context, m Manifest, files RuntimeFiles) []ManagementUICheckResult
func VerifySharedManagementUIChecks ¶ added in v0.4.17
func VerifySharedManagementUIChecks(ctx context.Context, dataDir, namespace string, m Manifest) []ManagementUICheckResult
type ManagementUISurface ¶ added in v0.4.17
type ManagementUISurface struct {
Service string `json:"service"`
Purpose ProviderInterfacePurpose `json:"purpose"`
URL string `json:"url"`
Authentication string `json:"authentication"`
AuthenticationClass ManagementAuthenticationClass `json:"authentication_class"`
RoleMappings []ManagementRoleMapping `json:"role_mappings,omitempty"`
}
func ApplicationManagementUISurfaces ¶ added in v0.4.17
func ApplicationManagementUISurfaces(m Manifest, files RuntimeFiles) ([]ManagementUISurface, error)
type Manifest ¶
type Manifest struct {
Version int
ApplicationID string
Name string
Environment string
Services Services
Secrets SecretRequirements
Workload WorkloadConfig
Exposures []HTTPExposureRequirement
Telemetry TelemetryRequirements
Metrics MetricsRequirements
Logs LogsRequirements
Runtime RuntimeRequirements
Identity IdentityRequirements
HA bool
Availability map[string]availability.Override
Consumes []ConsumptionRequirement
}
Manifest is the declarative application backend request understood by BaseHarbor.
func LoadManifestFile ¶
func ParseYAML ¶
ParseYAML parses the intentionally small v1 manifest grammar without adding a runtime dependency.
func WithAvailabilityOverride ¶ added in v0.4.21
func WithCacheInstances ¶ added in v0.4.15
func WithDocumentDatabaseInstances ¶ added in v0.4.19
func WithGeneratedSecret ¶
func WithHTTPExposure ¶ added in v0.4.4
func WithIdentity ¶ added in v0.4.17
func WithIdentityAuthentication ¶ added in v0.4.17
func WithIdentityCallbackPath ¶ added in v0.4.17
func WithIdentityLogoutPath ¶ added in v0.4.17
func WithKeyValueInstances ¶ added in v0.4.19
func WithLogsCollection ¶ added in v0.4.11
func WithMessagingPubSubInstances ¶ added in v0.4.19
func WithMessagingQueueInstances ¶ added in v0.4.19
func WithMessagingStreamInstances ¶ added in v0.4.19
func WithMetricsSource ¶ added in v0.4.8
func WithOTLPTelemetry ¶ added in v0.4.7
func WithObjectStorageBuckets ¶ added in v0.4.6
func WithOptionalGeneratedSecret ¶ added in v0.4.15
func WithOptionalSecrets ¶ added in v0.4.15
func WithRequiredSecrets ¶
func WithRuntimePermission ¶ added in v0.4.8
func WithSQLInstances ¶ added in v0.4.15
func WithWorkloadComponents ¶ added in v0.4.20
type MetricsDeploymentPolicy ¶ added in v0.4.8
type MetricsDeploymentPolicy struct {
Enabled bool
Collect map[MetricsSourceClass]bool
}
func MetricsPolicy ¶ added in v0.4.8
func MetricsPolicy(m Manifest) (MetricsDeploymentPolicy, error)
MetricsPolicy is deployment/operator state, never portable application intent. Defaults keep the user-facing path simple: when metrics collection is enabled, BaseHarbor also observes managed providers that explicitly advertise safe OpenMetrics endpoints. Policy can narrow the collected source classes.
type MetricsRequirements ¶ added in v0.4.8
type MetricsRequirements struct {
Sources []MetricsSourceRequirement
}
type MetricsSourceClass ¶ added in v0.4.8
type MetricsSourceClass string
const ( MetricsSourceApplication MetricsSourceClass = "application" MetricsSourceApplicationProvider MetricsSourceClass = "application-provider" MetricsSourcePlatformProvider MetricsSourceClass = "platform-provider" )
type MetricsSourceRequirement ¶ added in v0.4.8
type OTLPRequirement ¶ added in v0.4.7
type OTLPRequirement struct {
Signals []string
}
type ObjectStorageCredentials ¶ added in v0.4.6
func LoadObjectStorageCredentials ¶ added in v0.4.6
func LoadObjectStorageCredentials(files RuntimeFiles, bucket string) (ObjectStorageCredentials, error)
type Plan ¶
type PortableContract ¶ added in v0.4.0
type PortableContract struct {
Application string
Capabilities []CapabilityRequirement
Secrets SecretContract
Exposures []HTTPExposureRequirement
Metrics []MetricsSourceRequirement
Logs []string
Identity *IdentityRequirements
}
PortableContract is the provider-neutral application requirement view used as the seam between manifest compatibility and runtime/capability providers.
Deployment context such as environment, Compose paths, host ports, TLS source directories and provider object names must not be added here. Those belong to deployment state or provider-specific configuration.
func PortableContractFromManifest ¶ added in v0.4.0
func PortableContractFromManifest(m Manifest) (PortableContract, error)
PortableContractFromManifest translates the current manifest v1 compatibility surface into provider-neutral requirements without changing manifest behavior.
type PostgresBackup ¶
func DumpPostgresInstances ¶
func DumpPostgresInstances(ctx context.Context, runtime PostgresBackupRuntime, m Manifest, files RuntimeFiles) ([]PostgresBackup, error)
func DumpPostgresInstancesAt ¶ added in v0.4.17
func DumpPostgresInstancesAt(ctx context.Context, runtime PostgresBackupRuntime, m Manifest, files RuntimeFiles, dataDir, namespace string) ([]PostgresBackup, error)
type PostgresBackupRuntime ¶
type ProviderInterfacePurpose ¶ added in v0.4.17
type ProviderInterfacePurpose string
const ( ProviderInterfaceApplication ProviderInterfacePurpose = "application" ProviderInterfaceUserFacing ProviderInterfacePurpose = "user-facing" ProviderInterfaceAdministration ProviderInterfacePurpose = "administration" ProviderInterfaceManagement ProviderInterfacePurpose = "management" ProviderInterfaceObservability ProviderInterfacePurpose = "observability" )
type RecoveryContributorMetadata ¶ added in v0.4.16
type RecoveryContributorMetadata struct {
StateClass string `json:"state_class"`
LogicalResource string `json:"logical_resource,omitempty"`
Ownership string `json:"ownership"`
Support string `json:"support"`
Selected bool `json:"selected"`
Durable bool `json:"durable,omitempty"`
ExplicitlyExcluded bool `json:"explicitly_excluded,omitempty"`
Verified bool `json:"verified,omitempty"`
Reason string `json:"reason,omitempty"`
}
type RecoveryMetadata ¶ added in v0.3.0
type RecoveryMetadata struct {
Version int `json:"version"`
ApplicationID string `json:"application_id"`
DeploymentID string `json:"deployment_id"`
Application string `json:"application"`
Environment string `json:"environment"`
RestoredAt time.Time `json:"restored_at"`
BackupCreatedAt time.Time `json:"backup_created_at"`
ArchivePath string `json:"archive_path"`
Recovery []RecoveryContributorMetadata `json:"recovery,omitempty"`
}
func (RecoveryMetadata) Validate ¶ added in v0.3.0
func (m RecoveryMetadata) Validate() error
type RepositoryEnvironmentSelection ¶ added in v0.4.13
type RepositoryEnvironmentSelection struct {
RepositoryRoot string
ManifestPath string
Manifest Manifest
Environment string
EnvironmentSpecific bool
LegacyState bool
}
RepositoryEnvironmentSelection is the deterministic repository/application source selected for one deployment environment. Environment-specific manifests are complete application contracts; they are never overlays.
func ResolveRepositoryEnvironment ¶ added in v0.4.13
func ResolveRepositoryEnvironment(start, requested string) (RepositoryEnvironmentSelection, error)
ResolveRepositoryEnvironment resolves the repository root, complete manifest and deployment environment as one operation.
A root baseharbor.yaml remains the compatibility path for simple repositories. An explicit environment first prefers envs/<environment>/baseharbor.yaml. If that file does not exist, the root manifest is reused as complete intent and only its deployment context is overridden. This preserves the established -e/--environment behavior without mutating the repository contract.
type ResolvedConsumption ¶ added in v0.4.21
type ResolvedConsumption struct {
Name string `json:"name"`
Producer LogicalProducerReference `json:"producer"`
BindingID string `json:"binding_id"`
Protocol string `json:"protocol,omitempty"`
Endpoint string `json:"endpoint,omitempty"`
Resolved bool `json:"resolved"`
Diagnostic string `json:"diagnostic,omitempty"`
}
func ResolveConsumption ¶ added in v0.4.21
func ResolveConsumption(currentApplicationID string, requirement ConsumptionRequirement, endpoint string) (ResolvedConsumption, error)
ResolveConsumption applies runtime/provider realization without changing the logical producer reference. Endpoint is realization state, never portable application intent.
type RuntimeBackendProbeExecutor ¶ added in v0.4.19
type RuntimeBackendProbeExecutor struct {
// contains filtered or unexported fields
}
func NewRuntimeBackendProbeExecutor ¶ added in v0.4.19
func NewRuntimeBackendProbeExecutor(runtime bhruntime.RuntimeProvider, files RuntimeFiles) RuntimeBackendProbeExecutor
func (RuntimeBackendProbeExecutor) ProbeBackend ¶ added in v0.4.19
func (e RuntimeBackendProbeExecutor) ProbeBackend(ctx context.Context, probe BackendProbe) (string, error)
type RuntimeComponentObservability ¶ added in v0.4.15
type RuntimeComponentObservability struct {
ID string
Provider capability.ProviderKind
Class observability.SourceClass
Scope capability.ProviderScope
OwnerApplication string
MetricsNetwork string
MetricsTarget string
MetricsPath string
MetricsSecurity observability.Security
LogsTarget string
TracesTarget string
TracesSecurity observability.Security
}
type RuntimeContract ¶
type RuntimeContract struct {
Env string
BindingsDir string
WorkloadBindingsDir string
Metadata string
}
func EnsureRuntimeContract ¶
func EnsureRuntimeContract(m Manifest, files RuntimeFiles) (RuntimeContract, error)
type RuntimeFiles ¶
type RuntimeFiles struct {
Dir string
Compose string
Env string
ApplicationEnv string
Bindings string
Project string
ResourceProject string
Namespace string
}
func EnsurePostgresRuntime ¶
func EnsurePostgresRuntime(ctx context.Context, issuer serviceaccess.Issuer, store Store, m Manifest) (RuntimeFiles, error)
EnsurePostgresRuntime is kept for callers from the first runtime milestone.
func EnsureRuntime ¶
func EnsureRuntime(ctx context.Context, issuer serviceaccess.Issuer, store Store, m Manifest) (RuntimeFiles, error)
func ExistingRuntimeFiles ¶
func ExistingRuntimeFiles(store Store, m Manifest) (RuntimeFiles, error)
func RuntimeFilesFor ¶ added in v0.4.4
func RuntimeFilesFor(store Store, m Manifest) RuntimeFiles
type RuntimeOTLPBinding ¶ added in v0.4.15
type RuntimeOTLPBinding struct {
Provider capability.ProviderKind
ContainerEndpoint string
CAFile string
ClientCertFile string
ClientKeyFile string
Headers string
}
func ExistingRuntimeOTLPBinding ¶ added in v0.4.15
func ExistingRuntimeOTLPBinding(m Manifest, files RuntimeFiles) (RuntimeOTLPBinding, bool, error)
type RuntimePermission ¶ added in v0.4.8
type RuntimeRequirements ¶ added in v0.4.8
type RuntimeRequirements struct {
Permissions []RuntimePermission
}
type SecretContract ¶ added in v0.4.0
type SecretContract struct {
Managed bool
Required []SecretRequirement
}
SecretContract describes secret intent without selecting a concrete secret backend or delivery mechanism. Required values remain names/generation intent only; provider credentials and provider object identifiers never belong here.
type SecretGeneration ¶
type SecretRequirement ¶
type SecretRequirement struct {
Name string
Generate *SecretGeneration
}
func GeneratedSecretRequirements ¶
func GeneratedSecretRequirements(m Manifest) []SecretRequirement
func SecretRequirementByName ¶
func SecretRequirementByName(m Manifest, name string) (SecretRequirement, bool)
type SecretRequirements ¶
type SecretRequirements struct {
Required []SecretRequirement
Optional []SecretRequirement
}
SecretRequirements declares application-owned secret requirements. Values never belong in the manifest. Generate only expresses explicit intent for BaseHarbor to create a missing value directly in the managed secret backend.
type ServiceBinding ¶ added in v0.3.0
type ServiceBinding struct {
Kind string
Instance string
Host string
Port string
Database string
Username string
Password string
URI string
CertificatesPath string
}
ServiceBinding is the provider-neutral information needed by developer access actions. Callers should prefer these fields over runtime/container names so a later provider can satisfy the same action model.
func ResolveServiceBinding ¶ added in v0.3.0
func ResolveServiceBinding(files RuntimeFiles, kind, instance string) (ServiceBinding, error)
ResolveServiceBinding loads an already-materialized owner-only service binding. It never creates or rotates credentials.
type ServiceInstance ¶
type ServiceInstance struct{}
ServiceInstance is the stable logical identity of one requested backend service. The empty v1 shape is intentional: topology remains a BaseHarbor implementation detail and future intent such as availability can evolve here.
type Services ¶
type Services struct {
SQL bool
Cache bool
KeyValue bool
DocumentDatabase bool
MessagingQueue bool
MessagingPubSub bool
MessagingStream bool
Secrets bool
ObjectStorage bool
Identity bool
SQLManagementUI bool
CacheManagementUI bool
KeyValueManagementUI bool
DocumentDatabaseManagementUI bool
MessagingManagementUI bool
SecretsManagementUI bool
ObjectStorageManagementUI bool
IdentityManagementUI bool
ObservabilityManagementUI bool
SQLInstances map[string]ServiceInstance
CacheInstances map[string]ServiceInstance
KeyValueInstances map[string]ServiceInstance
DocumentDatabaseInstances map[string]ServiceInstance
MessagingQueueInstances map[string]ServiceInstance
MessagingPubSubInstances map[string]ServiceInstance
MessagingStreamInstances map[string]ServiceInstance
ObjectStorageBuckets map[string]ServiceInstance
}
type SharedBackendFiles ¶ added in v0.4.17
type SharedBackendFiles struct {
}
func SharedBackendFilesAt ¶ added in v0.4.17
func SharedBackendFilesAt(dataDir, namespace, environment string) SharedBackendFiles
type SharedPostgresResourceObservation ¶ added in v0.4.17
type SharedPostgresResourceObservation struct {
}
func SharedPostgresResourcesAt ¶ added in v0.4.17
func SharedPostgresResourcesAt(dataDir, namespace string, m Manifest) ([]SharedPostgresResourceObservation, error)
type StatusCheck ¶ added in v0.4.11
type StatusCheck struct {
Name string `json:"name"`
OK bool `json:"ok"`
State string `json:"state,omitempty"`
Detail string `json:"detail,omitempty"`
}
StatusCheck is a secret-safe readiness observation shared by CLI and future machine-oriented control surfaces.
type StatusResult ¶ added in v0.4.11
type StatusResult struct {
ContractVersion string `json:"contract_version"`
Target string `json:"target"`
Application string `json:"application"`
Environment string `json:"environment"`
Manifest string `json:"manifest,omitempty"`
Project string `json:"project"`
State string `json:"state"`
Ready bool `json:"ready"`
Checks []StatusCheck `json:"checks"`
}
StatusResult is the shared application readiness model. It intentionally contains operational state only and never credential or secret values.
func (*StatusResult) AddCheck ¶ added in v0.4.11
func (r *StatusResult) AddCheck(name string, ok bool, detail string)
AddCheck appends one readiness observation and folds failures into Ready.
func (*StatusResult) AddObservation ¶ added in v0.4.17
func (r *StatusResult) AddObservation(name, state, detail string)
func (StatusResult) HasFailures ¶ added in v0.4.17
func (r StatusResult) HasFailures() bool
func (StatusResult) HasUnverified ¶ added in v0.4.17
func (r StatusResult) HasUnverified() bool
type Store ¶
func DefaultStore ¶
func DefaultStore() Store
func (Store) LastBackup ¶ added in v0.3.0
func (s Store) LastBackup(applicationName string) (BackupMetadata, error)
func (Store) LastRecovery ¶ added in v0.3.0
func (s Store) LastRecovery(applicationName string) (RecoveryMetadata, error)
func (Store) LastUpdate ¶ added in v0.3.0
func (s Store) LastUpdate(applicationName string) (UpdateMetadata, error)
func (Store) RecordLastBackup ¶ added in v0.3.0
func (s Store) RecordLastBackup(metadata BackupMetadata) error
func (Store) RecordLastRecovery ¶ added in v0.3.0
func (s Store) RecordLastRecovery(metadata RecoveryMetadata) error
func (Store) RecordLastUpdate ¶ added in v0.3.0
func (s Store) RecordLastUpdate(metadata UpdateMetadata) error
type TelemetryRequirements ¶ added in v0.4.7
type TelemetryRequirements struct {
OTLP *OTLPRequirement
}
type TracesDeploymentPolicy ¶ added in v0.4.15
type TracesDeploymentPolicy struct {
Enabled bool
Collect map[TracesSourceClass]bool
}
func TracesPolicy ¶ added in v0.4.15
func TracesPolicy(m Manifest) (TracesDeploymentPolicy, error)
type TracesSourceClass ¶ added in v0.4.15
type TracesSourceClass string
const ( TracesSourceApplication TracesSourceClass = "application" TracesSourceApplicationProvider TracesSourceClass = "application-provider" TracesSourcePlatformProvider TracesSourceClass = "platform-provider" )
type UpdateMetadata ¶ added in v0.3.0
type UpdateMetadata struct {
Version int `json:"version"`
Application string `json:"application"`
Environment string `json:"environment"`
UpdatedAt time.Time `json:"updated_at"`
Branch string `json:"branch"`
Upstream string `json:"upstream"`
FromRevision string `json:"from_revision"`
ToRevision string `json:"to_revision"`
Result string `json:"result"`
BackupPath string `json:"backup_path,omitempty"`
BackupCreatedAt time.Time `json:"backup_created_at,omitempty"`
}
func (UpdateMetadata) Validate ¶ added in v0.3.0
func (m UpdateMetadata) Validate() error
type WorkloadBindingPlan ¶
type WorkloadBindingPlan struct {
RuntimeIdentityServices []string
FileSecretsByService map[string][]string
}
func (WorkloadBindingPlan) Empty ¶
func (p WorkloadBindingPlan) Empty() bool
type WorkloadConfig ¶
type WorkloadConfig struct {
Components []string
}
WorkloadConfig carries only portable logical workload-component identity. Source-format metadata such as Compose/Kubernetes/Quadlet paths belongs to repository authoring metadata and never to portable application intent.
type WorkloadFiles ¶
type WorkloadFiles struct {
RepositoryRoot string
Compose string
Override string
Services []string
Project string
Partial bool
}
func MaterializeWorkload ¶
func MaterializeWorkload(repositoryRoot string, m Manifest, runtime RuntimeFiles) (WorkloadFiles, bool, error)
func MaterializeWorkloadFromCompose ¶ added in v0.4.20
func MaterializeWorkloadFromCompose(repositoryRoot, sourcePath string, m Manifest, runtime RuntimeFiles) (WorkloadFiles, bool, error)
type WorkloadSecurityDecision ¶ added in v0.4.9
type WorkloadSecurityDecision string
const ( WorkloadSecurityAllow WorkloadSecurityDecision = "allow" WorkloadSecurityWarn WorkloadSecurityDecision = "warn" WorkloadSecurityDeny WorkloadSecurityDecision = "deny" )
type WorkloadSecurityFinding ¶ added in v0.4.9
type WorkloadSecurityPolicy ¶ added in v0.4.13
type WorkloadSecurityPolicy struct {
Mode string `json:"mode"`
AllowedOverrides []string `json:"allowed_overrides,omitempty"`
}
func ResolveWorkloadSecurityPolicy ¶ added in v0.4.13
func ResolveWorkloadSecurityPolicy(m Manifest) (WorkloadSecurityPolicy, error)
type WorkloadSecurityReport ¶ added in v0.4.9
type WorkloadSecurityReport struct {
Mode string `json:"mode"`
Findings []WorkloadSecurityFinding `json:"findings"`
}
func AnalyzeComposeSecuritySource ¶ added in v0.4.17
func AnalyzeComposeSecuritySource(m Manifest, source []byte) (WorkloadSecurityReport, error)
func AnalyzeRenderedComposeSecurity ¶ added in v0.4.9
func AnalyzeRenderedComposeSecurity(m Manifest, rendered []byte) (WorkloadSecurityReport, error)
func (WorkloadSecurityReport) Denied ¶ added in v0.4.9
func (r WorkloadSecurityReport) Denied() bool
func (WorkloadSecurityReport) Error ¶ added in v0.4.9
func (r WorkloadSecurityReport) Error() error
Source Files
¶
- access.go
- availability_resolution.go
- availability_runtime.go
- backend_tls.go
- backup_metadata.go
- capability_model.go
- connectivity.go
- consumption.go
- contract.go
- environment.go
- external_provider_registry.go
- generated_secrets.go
- identity.go
- identity_binding.go
- identity_network.go
- identity_policy.go
- logs_policy.go
- management_access.go
- management_ui.go
- manifest.go
- manifest_parse.go
- manifest_render.go
- manifest_validation.go
- metrics_policy.go
- mongodb_credential_rotation.go
- mongodb_credential_rotation_helpers.go
- mongodb_ha.go
- mongodb_ha_runtime.go
- mongodb_runtime.go
- mongodb_verify.go
- network.go
- object_storage_binding.go
- object_storage_credential_rotation.go
- object_storage_runtime.go
- plan.go
- postgres_backup.go
- postgres_ha.go
- provider_pki_rotation.go
- provider_pki_rotation_runtime.go
- provider_placement.go
- provider_registry.go
- rabbitmq_credential_rotation.go
- rabbitmq_credential_rotation_helpers.go
- rabbitmq_credentials.go
- rabbitmq_ha.go
- rabbitmq_verify.go
- recovery_metadata.go
- repository_manifest.go
- runtime_component_observability.go
- runtime_contract.go
- runtime_contract_urls.go
- runtime_identity.go
- runtime_identity_workload.go
- runtime_inspect.go
- runtime_lifecycle.go
- runtime_observability.go
- runtime_ports.go
- runtime_postgres.go
- runtime_shape.go
- runtime_telemetry.go
- secure_binding.go
- shared_backends.go
- shared_backends_management.go
- shared_backends_runtime.go
- shared_backends_state.go
- status_result.go
- store.go
- telemetry_binding.go
- traces_policy.go
- update_metadata.go
- valkey_credential_rotation.go
- valkey_credential_rotation_helpers.go
- valkey_credential_rotation_runtime.go
- valkey_ha.go
- valkey_ha_verify.go
- valkey_stable_verify.go
- workload.go
- workload_security.go