cannot disable swagger #12774

Closed
opened 2025-11-02 10:20:35 -06:00 by GiteaMirror · 2 comments
Owner

Originally created by @relikd on GitHub (Apr 2, 2024).

Description

  1. set ENABLE_SWAGGER = false
  2. systemctl restart gitea
  3. API is still enabled

Gitea Version

1.21.10

Can you reproduce the bug on the Gitea demo site?

No

Log Gist

No response

Screenshots

No response

Git Version

No response

Operating System

Arch

How are you running Gitea?

pacman gitea binary

Database

SQLite

Originally created by @relikd on GitHub (Apr 2, 2024). ### Description 1) set `ENABLE_SWAGGER = false` 2) `systemctl restart gitea` 3) API is still enabled ### Gitea Version 1.21.10 ### Can you reproduce the bug on the Gitea demo site? No ### Log Gist _No response_ ### Screenshots _No response_ ### Git Version _No response_ ### Operating System Arch ### How are you running Gitea? pacman gitea binary ### Database SQLite
GiteaMirror added the type/bug label 2025-11-02 10:20:35 -06:00
Author
Owner

@techknowlogick commented on GitHub (Apr 2, 2024):

Swagger is a UI for easy API documentation. Disabling swagger does not disable the API. The API is required for application functionality.

@techknowlogick commented on GitHub (Apr 2, 2024): Swagger is a UI for easy API documentation. Disabling swagger does not disable the API. The API is required for application functionality.
Author
Owner

@relikd commented on GitHub (Apr 2, 2024):

Actually, I was refering to the config parameter. ... But I was about to close this issue anyway. Apparently I forgot to uncomment the "[api]" header. With the header set, the API is disabled as the config comment suggests.

@relikd commented on GitHub (Apr 2, 2024): Actually, I was refering to the config parameter. ... But I was about to close this issue anyway. Apparently I forgot to uncomment the "[api]" header. With the header set, the API is disabled as the config comment suggests.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#12774