Skip to content

[Refactor]: Improve configuration loading #32

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
jescalada opened this issue Mar 8, 2025 · 0 comments · May be fixed by finos/git-proxy#998
Open

[Refactor]: Improve configuration loading #32

jescalada opened this issue Mar 8, 2025 · 0 comments · May be fixed by finos/git-proxy#998
Assignees

Comments

@jescalada
Copy link
Collaborator

Is your feature request related to a problem? Please describe.
Currently, the app's configuration is set in proxy.config.json, which may cause these problems:

  • undefined errors caused by missing entries
  • Type errors due to non-normalized schemas for arrays/objects (for example, auth methods all have unique properties, which should be typed and normalized)

Describe the solution you'd like
I think a good solution would be to keep the configuration in a TS file, and load it from there. I believe this would cause breaking changes to current users, so we would have to discuss if bumping up the git-proxy version is possible/desirable or if we could have a hybrid solution instead.

Describe alternatives you've considered
Using environment variables, but that's sadly unrealistic because of the complexity of the config.

Additional context
Working with adding new auth methods (#30, #24) made me realize that this is necessary to make sure users can have auth methods without things blowing up due to missing or malformed config files.

@jescalada jescalada changed the title Improve configuration loading [Refactor]: Improve configuration loading Mar 8, 2025
@fabiovincenzi fabiovincenzi self-assigned this Apr 23, 2025
@fabiovincenzi fabiovincenzi linked a pull request Apr 30, 2025 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants