The Directory server supports configuration via environment variables, YAML configuration files, or both. Environment variables follow the DIRECTORY_SERVER_ prefix convention.
The server validates all records server-side. Records are validated using the configured OASF schema URL.
oasf_api_validation.schema_url/DIRECTORY_SERVER_OASF_API_VALIDATION_SCHEMA_URL- OASF schema URL for API-based validation (required)- Default:
https://schema.oasf.outshift.com - URL of the OASF server to use for validation
- This affects all record validation operations including push, sync, and import
- Default:
Example with environment variables:
# Use default OASF API validator
./dirctl-apiserver
# Use custom OASF server
DIRECTORY_SERVER_OASF_API_VALIDATION_SCHEMA_URL=http://localhost:8080 ./dirctl-apiserver
# Use custom OASF server
DIRECTORY_SERVER_OASF_API_VALIDATION_SCHEMA_URL="http://localhost:8080" ./dirctl-apiserverExample with YAML configuration:
# server.config.yml
oasf_api_validation:
schema_url: "https://schema.oasf.outshift.com"
listen_address: "0.0.0.0:8888"To test with a local OASF instance deployed alongside the directory server:
-
Enable OASF in Helm values - Edit
install/charts/dir/values.yaml:apiserver: oasf: enabled: true
-
Set schema URL to use the deployed OASF instance - In the same file, set:
apiserver: config: oasf_api_validation: schema_url: "http://dir-ingress-controller.dir-server.svc.cluster.local"
Replace
dirwith your Helm release name anddir-serverwith your namespace if different. -
Deploy:
task build task deploy:local
The OASF instance will be deployed as a subchart in the same namespace and automatically configured for multi-version routing via ingress.
If you want to deploy with a locally built OASF image (e.g., containing 0.9.0-dev schema files), you need to load the image into Kind before deploying. The task deploy:local command automatically creates a cluster and loads images, but it doesn't load custom OASF images. Follow these steps:
-
Create the Kind cluster first:
task test-env:kubernetes:setup-cluster
This creates the cluster and loads the Directory server images.
-
Build and tag your local OASF image:
cd /path/to/oasf/server docker build -t ghcr.io/agntcy/oasf-server:latest .
-
Load the OASF image into Kind:
kind load docker-image ghcr.io/agntcy/oasf-server:latest --name agntcy-cluster
-
Configure values.yaml to use the local image:
oasf: enabled: true image: repository: ghcr.io/agntcy/oasf-server versions: - server: latest schema: 0.9.0-dev default: true
-
Deploy with Helm (don't use
task deploy:localas it will recreate the cluster):helm upgrade --install dir ./install/charts/dir \ -f ./install/charts/dir/values.yaml \ -n dir-server --create-namespace
Note: If you update the local OASF image, reload it into Kind and restart the deployment:
kind load docker-image ghcr.io/agntcy/oasf-server:latest --name agntcy-cluster
kubectl rollout restart deployment/dir-oasf-0-9-0-dev -n dir-serverFor complete server configuration including authentication, authorization, storage, routing, and database options, see the server configuration reference.