settings.development.coffee.example 5.7 KB

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