Auth: Limit places administration to local - #1888
Conversation
0eb319a to
993699b
Compare
993699b to
a9c2d91
Compare
a9c2d91 to
528369d
Compare
Signed-off-by: Burfeind, Jan-Niklas <git@aiyionpri.me>
which can be set to LOCAL_ADMIN or left out. Setting it to LOCAL_ADMIN requires all changes to places to come from a loopback IP. This allows a centralized places definition and gives clients early feedback about an instance ignoring their demands. Signed-off-by: Burfeind, Jan-Niklas <git@aiyionpri.me>
528369d to
380da7a
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #1888 +/- ##
========================================
- Coverage 46.0% 45.8% -0.2%
========================================
Files 180 180
Lines 14464 14497 +33
========================================
Hits 6654 6654
- Misses 7810 7843 +33
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. |
|
@Emantor is there a branch I could take for inspiration to get this reviewed? |
| def auth_required(func): | ||
| @wraps(func) | ||
| async def decorated(self, request, context): | ||
| if environ.get("AUTH") == "LOCAL_ADMIN": |
There was a problem hiding this comment.
We should really stop adding more and more env variables to configure the exporter and reuse the existing configuration yaml for non-resource configuration as well.
@Emantor I think you mentioned that you had an Idea how that could look like?
There was a problem hiding this comment.
For config related to deployment environments I tend to follow https://12factor.net/config
But if you'd rather have this in a config, I'd follow the wish :)
Description
Checklist