From 00b6c5f315ac00e9da8a6de99c50b064e9f87872 Mon Sep 17 00:00:00 2001 From: Rob Watson Date: Wed, 3 Jan 2018 20:02:46 +0000 Subject: Implement HTTPS-only pages - Check `config.json` for `httpsonly` attribute - Store value against custom domain or group/project pair - Respond with 301 redirect to HTTP requests to these domains/projects Re: https://gitlab.com/gitlab-org/gitlab-ce/issues/28857 --- domain_config.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'domain_config.go') diff --git a/domain_config.go b/domain_config.go index e0f00cc4..f5c3db79 100644 --- a/domain_config.go +++ b/domain_config.go @@ -11,10 +11,12 @@ type domainConfig struct { Domain string Certificate string Key string + HTTPSOnly bool `json:"https_only"` } type domainsConfig struct { - Domains []domainConfig + Domains []domainConfig + HTTPSOnly bool `json:"https_only"` } func (c *domainConfig) Valid(rootDomain string) bool { -- cgit v1.2.3