enable and document using manage.py in online environment #260

Closed
kiara wants to merge 1 commit from kiara/fediversity:online-manage-py into main
Owner

allows e.g. making users from cli

allows e.g. making users from cli

The existing code should work; what problem is this trying to solve?

The existing code should work; what problem is this trying to solve?
Author
Owner

@fricklerhandwerk try it in the demo env - each of the currently mandatory env vars will error as they are set only in the service, not in external cli invocations

@fricklerhandwerk try it in the demo env - each of the currently mandatory env vars will error as they are set only in the service, not in external cli invocations

That would be very surprising, this is the code where it's accounted for:
https://git.fediversity.eu/Fediversity/Fediversity/src/branch/main/panel/nix/configuration.nix#L45
And the executable is added to the environment here:
https://git.fediversity.eu/Fediversity/Fediversity/src/branch/main/panel/nix/configuration.nix#L139

It's possible that the command is slightly broken because, as noted early on, all of this tends to be janky if not set just right. But ripping out a random part of that system and trying to run manual invocations is not the right approach.

I'll test and debug it later today.

That would be very surprising, this is the code where it's accounted for: https://git.fediversity.eu/Fediversity/Fediversity/src/branch/main/panel/nix/configuration.nix#L45 And the executable is added to the environment here: https://git.fediversity.eu/Fediversity/Fediversity/src/branch/main/panel/nix/configuration.nix#L139 It's possible that the command is slightly broken because, as noted early on, all of this tends to be janky if not set just right. But ripping out a random part of that system and trying to run manual invocations is not the right approach. I'll test and debug it later today.
Author
Owner

i see, thanks for your feedback.
i now understand the manage command is exposed under the root user, while the environment could say be borrowed from the service by systemd-run.
that being said, the credential currently is exposed only to the service, which our settings.py currently requires while manual invocations of the manage command would typically be run from a shell, rather than from our service.

i see, thanks for your feedback. i now understand the `manage` command is exposed under the root user, while the environment could say be borrowed from the service by `systemd-run`. that being said, the credential currently is exposed only to the service, which our `settings.py` currently requires while manual invocations of the `manage` command would typically be run from a shell, rather than from our service.
kiara force-pushed online-manage-py from 62cdb566e6
All checks were successful
/ check-pre-commit (pull_request) Successful in 23s
/ check-website (pull_request) Successful in 8s
/ check-peertube (pull_request) Successful in 20s
to 34fca24bb1
All checks were successful
/ check-pre-commit (pull_request) Successful in 25s
/ check-website (pull_request) Successful in 11s
/ check-peertube (pull_request) Successful in 22s
2025-03-20 10:23:42 +01:00
Compare
kiara force-pushed online-manage-py from 34fca24bb1
All checks were successful
/ check-pre-commit (pull_request) Successful in 25s
/ check-website (pull_request) Successful in 11s
/ check-peertube (pull_request) Successful in 22s
to a858a05d20
All checks were successful
/ check-pre-commit (pull_request) Successful in 25s
/ check-website (pull_request) Successful in 9s
/ check-peertube (pull_request) Successful in 21s
2025-03-20 10:32:13 +01:00
Compare
kiara force-pushed online-manage-py from a858a05d20
All checks were successful
/ check-pre-commit (pull_request) Successful in 25s
/ check-website (pull_request) Successful in 9s
/ check-peertube (pull_request) Successful in 21s
to 72805263a8 2025-03-20 11:22:28 +01:00
Compare
kiara force-pushed online-manage-py from 72805263a8 to 4cdc2702e0
All checks were successful
/ check-pre-commit (pull_request) Successful in 25s
/ check-website (pull_request) Successful in 11s
/ check-peertube (pull_request) Successful in 21s
/ check-panel (pull_request) Successful in 1m11s
2025-03-20 11:22:31 +01:00
Compare
Author
Owner

closing as this should be obsolete once tests pass

closing as this should be obsolete once tests pass
kiara closed this pull request 2025-03-20 11:37:53 +01:00
All checks were successful
/ check-pre-commit (pull_request) Successful in 25s
/ check-website (pull_request) Successful in 11s
/ check-peertube (pull_request) Successful in 21s
/ check-panel (pull_request) Successful in 1m11s

Pull request closed

Sign in to join this conversation.
No reviewers
No milestone
No project
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
fediversity/fediversity!260
No description provided.