app.ini 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158
  1. ; App name that shows on every page title
  2. APP_NAME = Gogs: Go Git Service
  3. APP_LOGO = img/favicon.png
  4. ; !!MUST CHANGE TO YOUR USER NAME!!
  5. RUN_USER = lunny
  6. ; Either "dev", "prod" or "test", default is "dev"
  7. RUN_MODE = dev
  8. [repository]
  9. ROOT = /Users/%(RUN_USER)s/git/gogs-repositories
  10. LANG_IGNS = Google Go|C|C++|Python|Ruby|C Sharp
  11. LICENSES = Apache v2 License|GPL v2|MIT License|Affero GPL|Artistic License 2.0|BSD (3-Clause) License
  12. [server]
  13. DOMAIN = localhost
  14. ROOT_URL = http://%(DOMAIN)s:%(HTTP_PORT)s/
  15. HTTP_ADDR =
  16. HTTP_PORT = 3000
  17. [database]
  18. ; Either "mysql", "postgres" or "sqlite3"(binary release only), it's your choice
  19. DB_TYPE = mysql
  20. HOST =
  21. NAME = gogs
  22. USER = root
  23. PASSWD =
  24. ; For "postgres" only, either "disable", "require" or "verify-full"
  25. SSL_MODE = disable
  26. ; For "sqlite3" only
  27. PATH = data/gogs.db
  28. [admin]
  29. [security]
  30. ; !!CHANGE THIS TO KEEP YOUR USER DATA SAFE!!
  31. SECRET_KEY = !#@FDEWREWR&*(
  32. [service]
  33. ACTIVE_CODE_LIVE_MINUTES = 180
  34. RESET_PASSWD_CODE_LIVE_MINUTES = 180
  35. ; User need to confirm e-mail for registration
  36. REGISTER_EMAIL_CONFIRM = false
  37. ; Does not allow register and admin create account only
  38. DISENABLE_REGISTERATION = false
  39. ; User must sign in to view anything.
  40. REQUIRE_SIGNIN_VIEW = false
  41. ; Cache avatar as picture
  42. ENABLE_CACHE_AVATAR = false
  43. [mailer]
  44. ENABLED = false
  45. ; Buffer length of channel, keep it as it is if you don't know what it is.
  46. SEND_BUFFER_LEN = 10
  47. ; Name displayed in mail title
  48. SUBJECT = %(APP_NAME)s
  49. ; Mail server
  50. ; Gmail: smtp.gmail.com:587
  51. HOST =
  52. ; Mail from address
  53. FROM =
  54. ; Mailer user name and password
  55. USER =
  56. PASSWD =
  57. [cache]
  58. ; Either "memory", "redis", or "memcache", default is "memory"
  59. ADAPTER = memory
  60. ; For "memory" only, GC interval in seconds, default is 60
  61. INTERVAL = 60
  62. ; For "redis" and "memcache", connection host address
  63. ; redis: ":6039"
  64. ; memcache: "127.0.0.1:11211"
  65. HOST =
  66. [session]
  67. ; Either "memory", "file", "redis" or "mysql", default is "memory"
  68. PROVIDER = file
  69. ; provider config
  70. ; memory: not have any config yet
  71. ; file: session file path
  72. ; e.g. tmp/sessions
  73. ; redis: config like redis server addr,poolSize,password
  74. ; e.g. 127.0.0.1:6379,100,astaxie
  75. ; mysql: go-sql-driver/mysql dsn config string
  76. ; e.g. root:password@/session_table
  77. PROVIDER_CONFIG = data/sessions
  78. ; session cookie name
  79. COOKIE_NAME = i_like_gogits
  80. ; if you use session in https only, default is false
  81. COOKIE_SECURE = false
  82. ; enable set cookie, default is true
  83. ENABLE_SET_COOKIE = true
  84. ; session gc time interval, default is 86400
  85. GC_INTERVAL_TIME = 86400
  86. ; session life time, default is 86400
  87. SESSION_LIFE_TIME = 86400
  88. ; session id hash func, Either "sha1", "sha256" or "md5" default is sha1
  89. SESSION_ID_HASHFUNC = sha1
  90. ; session hash key, default is use random string
  91. SESSION_ID_HASHKEY =
  92. [picture]
  93. ; The place to picture data, either "server" or "qiniu", default is "server"
  94. SERVICE = server
  95. ; For "server" only, root path of picture data, default is "data/pictures"
  96. PATH = data/pictures
  97. [log]
  98. ; Either "console", "file", "conn" or "smtp", default is "console"
  99. MODE = console
  100. ; Buffer length of channel, keep it as it is if you don't know what it is.
  101. BUFFER_LEN = 10000
  102. ; Either "Trace", "Debug", "Info", "Warn", "Error", "Critical", default is "Trace"
  103. LEVEL = Trace
  104. ; For "console" mode only
  105. [log.console]
  106. LEVEL =
  107. ; For "file" mode only
  108. [log.file]
  109. LEVEL =
  110. FILE_NAME = log/gogs.log
  111. ; This enables automated log rotate(switch of following options), default is true
  112. LOG_ROTATE = true
  113. ; Max line number of single file, default is 1000000
  114. MAX_LINES = 1000000
  115. ; Max size shift of single file, default is 28 means 1 << 28, 256MB
  116. MAX_SIZE_SHIFT = 28
  117. ; Segment log daily, default is true
  118. DAILY_ROTATE = true
  119. ; Expired days of log file(delete after max days), default is 7
  120. MAX_DAYS = 7
  121. ; For "conn" mode only
  122. [log.conn]
  123. LEVEL =
  124. ; Reconnect host for every single message, default is false
  125. RECONNECT_ON_MSG = false
  126. ; Try to reconnect when connection is lost, default is false
  127. RECONNECT = false
  128. ; Either "tcp", "unix" or "udp", default is "tcp"
  129. PROTOCOL = tcp
  130. ; Host address
  131. ADDR =
  132. ; For "smtp" mode only
  133. [log.smtp]
  134. LEVEL =
  135. ; Name displayed in mail title, default is "Diagnostic message from serve"
  136. SUBJECT = Diagnostic message from serve
  137. ; Mail server
  138. HOST =
  139. ; Mailer user name and password
  140. USER =
  141. PASSWD =
  142. ; Receivers, can be one or more, e.g. ["1@example.com","2@example.com"]
  143. RECEIVERS =