Documentation
¶
Overview ¶
Package pagesproject implements the L2 Controller for PagesProject CRD. It registers project configurations to the Core Service for sync.
Index ¶
Constants ¶
const ( // FinalizerName is the finalizer for PagesProject resources. FinalizerName = "pagesproject.networking.cloudflare-operator.io/finalizer" // ManagedByLabel identifies resources managed by PagesProject controller. ManagedByLabel = "networking.cloudflare-operator.io/managed-by" // ManagedByNameLabel stores the PagesProject name that manages this deployment. ManagedByNameLabel = "networking.cloudflare-operator.io/managed-by-name" // ManagedByUIDLabel stores the PagesProject UID to prevent conflicts after deletion. ManagedByUIDLabel = "networking.cloudflare-operator.io/managed-by-uid" // VersionLabel stores the version name from ProjectVersion. VersionLabel = "networking.cloudflare-operator.io/version" // ManagedAnnotation marks a resource as managed by PagesProject. ManagedAnnotation = "networking.cloudflare-operator.io/managed" // ManagedByValue is the value for ManagedByLabel. ManagedByValue = "pagesproject" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PagesProjectReconciler ¶
type PagesProjectReconciler struct {
client.Client
Scheme *runtime.Scheme
Recorder record.EventRecorder
// contains filtered or unexported fields
}
PagesProjectReconciler reconciles a PagesProject object
func (*PagesProjectReconciler) SetupWithManager ¶
func (r *PagesProjectReconciler) SetupWithManager(mgr ctrl.Manager) error
type ResolvedVersions ¶ added in v0.31.0
type ResolvedVersions struct {
Versions []networkingv1alpha2.ProjectVersion
ProductionTarget string
}
ResolvedVersions contains the resolved versions and production target.
type TemplateData ¶ added in v0.31.0
type TemplateData struct {
Version string
}
TemplateData contains data for template execution.
type VersionManager ¶ added in v0.29.0
type VersionManager struct {
client.Client
Scheme *runtime.Scheme
// contains filtered or unexported fields
}
VersionManager manages declarative versions for PagesProject.
func NewVersionManager ¶ added in v0.29.0
func NewVersionManager(k8sClient client.Client, scheme *runtime.Scheme, log logr.Logger) *VersionManager
NewVersionManager creates a new VersionManager.
func (*VersionManager) HasVersions ¶ added in v0.31.0
func (*VersionManager) HasVersions(project *networkingv1alpha2.PagesProject) bool
HasVersions checks if the project has any versions configured.
func (*VersionManager) Reconcile ¶ added in v0.29.0
func (vm *VersionManager) Reconcile(ctx context.Context, project *networkingv1alpha2.PagesProject) error
Reconcile synchronizes the desired versions with actual PagesDeployment resources.
func (*VersionManager) ResolveVersions ¶ added in v0.31.0
func (vm *VersionManager) ResolveVersions(project *networkingv1alpha2.PagesProject) (*ResolvedVersions, error)
ResolveVersions resolves versions based on the version management configuration. This supports three modes: targetVersion, declarativeVersions, and fullVersions. For backward compatibility, it also supports the legacy spec.versions field.