mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-11-04 16:29:37 +00:00
Merge pull request #628 from KylePDavis/use_url_prefix_for_fcgi
Use AppSubUrl as prefix for routes in FCGI mode
This commit is contained in:
commit
4c770b87c5
1 changed files with 3 additions and 0 deletions
|
@ -85,6 +85,9 @@ func newMacaron() *macaron.Macaron {
|
||||||
if setting.EnableGzip {
|
if setting.EnableGzip {
|
||||||
m.Use(macaron.Gziper())
|
m.Use(macaron.Gziper())
|
||||||
}
|
}
|
||||||
|
if setting.Protocol == setting.FCGI {
|
||||||
|
m.SetURLPrefix(setting.AppSubUrl)
|
||||||
|
}
|
||||||
m.Use(macaron.Static(
|
m.Use(macaron.Static(
|
||||||
path.Join(setting.StaticRootPath, "public"),
|
path.Join(setting.StaticRootPath, "public"),
|
||||||
macaron.StaticOptions{
|
macaron.StaticOptions{
|
||||||
|
|
Loading…
Reference in a new issue