Skip to content
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

Iterate towards a "real" application that can be configured #8

Open
michaelarnauts opened this issue Jun 7, 2024 · 1 comment
Open

Comments

@michaelarnauts
Copy link
Contributor

First of all, I don't want to force this project into a direction you don't want to. Feel free to reject my comments and remarks :)

This project has a good functionality, but it's lacking options to configure it without having to edit the files. My goal is to have an application (probably packaged in a docker image) that can be configured and started with all database drivers included.

I'm looking at https://fastapi.tiangolo.com/advanced/settings/ to parse environment variables (and probably also command line variables now that pydantic/pydantic-settings#214 has been merged, a few days ago!), so the hardcoded configurations like the db_connection parameters, or the RadTables overrides can be removed and filled in from configuration.

I've started working on this, but if you don't like this direction, feel free to say so, and I'll setup a fork of this project with these changes.

@angely-dev
Copy link
Owner

Actually, when I started the project, I did have in mind the idea to "package" the application at some point, hence the usage of DB API 2.0 (PEP 249) and RadTables so that it can be parameterized (and some other config could be parametrized as well, like PER_PAGE for pagination). Now what about the authentication? Maybe we can provide the ability to enable API key authentication.

So I'm not against it, on the contrary, and thanks again for your interest and your work! Please allow me some time to check the PR in detail.

About the CI/CD, I am okay with Black code formatting as I already use it on another project. I also want to add mypy for static type checking. Ideally, I am planning to unit test the API as well as pyfreeradius using TestClient. And all this (Black, mypy, pytest) could be run using a GitHub workflow. Unit test will require a Docker container though.

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

No branches or pull requests

2 participants