pkg

module
v0.14.0 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2025 License: Apache-2.0

README

AlaudaDevOps common packages 📦

fork from katanomi/pkg, and use branch v2 as main

All shared common packages and code across katanomi repos

  • apis: common types and functions for type definitions
  • apis/meta: objects, definitions and functions shared across projects (versioned)
  • apis/validation: common validation methods
  • client: client related functions
  • controllers: controller methods and objects
  • errors: common error functions
  • examples: examples of how to utilize this repo methods/objects
  • hack: basic repo hacking files (not a package)
  • logging: logging related
  • maps: package to manipulate maps with sortingand other methods.
  • manager: controller-runtime manager methods
  • multicluster: shared multicluster interfaces and implementations for client, etc.
  • names: name generation releated methods (k8s.io/apiserver inspired)
  • namespace: namespace releated methods
  • parallel: parallel task execution implementation
  • plugin: plugin system files and subpackages
  • restclient: RESTful client methods
  • scheme: scheme related methods
  • sharedmain: common main functions to init components
  • testing: automated test related methods
  • testing/framework: automated test framework for e2e and integration testing
  • user: user matching releated functions
  • webhook: custom webhook methods to extend current controller-runtime webhooks

TODO

  • [ ]: implement custom validation webhook methods
  • [ ]: add more unit tests
  • [ ]: add requirements to testing/framework to automatically enable/disable tests based on setup

Directories

