summaryrefslogtreecommitdiff
path: root/system
diff options
context:
space:
mode:
Diffstat (limited to 'system')
-rw-r--r--system/admin/config/config.go6
-rw-r--r--system/tls/enable.go3
2 files changed, 7 insertions, 2 deletions
diff --git a/system/admin/config/config.go b/system/admin/config/config.go
index fdc1ae4..2bc80c6 100644
--- a/system/admin/config/config.go
+++ b/system/admin/config/config.go
@@ -13,6 +13,7 @@ type Config struct {
Name string `json:"name"`
Domain string `json:"domain"`
HTTPPort string `json:"http_port"`
+ HTTPSPort string `json:"https_port"`
AdminEmail string `json:"admin_email"`
ClientSecret string `json:"client_secret"`
Etag string `json:"etag"`
@@ -46,6 +47,11 @@ func (c *Config) MarshalEditor() ([]byte, error) {
}),
},
editor.Field{
+ View: editor.Input("HTTPSPort", c, map[string]string{
+ "type": "hidden",
+ }),
+ },
+ editor.Field{
View: editor.Input("AdminEmail", c, map[string]string{
"label": "Adminstrator Email (will be notified of internal system information)",
}),
diff --git a/system/tls/enable.go b/system/tls/enable.go
index c6f65b3..f9c16d8 100644
--- a/system/tls/enable.go
+++ b/system/tls/enable.go
@@ -10,7 +10,6 @@ import (
"time"
"github.com/ponzu-cms/ponzu/system/db"
-
"golang.org/x/crypto/acme/autocert"
)
@@ -71,7 +70,7 @@ func Enable() {
setup()
server := &http.Server{
- Addr: ":443",
+ Addr: fmt.Sprintf(":%s", db.ConfigCache("https_port")),
TLSConfig: &tls.Config{GetCertificate: m.GetCertificate},
}