Distributing Components #7
PascalSenn
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Distributing Components
In Confix, we have two primary methods to distribute components: Direct Shipping and Repositories.
Discovery: This is the preferred method for component distribution. Here, you bundle the components directly with your package. This approach facilitates seamless integration of the components with your project, eliminating the need for additional retrieval or loading operations.
Repositories: Alternatively, you can utilize repositories to load components from various storage providers. This method offers flexibility and can be particularly useful in scenarios where the components are stored externally or need to be versioned independently of the primary project.
For efficient component management, we recommend configuring the component discovery and repository settings globally in the
.confixrc
file or locally in theconfix.repository
file for repository-specific configurations. While it's possible to make project-specific adjustments in the.confix.project
file, we suggest this approach only when absolutely necessary. Sharing configurations across projects helps maintain consistency, reduces duplication, and allows for easier maintenance.Component Discovery
You can specify how your projects discover the components used in your configuration by defining the
componentProviders
. Component providers are responsible for loading the components used by your project whenever you 'reload' the project. As you bundle the code/binaries of the component together with the component on build time, you guarantee that you configuration always matches the used version of the component.There are several types of component providers available, such as
dotnet-package
, which scans the project's assemblies for embedded resources describing a Confix component, andnode-modules
, which checks the node-modules used by the project for Confix components.Component Repositories
Component repositories come into play when you're unable to bundle a schema with your code or when components need separate versioning (for instance, in build pipeline configuration). These repositories may exist in various locations such as Azure Blob storage (
blob
), Helm repositories (helm
), Git repositories (git
), or public JSON schemas (json-schema
).Beta Was this translation helpful? Give feedback.
All reactions