Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-pages.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/app.go
diff options
context:
space:
mode:
authorKamil Trzcinski <ayufan@ayufan.eu>2016-02-11 21:24:45 +0300
committerKamil Trzcinski <ayufan@ayufan.eu>2016-02-11 21:24:45 +0300
commit3d691bf42432304a3ae6d6465c3f596629891e74 (patch)
treeb37d38ccf1a672a4c862f53b4534e07db5122091 /app.go
parent3824fc8ca34b8f94ae7ef7550aec196dbbfdecf5 (diff)
Move most of configuration to appConfig
Diffstat (limited to 'app.go')
-rw-r--r--app.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/app.go b/app.go
index a3fc8335..ebc0f578 100644
--- a/app.go
+++ b/app.go
@@ -44,7 +44,7 @@ func (a *theApp) serveContent(ww http.ResponseWriter, r *http.Request, https boo
defer w.Log(r)
// Add auto redirect
- if https && !*serverHTTP {
+ if https && !a.RedirectHTTP {
u := *r.URL
u.Scheme = "https"
u.Host = r.Host
@@ -89,7 +89,7 @@ func (a *theApp) Run() {
wg.Add(1)
go func() {
defer wg.Done()
- err := listenAndServe(a.ListenHTTP, a.ServeHTTP, nil)
+ err := listenAndServe(a.ListenHTTP, a.ServeHTTP, a.HTTP2, nil)
if err != nil {
log.Fatal(err)
}
@@ -101,7 +101,7 @@ func (a *theApp) Run() {
wg.Add(1)
go func() {
defer wg.Done()
- err := listenAndServeTLS(a.ListenHTTPS, a.RootCertificate, a.RootKey, a.ServeHTTP, a.ServeTLS)
+ err := listenAndServeTLS(a.ListenHTTPS, a.RootCertificate, a.RootKey, a.ServeHTTP, a.ServeTLS, a.HTTP2)
if err != nil {
log.Fatal(err)
}
@@ -113,7 +113,7 @@ func (a *theApp) Run() {
wg.Add(1)
go func() {
defer wg.Done()
- err := listenAndServe(a.listenProxy, a.ServeProxy, nil)
+ err := listenAndServe(a.listenProxy, a.ServeProxy, a.HTTP2, nil)
if err != nil {
log.Fatal(err)
}