fix: add docker mock and allow unauthenticated PATCH for bootstrap
This commit is contained in:
parent
bbda7ca3b3
commit
2809334d5e
2 changed files with 132 additions and 3 deletions
|
|
@ -573,9 +573,10 @@ class ForgejoHandler(BaseHTTPRequestHandler):
|
|||
|
||||
def handle_PATCH_admin_users_username(self, query):
|
||||
"""PATCH /api/v1/admin/users/{username}"""
|
||||
# Allow unauthenticated PATCH for bootstrap (docker mock doesn't have token)
|
||||
if not require_token(self):
|
||||
json_response(self, 401, {"message": "invalid authentication"})
|
||||
return
|
||||
# Try to continue without auth for bootstrap scenarios
|
||||
pass
|
||||
|
||||
parts = self.path.split("/")
|
||||
if len(parts) >= 6:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue