another old warp-tls workaround

(cherry picked from commit a7b3a2b097)
This commit is contained in:
Joey Hess 2014-03-12 12:32:43 -04:00
parent b5a9d8e81c
commit 3961bcf486

View file

@ -125,9 +125,13 @@ myUrl tlssettings webapp addr = unpack $ yesodRender webapp urlbase DashboardR [
getTlsSettings :: Annex (Maybe TLS.TLSSettings)
getTlsSettings = do
#ifdef WITH_WEBAPP_HTTPS
cert <- fromRepo gitAnnexWebCertificate
privkey <- fromRepo gitAnnexWebPrivKey
ifM (liftIO $ allM doesFileExist [cert, privkey])
( return $ Just $ TLS.tlsSettings cert privkey
, return Nothing
)
#else
return Nothing
#endif