Settings can't be provided via environment variables

Open
#26 0 comments 0 reactions 0 assignees View on GitHub

@gagantrivedi is already working on this.

Since Oct 17, 2026.

  • #27 by @gagantrivedi — open

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
58/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Active
Tech stack
docker, rust
Domain
backend

Research direction

Start by reading the Rust proxy's configuration loading and environment-variable handling, then compare the documented settings with the Python proxy behavior referenced in the issue. Reproduce the startup failure with the provided Docker command and check that env vars work both without a config file and when they conflict with config.json; done means env vars take precedence in both cases.

Written by the indexing model from the issue text.

Description

Current behaviour

The Rust proxy only reads settings from config.json. Environment variables such as ENVIRONMENT_KEY_PAIRS or API_POLL_FREQUENCY_SECONDS are ignored:

  • With no config file, the container exits on startup with Failed to read config file.
  • With a config file present, conflicting env vars are silently ignored and the file values are used.

The Python proxy reads both, with env vars taking precedence over the file, and the docs document env var configuration. Deployments configured via env vars can't switch to the Rust image as-is.

Reproduction

docker run --rm \
  -e ENVIRONMENT_KEY_PAIRS='[{"server_side_key":"ser.abc","client_side_key":"abc"}]' \
  flagsmith/edge-proxy-rs:0.2.0
# Error: configuration error: Failed to read config file: No such file or directory (os error 2)

docker run --rm \
  -e ENVIRONMENT_KEY_PAIRS='[{"server_side_key":"ser.abc","client_side_key":"abc"}]' \
  flagsmith/edge-proxy:2.23.0
# starts and polls using client key "abc"

Expected

Same as the Python proxy: settings can be provided via environment variables, taking precedence over config.json.

Dominant language
Rust
Stars
3
Forks
1
Avg merge
2d 23h
Merged PRs (30d)
4

Getting set up

  • Ships a Dockerfile or Docker Compose file
  • No pull request template
  • No contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Flagsmith/edge-proxy-rs

All issues in Flagsmith/edge-proxy-rs

Similar issues

More Rust issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.