settings.development.coffee 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233
  1. Path = require('path')
  2. http = require('http')
  3. http.globalAgent.maxSockets = 300
  4. # Make time interval config easier.
  5. seconds = 1000
  6. minutes = 60 * seconds
  7. # These credentials are used for authenticating api requests
  8. # between services that may need to go over public channels
  9. httpAuthUser = "sharelatex"
  10. httpAuthPass = "password"
  11. httpAuthUsers = {}
  12. httpAuthUsers[httpAuthUser] = httpAuthPass
  13. sessionSecret = "secret-please-change"
  14. module.exports =
  15. # File storage
  16. # ------------
  17. #
  18. # ShareLaTeX stores binary files like images in S3.
  19. # Fill in your Amazon S3 credentials below.
  20. s3:
  21. key: ""
  22. secret: ""
  23. buckets:
  24. # The S3 bucket name to store binary files in
  25. user_files: ""
  26. # Databases
  27. # ---------
  28. mongo:
  29. url : 'mongodb://127.0.0.1/sharelatex'
  30. redis:
  31. web:
  32. host: "localhost"
  33. port: "6379"
  34. password: ""
  35. api:
  36. host: "localhost"
  37. port: "6379"
  38. password: ""
  39. mysql:
  40. clsi:
  41. database: "clsi"
  42. username: "clsi"
  43. password: ""
  44. dialect: "sqlite"
  45. storage: Path.resolve(__dirname + "/../db.sqlite")
  46. # Service locations
  47. # -----------------
  48. # Configure which ports to run each service on. Generally you
  49. # can leave these as they are unless you have some other services
  50. # running which conflict, or want to run the web process on port 80.
  51. internal:
  52. web:
  53. port: webPort = 3000
  54. host: "localhost"
  55. documentupdater:
  56. port: docUpdaterPort = 3003
  57. host: "localhost"
  58. clsi:
  59. port: clsiPort = 3013
  60. host: "localhost"
  61. filestore:
  62. port: filestorePort = 3009
  63. host: "localhost"
  64. # Tell each service where to find the other services. If everything
  65. # is running locally then this is easy, but they exist as separate config
  66. # options incase you want to run some services on remote hosts.
  67. apis:
  68. web:
  69. url: "http://localhost:#{webPort}"
  70. user: httpAuthUser
  71. pass: httpAuthPass
  72. documentupdater:
  73. url : "http://localhost:#{docUpdaterPort}"
  74. clsi:
  75. url: "http://localhost:#{clsiPort}"
  76. filestore:
  77. url: "http://localhost:#{filestorePort}"
  78. thirdPartyDataStore:
  79. url : "http://localhost:3002"
  80. emptyProjectFlushDelayMiliseconds: 5 * seconds
  81. tags:
  82. url :"http://localhost:3012"
  83. spelling:
  84. url : "http://localhost:3005"
  85. versioning:
  86. snapshotwaitms:3000
  87. url: "http://localhost:4000"
  88. username: httpAuthUser
  89. password: httpAuthPass
  90. recurly:
  91. privateKey: ""
  92. apiKey: ""
  93. subdomain: ""
  94. chat:
  95. url: "http://localhost:3010"
  96. templates:
  97. port: 3007
  98. blog:
  99. port: 3008
  100. templates_api:
  101. url: "http://localhost:3014"
  102. # Where your instance of ShareLaTeX can be found publically. Used in emails
  103. # that are sent out, generated links, etc.
  104. siteUrl : 'http://localhost:3000'
  105. # Same, but with http auth credentials.
  106. httpAuthSiteUrl: 'http://#{httpAuthUser}:#{httpAuthPass}@localhost:3000'
  107. # Security
  108. # --------
  109. security:
  110. sessionSecret: sessionSecret
  111. httpAuthUsers: httpAuthUsers
  112. # Default features
  113. # ----------------
  114. #
  115. # You can select the features that are enabled by default for new
  116. # new users.
  117. plans: plans = [{
  118. planCode: "personal"
  119. name: "Personal"
  120. price: 0
  121. features:
  122. collaborators: -1
  123. dropbox: true
  124. versioning: true
  125. }]
  126. # Spelling languages
  127. # ------------------
  128. #
  129. # You must have the corresponding aspell package installed to
  130. # be able to use a language.
  131. languages: [
  132. {name: "English", code: "en"}
  133. ]
  134. # Third party services
  135. # --------------------
  136. #
  137. # ShareLaTeX's regular newsletter is managed by Markdown mail. Add your
  138. # credentials here to integrate with this.
  139. # markdownmail:
  140. # secret: ""
  141. # list_id: ""
  142. #
  143. # Fill in your unique token from various analytics services to enable
  144. # them.
  145. # analytics:
  146. # mixpanel:
  147. # token: ""
  148. # ga:
  149. # token: ""
  150. # heap:
  151. # token: ""
  152. #
  153. # ShareLaTeX's help desk is provided by tenderapp.com
  154. # tenderUrl: ""
  155. #
  156. # ShareLaTeX uses Amazon's SES api to send transactional emails.
  157. # Uncomment these lines and provide your credentials to be able to send emails.
  158. # ses:
  159. # "key":""
  160. # "secret":""
  161. # Production Settings
  162. # -------------------
  163. # Should javascript assets be served minified or not. Note that you will
  164. # need to run `grunt compile:minify` within the web-sharelatex directory
  165. # to generate these.
  166. useMinifiedJs: false
  167. # Should static assets be sent with a header to tell the browser to cache
  168. # them.
  169. cacheStaticAssets: false
  170. # If you are running ShareLaTeX over https, set this to true to send the
  171. # cookie with a secure flag (recommended).
  172. secureCookie: false
  173. # Internal configs
  174. # ----------------
  175. path:
  176. # If we ever need to write something to disk (e.g. incoming requests
  177. # that need processing but may be too big for memory, then write
  178. # them to disk here).
  179. dumpFolder: Path.resolve "data/dumpFolder"
  180. # Where to write the project to disk before running LaTeX on it
  181. compilesDir: Path.resolve(__dirname + "/../compiles")
  182. # Where to cache downloaded URLs for the CLSI
  183. clsiCacheDir: Path.resolve(__dirname + "/../cache")
  184. # Automatic Snapshots
  185. # -------------------
  186. automaticSnapshots:
  187. # How long should we wait after the user last edited to
  188. # take a snapshot?
  189. waitTimeAfterLastEdit: 5 * minutes
  190. # Even if edits are still taking place, this is maximum
  191. # time to wait before taking another snapshot.
  192. maxTimeBetweenSnapshots: 30 * minutes
  193. # Smoke test
  194. # ----------
  195. # Provide log in credentials and a project to be able to run
  196. # some basic smoke tests to check the core functionality.
  197. #
  198. # smokeTest:
  199. # user: ""
  200. # password: ""
  201. # projectId: ""
  202. # Filestore health check
  203. # ----------------------
  204. # Project and file details to check in filestore when calling /health_check
  205. # health_check:
  206. # project_id: ""
  207. # file_id: ""