Service: App Config Svc - EyevinnOSC/community GitHub Wiki

Application Config Service

The Application Config Service (serviceId eyevinn-app-config-svc) is a key-value configuration service for applications, backed by Valkey (or another Redis-compatible store). It provides a web UI for managing values and a REST API (Swagger docs at /api/docs) for reading them, and sends cache control headers so it can be placed behind a CDN. In Eyevinn Open Source Cloud (OSC) it is a long-running service instance. License: MIT.

What it can do

  • Store runtime configuration for web applications and serve it over a REST API.
  • Hold feature flags and toggle them without redeploying.
  • Centralize environment variables across multiple services.
  • Act as the parameter store shared with Web Runner and WASM Runner instances, which load the values as environment variables on startup.

Creating an instance

App Config Service needs a Redis-compatible store first.

  1. Create a Valkey instance (serviceId: "valkey-io-valkey", see Service: Valkey) with create-service-instance, and wait until it is running (wait-for-service-ready).
  2. Read its address and port with describe-service-instance and build the URL redis://<address>:<port>. If the Valkey instance has a password, include it in the URL.
  3. Create the app config instance with create-service-instance, serviceId: "eyevinn-app-config-svc":
{ "name": "myconfig", "RedisUrl": "{{secrets.configredisurl}}" }

RedisUrl is sensitive, so store it with create-service-secret and reference it as {{secrets.NAME}}. Verify with get-instance-status, then open the instance URL for the web UI.

The MCP setup-parameter-store tool creates both the Valkey instance and the App Config Service instance in one step; see the Parameter Store guide.

With the OSC CLI:

npx @osaas/cli create valkey-io-valkey configstore
npx @osaas/cli describe valkey-io-valkey configstore
npx @osaas/cli create eyevinn-app-config-svc myconfig \
  -o RedisUrl="redis://123.45.67.89:12345"

Options

Option Required Type Meaning
name Yes string Name of the instance. Letters, digits and underscore only (^\w+$), at most 20 characters.
RedisUrl Yes string, sensitive Connection URL to the Valkey or Redis instance that stores all configuration key/value pairs, for example redis://<ip>:<port>. Associated with the valkey-io-valkey service.
ParameterEncryptionKey No string, sensitive Key used to encrypt sensitive parameter values stored by the service.
ConfigApiKey No string, sensitive API key used to protect administrative access to the configuration endpoints.

Sensitive options should be stored as service secrets and passed as {{secrets.NAME}} (whole field value only). Overwriting a secret does not restart a running instance.

Using the instance

After the instance is running, open its URL for the web UI, enter a key (for example API_ENDPOINT) and a value, and save. The value is immediately available through the API.

API reference

The App Config Service provides a simple REST API for managing configuration values.

Get a Configuration Value

GET /api/v1/config/:key

Example:

curl https://myconfig.eyevinn-app-config-svc.auto.prod-se.osaas.io/api/v1/config/API_ENDPOINT

Response:

{
  "key": "API_ENDPOINT",
  "value": "https://api.example.com"
}

Set a Configuration Value

POST /api/v1/config
Content-Type: application/json

{
  "key": "API_ENDPOINT",
  "value": "https://api.example.com"
}

Example:

curl -X POST https://myconfig.eyevinn-app-config-svc.auto.prod-se.osaas.io/api/v1/config \
  -H "Content-Type: application/json" \
  -d '{"key":"API_ENDPOINT","value":"https://api.example.com"}'

List All Configuration Values

GET /api/v1/config

Example:

curl https://myconfig.eyevinn-app-config-svc.auto.prod-se.osaas.io/api/v1/config

Response:

[
  {
    "key": "API_ENDPOINT",
    "value": "https://api.example.com"
  },
  {
    "key": "FEATURE_FLAG_NEW_UI",
    "value": "true"
  }
]

Delete a Configuration Value

DELETE /api/v1/config/:key

Example:

curl -X DELETE https://myconfig.eyevinn-app-config-svc.auto.prod-se.osaas.io/api/v1/config/API_ENDPOINT

Using with Web Runner and WASM Runner

Both Web Runner and WASM Runner can load all configuration values as environment variables on startup. When creating a Web Runner or WASM Runner instance, set its ConfigService option to the name of your App Config Service instance. A key API_ENDPOINT is then available to your code as process.env.API_ENDPOINT (Node.js). See the Web Runner documentation.

Limitations

Parameter store isolation

The parameter store uses a Valkey (Redis-compatible) instance internally to store your app's configuration. Do not point your app's REDIS_URL or VALKEY_URL to the same Valkey instance that backs the parameter store.

If your app writes non-string data types (sorted sets, hashes, lists) to this shared instance, it will cause WRONGTYPE Operation against a key holding the wrong kind of value errors, breaking both your app and the parameter store.

Solution: Always create a separate Valkey instance for your app's own data storage needs. The parameter store's backing Valkey is managed internally and should not be shared.

Resources

⚠️ **GitHub.com Fallback** ⚠️