@veecode-platform/plugin-veecode-platform-common
TypeScript icon, indicating that this package has built-in type declarations

0.3.19 • Public • Published

VeeCode Platform Common Plugin

The Veecode Platform Common plugin is a backend plugin that extends the backstage catalog, adding new features to the application's standard behavior.

Such as new kinds, new schemas and a new apiversion.

Kinds:

  • Environment
  • Cluster
  • Database
  • Vault
  • FinOps

ApiVersion

  • veecode.backstage.io/v1alpha1

Get started

cd packages/backend
yarn add @veecode-platform/plugin-veecode-platform-common

Now, in the file packages > backend > src > plugins > catalog.ts:

...
+ import { ClusterEntitiesProcessor, DatabaseEntitiesProcessor, EnvironmentEntitiesProcessor, VaultEntitiesProcessor } from '@veecode-platform/plugin-veecode-platform-common';
...

export default async function createPlugin(
  env: PluginEnvironment,
): Promise<Router> {
  const builder = await CatalogBuilder.create(env);
  ... 
  
+  builder.addProcessor( new ClusterEntitiesProcessor());
+  builder.addProcessor( new EnvironmentEntitiesProcessor());
+  builder.addProcessor( new DatabaseEntitiesProcessor());
+  builder.addProcessor( new VaultEntitiesProcessor());

  builder.addProcessor(new ScaffolderEntitiesProcessor());
  const { processingEngine, router } = await builder.build();
  await processingEngine.start();
  return router;
}

...

By adding the processors to the application's backend, we extend our configuration to the default behavior of the backstage.

Remember that in order to access the customized types, you just need to grant access in app-config.yaml:

catalog:
  import:
    entityFilename: catalog-info.yaml
    pullRequestBranchName: backstage-integration
  rules:
+    - allow: [Component, System, API, Resource, Location, Database, Cluster, Environment, Vault]
...

/@veecode-platform/plugin-veecode-platform-common/

    Package Sidebar

    Install

    npm i @veecode-platform/plugin-veecode-platform-common

    Weekly Downloads

    168

    Version

    0.3.19

    License

    Apache-2.0

    Unpacked Size

    129 kB

    Total Files

    38

    Last publish

    Collaborators

    • lmtxr.veecodes
    • veecode-admin