Path Synopsis
apis
meta/v1alpha1
Package v1alpha1 contains API Schema definitions for the types v1alpha1 API group this group is a duck type only package that hosts common objects and interfaces in alauda devops very similar to knative.dev/pkg/apis/duck/v1 or k8s.io/apimachinery/pkg/apis/meta/v1 +kubebuilder:object:generate=true +k8s:deepcopy-gen=package +groupName=meta.alauda.io
Package v1alpha1 contains API Schema definitions for the types v1alpha1 API group this group is a duck type only package that hosts common objects and interfaces in alauda devops very similar to knative.dev/pkg/apis/duck/v1 or k8s.io/apimachinery/pkg/apis/meta/v1 +kubebuilder:object:generate=true +k8s:deepcopy-gen=package +groupName=meta.alauda.io
validation
Package validation contains useful validation functions
Package validation contains useful validation functions
Package client contains functions to add and retrieve client from context
Package client contains functions to add and retrieve client from context
command
args
Package args stores useful methods to parse and extract data from extra arguments given to cli commands
Package args stores useful methods to parse and extract data from extra arguments given to cli commands
exec
Package exec contains an interface for executing commands, along with helpers TODO(bentheelder): add standardized timeout functionality & a default timeout so that commands cannot hang indefinitely (!)
Package exec contains an interface for executing commands, along with helpers TODO(bentheelder): add standardized timeout functionality & a default timeout so that commands cannot hang indefinitely (!)
io
Package io some io operation functions
Package io some io operation functions
logger
Package logger logger used by cli
Package logger logger used by cli
Package common useful functionality for encoding and decoding objects
Package common useful functionality for encoding and decoding objects
Package config stores katanomi configuration manager which watch configmap and work immediately if configmap changed
Package config stores katanomi configuration manager which watch configmap and work immediately if configmap changed
fake
Package fake provide fake manager for config
Package fake provide fake manager for config
Package configmap contains configMap related functions.
Package configmap contains configMap related functions.
Package controllers implements the lazy loader logic for Katanomi.
Package controllers implements the lazy loader logic for Katanomi.
Package encoding provides some useful functions for encoding and decoding objects
Package encoding provides some useful functions for encoding and decoding objects
Package errors provides a set of error functions
Package errors provides a set of error functions
examples
sample-controller/apis/test/v1alpha1
Package v1alpha1 contains API Schema definitions for the core v1alpha1 API group +kubebuilder:object:generate=true +groupName=test.alauda.io
Package v1alpha1 contains API Schema definitions for the core v1alpha1 API group +kubebuilder:object:generate=true +groupName=test.alauda.io
Package fieldindexer provides types and functions about fieldindexer
Package fieldindexer provides types and functions about fieldindexer
Package finalizer provides a set of functions to manage finalizers
Package finalizer provides a set of functions to manage finalizers
Package hash contains useful functionality for hashing.
Package hash contains useful functionality for hashing.
Package logging contains useful functionality
Package logging contains useful functionality
Package manager contains functions to add and retrieve manager from context
Package manager contains functions to add and retrieve manager from context
Package maps contains methods to operate maps of all kinds
Package maps contains methods to operate maps of all kinds
Package names contains useful functionality for generating names
Package names contains useful functionality for generating names
Package namespace contains functions to add and retrieve namespace from context
Package namespace contains functions to add and retrieve namespace from context
Package networkutils contains functions to help with network operations
Package networkutils contains functions to help with network operations
Package parallel used to execute tasks in parallel
Package parallel used to execute tasks in parallel
Package pointer provides helper functions for generating pointers
Package pointer provides helper functions for generating pointers
Package record has all client logic for recording and reporting
Package record has all client logic for recording and reporting
Package references contains methods to manage owner references
Package references contains methods to manage owner references
Package regex provides helper functions for regular expression search.
Package regex provides helper functions for regular expression search.
Package restclient contains functions to add and retrieve rest client from context
Package restclient contains functions to add and retrieve rest client from context
Package route contains useful functionality for the package route
Package route contains useful functionality for the package route
Package scheme contains functions to add and retrieve scheme from context
Package scheme contains functions to add and retrieve scheme from context
Package sharedmain contains useful functionality for main
Package sharedmain contains useful functionality for main
Package ssl contains operations related to SSL certificates.
Package ssl contains operations related to SSL certificates.
assertions
Package assertions contains all the assertions that can be used in tests for general testing.
Package assertions contains all the assertions that can be used in tests for general testing.
mock
Package mock contains useful functionality for testing
Package mock contains useful functionality for testing
mock/github.com/AlaudaDevops/pkg
Package sharedmain is a generated GoMock package.
Package sharedmain is a generated GoMock package.
mock/github.com/AlaudaDevops/pkg/apis/meta/v1alpha1
Package apis is a generated GoMock package.
Package apis is a generated GoMock package.
mock/github.com/AlaudaDevops/pkg/multicluster
Package multicluster is a generated GoMock package.
Package multicluster is a generated GoMock package.
mock/github.com/AlaudaDevops/pkg/warnings/condition
Package warnings is a generated GoMock package.
Package warnings is a generated GoMock package.
mock/github.com/minio/minio-go
Package pkg is a generated GoMock package.
Package pkg is a generated GoMock package.
mock/k8s.io/cli-runtime/pkg/genericclioptions
Package genericclioptions is a generated GoMock package.
Package genericclioptions is a generated GoMock package.
mock/k8s.io/client-go/kubernetes
Package kubernetes is a generated GoMock package.
Package kubernetes is a generated GoMock package.
mock/knative.dev/pkg/apis
Package apis is a generated GoMock package.
Package apis is a generated GoMock package.
mock/sigs.k8s.io/controller-runtime/pkg/client
Package client is a generated GoMock package.
Package client is a generated GoMock package.
mock/sigs.k8s.io/controller-runtime/pkg/manager
Package manager is a generated GoMock package.
Package manager is a generated GoMock package.
Package tracing contains tracing related functions.
Package tracing contains tracing related functions.
Package url contains general processing functions for some urls.
Package url contains general processing functions for some urls.
Package warnings contains useful functions to manage warnings in the status
Package warnings contains useful functions to manage warnings in the status
condition
Package condition provides a set of utilities for managing warning conditions and emitting warning events
Package condition provides a set of utilities for managing warning conditions and emitting warning events
Package watcher stores interface DefaultingWatcherWithOnChange
Package watcher stores interface DefaultingWatcherWithOnChange
webhook
admission
Package admission contains functions to add and retrieve admission request from context
Package admission contains functions to add and retrieve admission request from context
Package workers for job worker managed by controller-runtime manager
Package workers for job worker managed by controller-runtime manager

Jump to

Keyboard shortcuts

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