config.tmpl 8.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205
  1. {{template "base/head" .}}
  2. {{template "base/navbar" .}}
  3. <div id="body" class="container" data-page="admin">
  4. {{template "admin/nav" .}}
  5. <div id="admin-container" class="col-md-10">
  6. <div class="panel panel-default">
  7. <div class="panel-heading">
  8. Server Configuration
  9. </div>
  10. <div class="panel-body">
  11. <dl class="dl-horizontal admin-dl-horizontal">
  12. <dt>Application Name</dt>
  13. <dd>{{AppName}}</dd>
  14. <dt>Application Version</dt>
  15. <dd>{{AppVer}}</dd>
  16. <dt>Application URL</dt>
  17. <dd>{{.AppUrl}}</dd>
  18. <dt>Domain</dt>
  19. <dd>{{.Domain}}</dd>
  20. <dt>Offline Mode</dt>
  21. <dd><i class="fa fa{{if .OfflineMode}}-check{{end}}-square-o"></i></dd>
  22. <hr/>
  23. <dt>Run User</dt>
  24. <dd>{{.RunUser}}</dd>
  25. <dt>Run Mode</dt>
  26. <dd>{{.RunMode}}</dd>
  27. <hr/>
  28. <dt>Repository Root Path</dt>
  29. <dd>{{.RepoRootPath}}</dd>
  30. <dt>Script Type</dt>
  31. <dd>{{.ScriptType}}</dd>
  32. </dl>
  33. </div>
  34. </div>
  35. <div class="panel panel-default">
  36. <div class="panel-heading">
  37. Database Configuration
  38. </div>
  39. <div class="panel-body">
  40. <dl class="dl-horizontal admin-dl-horizontal">
  41. <dt>Type</dt>
  42. <dd>{{.DbCfg.Type}}</dd>
  43. <dt>Host</dt>
  44. <dd>{{.DbCfg.Host}}</dd>
  45. <dt>Name</dt>
  46. <dd>{{.DbCfg.Name}}</dd>
  47. <dt>User</dt>
  48. <dd>{{.DbCfg.User}}</dd>
  49. <dt>SslMode</dt>
  50. <dd>{{.DbCfg.SslMode}} (for "postgres" only)</dd>
  51. <dt>Path</dt>
  52. <dd>{{.DbCfg.Path}} (for "sqlite3" only)</dd>
  53. </dl>
  54. </div>
  55. </div>
  56. <div class="panel panel-default">
  57. <div class="panel-heading">
  58. Service Configuration
  59. </div>
  60. <div class="panel-body">
  61. <dl class="dl-horizontal admin-dl-horizontal">
  62. <dt>Register Email Confirmation</dt>
  63. <dd><i class="fa fa{{if .Service.RegisterEmailConfirm}}-check{{end}}-square-o"></i></dd>
  64. <dt>Disable Registration</dt>
  65. <dd><i class="fa fa{{if .Service.DisableRegistration}}-check{{end}}-square-o"></i></dd>
  66. <dt>Require Sign In View</dt>
  67. <dd><i class="fa fa{{if .Service.RequireSignInView}}-check{{end}}-square-o"></i></dd>
  68. <dt>Mail Notification</dt>
  69. <dd><i class="fa fa{{if .Service.NotifyMail}}-check{{end}}-square-o"></i></dd>
  70. <dt>Enable Cache Avatar</dt>
  71. <dd><i class="fa fa{{if .Service.EnableCacheAvatar}}-check{{end}}-square-o"></i></dd>
  72. <hr/>
  73. <dt>Active Code Lives</dt>
  74. <dd>{{.Service.ActiveCodeLives}} minutes</dd>
  75. <dt>Reset Password Code Lives</dt>
  76. <dd>{{.Service.ResetPwdCodeLives}} minutes</dd>
  77. </dl>
  78. </div>
  79. </div>
  80. <div class="panel panel-default">
  81. <div class="panel-heading">
  82. Mailer Configuration
  83. </div>
  84. <div class="panel-body">
  85. <dl class="dl-horizontal admin-dl-horizontal">
  86. <dt>Enabled</dt>
  87. <dd><i class="fa fa{{if .MailerEnabled}}-check{{end}}-square-o"></i></dd>
  88. {{if .MailerEnabled}}<dt>Name</dt>
  89. <dd>{{.Mailer.Name}}</dd>
  90. <dt>Host</dt>
  91. <dd>{{.Mailer.Host}}</dd>
  92. <dt>User</dt>
  93. <dd>{{.Mailer.User}}</dd>{{end}}
  94. </dl>
  95. </div>
  96. </div>
  97. <div class="panel panel-default">
  98. <div class="panel-heading">
  99. OAuth Configuration
  100. </div>
  101. <div class="panel-body">
  102. <dl class="dl-horizontal admin-dl-horizontal">
  103. <dt>Enabled</dt>
  104. <dd><i class="fa fa{{if .OauthEnabled}}-check{{end}}-square-o"></i></dd>
  105. {{if .OauthEnabled}}<dt>GitHub</dt>
  106. <dd><i class="fa fa{{if .Oauther.GitHub}}-check{{end}}-square-o"></i></dd>
  107. <dt>Google</dt>
  108. <dd><i class="fa fa{{if .Oauther.Google}}-check{{end}}-square-o"></i></dd>
  109. <dt>Tencent QQ</dt>
  110. <dd><i class="fa fa{{if .Oauther.Tencent}}-check{{end}}-square-o"></i></dd>
  111. <dt>Weibo</dt>
  112. <dd><i class="fa fa{{if .Oauther.Weibo}}-check{{end}}-square-o"></i></dd>
  113. {{end}}
  114. </dl>
  115. </div>
  116. </div>
  117. <div class="panel panel-default">
  118. <div class="panel-heading">
  119. Cache Configuration
  120. </div>
  121. <div class="panel-body">
  122. <dl class="dl-horizontal admin-dl-horizontal">
  123. <dt>Cache Adapter</dt>
  124. <dd>{{.CacheAdapter}}</dd>
  125. <dt>Cache Config</dt>
  126. <dd><div style="padding-top: 5px;"><pre>{{.CacheConfig}}</pre></div></dd>
  127. </dl>
  128. </div>
  129. </div>
  130. <div class="panel panel-default">
  131. <div class="panel-heading">
  132. Session Configuration
  133. </div>
  134. <div class="panel-body">
  135. <dl class="dl-horizontal admin-dl-horizontal">
  136. <dt>Session Provider</dt>
  137. <dd>{{.SessionProvider}}</dd>
  138. <dt>Cookie Name</dt>
  139. <dd>{{.SessionConfig.CookieName}}</dd>
  140. <dt>Enable Set Cookie</dt>
  141. <dd><i class="fa fa{{if .SessionConfig.EnableSetCookie}}-check{{end}}-square-o"></i></dd>
  142. <dt>GC Interval Time</dt>
  143. <dd>{{.SessionConfig.GcIntervalTime}} seconds</dd>
  144. <dt>Session Life Time</dt>
  145. <dd>{{.SessionConfig.SessionLifeTime}} seconds</dd>
  146. <dt>HTTPS Only</dt>
  147. <dd><i class="fa fa{{if .SessionConfig.CookieSecure}}-check{{end}}-square-o"></i></dd>
  148. <dt>Cookie Life Time</dt>
  149. <dd>{{.SessionConfig.CookieLifeTime}} seconds</dd>
  150. <dt>Session ID Hash Function</dt>
  151. <dd>{{.SessionConfig.SessionIDHashFunc}}</dd>
  152. <dt>Session ID Hash Key</dt>
  153. <dd>{{.SessionConfig.SessionIDHashKey}}</dd>
  154. <dt>Provider Config</dt>
  155. <dd>{{.SessionConfig.ProviderConfig}}</dd>
  156. </dl>
  157. </div>
  158. </div>
  159. <div class="panel panel-default">
  160. <div class="panel-heading">
  161. Picture Configuration
  162. </div>
  163. <div class="panel-body">
  164. <dl class="dl-horizontal admin-dl-horizontal">
  165. <dt>Picture Service</dt>
  166. <dd>{{.PictureService}}</dd>
  167. </dl>
  168. </div>
  169. </div>
  170. <div class="panel panel-default">
  171. <div class="panel-heading">
  172. Log Configuration
  173. </div>
  174. <div class="panel-body">
  175. <dl class="dl-horizontal admin-dl-horizontal">
  176. <dt>Log Mode</dt>
  177. <dd>{{.LogMode}}</dd>
  178. <dt>Log Config</dt>
  179. <dd>
  180. <div style="padding-top: 5px;"><pre>{{.LogConfig}}</pre></div>
  181. </dd>
  182. </dl>
  183. </div>
  184. </div>
  185. </div>
  186. </div>
  187. {{template "base/footer" .}}