0.0.17 • Published 10 months ago

@mortware/kvd v0.0.17

Weekly downloads
-
License
ISC
Repository
-
Last release
10 months ago

@mortware/kvd

Configuration

This package is configured through a JSON configuration file. The configuration is set at startup and remains constant throughout the application's lifecycle.

Using a configuration file

Create a file named kvd-config.json in the root of your project with the following structure:

json
{
  "azure": {
    "blob": {
      "storageUrl": "your-blob-storage-url",
      "containerName": "your-container-name",
    },
    "queue": {
      "storageUrl": "your-queue-storage-url",
      "importName": "your-queue-name",
    },
    "sql": {
      "server": "your-azure-sql-server",
      "database": "your-azure-sql-database"
    }
  },
  "processDelay": "delay-in-ms"
}

The configuration object has the following structure:

  • azure: Contains Azure-specific configurations
    • blob: Azure Blob Storage settings
      • url: URL for Azure Blob Storage
      • container: Name of the container in Azure Blob Storage
    • queue: Azure Queue Storage settings
      • url: URL for Azure Queue Storage
      • import: (Optional) Name of the import queue in Azure Queue Storage
      • catalog: (Optional) Name of the catalog queue in Azure Queue Storage
    • sql: Azure SQL Database settings
      • server: Azure SQL Server address
      • database: Name of the database in Azure SQL
  • processDelay: (Optional) Delay in milliseconds to slow down the automation process

Accessing the configuration

The configuration is exported as a read-only object and can be accessed in your code as follows:

import { config } from '@mortware/kvd';
console.log(config.azure.blob.url);
0.0.17

10 months ago

0.0.16

10 months ago

0.0.15

10 months ago

0.0.14

10 months ago

0.0.13

10 months ago

0.0.12

10 months ago

0.0.11

10 months ago

0.0.10

10 months ago

0.0.9

10 months ago

0.0.8

10 months ago

0.0.7

10 months ago

0.0.6

10 months ago

0.0.5

10 months ago

0.0.4

10 months ago

0.0.3

10 months ago

0.0.2

10 months ago

0.0.1

10 months ago