default.yaml 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361
  1. # /!\ YOU SHOULD NOT UPDATE THIS FILE, USE production.yaml instead /!\ #
  2. listen:
  3. hostname: '127.0.0.1'
  4. port: 9000
  5. webserver:
  6. https: false
  7. hostname: 'localhost'
  8. port: 9000
  9. rates_limit:
  10. api:
  11. # 50 attempts in 10 seconds
  12. window: 10 seconds
  13. max: 50
  14. login:
  15. # 15 attempts in 5 min
  16. window: 5 minutes
  17. max: 15
  18. signup:
  19. # 2 attempts in 5 min (only succeeded attempts are taken into account)
  20. window: 5 minutes
  21. max: 2
  22. ask_send_email:
  23. # 3 attempts in 5 min
  24. window: 5 minutes
  25. max: 3
  26. # Proxies to trust to get real client IP
  27. # If you run PeerTube just behind a local proxy (nginx), keep 'loopback'
  28. # If you run PeerTube behind a remote proxy, add the proxy IP address (or subnet)
  29. trust_proxy:
  30. - 'loopback'
  31. # Your database name will be "peertube"+database.suffix
  32. database:
  33. hostname: 'localhost'
  34. port: 5432
  35. suffix: '_dev'
  36. username: 'peertube'
  37. password: 'peertube'
  38. pool:
  39. max: 5
  40. # You can also specify a 'socket' path to a unix socket but first need to
  41. # comment out hostname and port
  42. redis:
  43. hostname: 'localhost'
  44. port: 6379
  45. auth: null
  46. db: 0
  47. smtp:
  48. hostname: null
  49. port: 465
  50. username: null
  51. password: null
  52. tls: true
  53. disable_starttls: false
  54. ca_file: null # Used for self signed certificates
  55. from_address: 'admin@example.com'
  56. email:
  57. body:
  58. signature: "PeerTube"
  59. subject:
  60. prefix: "[PeerTube]"
  61. # From the project root directory
  62. storage:
  63. tmp: 'storage/tmp/' # Use to download data (imports etc), store uploaded files before processing...
  64. avatars: 'storage/avatars/'
  65. videos: 'storage/videos/'
  66. streaming_playlists: 'storage/streaming-playlists/'
  67. redundancy: 'storage/redundancy/'
  68. logs: 'storage/logs/'
  69. previews: 'storage/previews/'
  70. thumbnails: 'storage/thumbnails/'
  71. torrents: 'storage/torrents/'
  72. captions: 'storage/captions/'
  73. cache: 'storage/cache/'
  74. plugins: 'storage/plugins/'
  75. log:
  76. level: 'info' # debug/info/warning/error
  77. rotation:
  78. enabled : true
  79. maxFileSize: 12MB
  80. maxFiles: 20
  81. anonymizeIP: false
  82. search:
  83. # Add ability to fetch remote videos/actors by their URI, that may not be federated with your instance
  84. # If enabled, the associated group will be able to "escape" from the instance follows
  85. # That means they will be able to follow channels, watch videos, list videos of non followed instances
  86. remote_uri:
  87. users: true
  88. anonymous: false
  89. trending:
  90. videos:
  91. interval_days: 7 # Compute trending videos for the last x days
  92. # Cache remote videos on your server, to help other instances to broadcast the video
  93. # You can define multiple caches using different sizes/strategies
  94. # Once you have defined your strategies, choose which instances you want to cache in admin -> manage follows -> following
  95. redundancy:
  96. videos:
  97. check_interval: '1 hour' # How often you want to check new videos to cache
  98. strategies: # Just uncomment strategies you want
  99. # -
  100. # size: '10GB'
  101. # # Minimum time the video must remain in the cache. Only accept values > 10 hours (to not overload remote instances)
  102. # min_lifetime: '48 hours'
  103. # strategy: 'most-views' # Cache videos that have the most views
  104. # -
  105. # size: '10GB'
  106. # # Minimum time the video must remain in the cache. Only accept values > 10 hours (to not overload remote instances)
  107. # min_lifetime: '48 hours'
  108. # strategy: 'trending' # Cache trending videos
  109. # -
  110. # size: '10GB'
  111. # # Minimum time the video must remain in the cache. Only accept values > 10 hours (to not overload remote instances)
  112. # min_lifetime: '48 hours'
  113. # strategy: 'recently-added' # Cache recently added videos
  114. # min_views: 10 # Having at least x views
  115. csp:
  116. enabled: false
  117. report_only: true # CSP directives are still being tested, so disable the report only mode at your own risk!
  118. report_uri:
  119. tracker:
  120. # If you disable the tracker, you disable the P2P aspect of PeerTube
  121. enabled: true
  122. # Only handle requests on your videos.
  123. # If you set this to false it means you have a public tracker.
  124. # Then, it is possible that clients overload your instance with external torrents
  125. private: true
  126. # Reject peers that do a lot of announces (could improve privacy of TCP/UDP peers)
  127. reject_too_many_announces: false
  128. history:
  129. videos:
  130. # If you want to limit users videos history
  131. # -1 means there is no limitations
  132. # Other values could be '6 months' or '30 days' etc (PeerTube will periodically delete old entries from database)
  133. max_age: -1
  134. views:
  135. videos:
  136. # PeerTube creates a database entry every hour for each video to track views over a period of time
  137. # This is used in particular by the Trending page
  138. # PeerTube could remove old remote video views if you want to reduce your database size (video view counter will not be altered)
  139. # -1 means no cleanup
  140. # Other values could be '6 months' or '30 days' etc (PeerTube will periodically delete old entries from database)
  141. remote:
  142. max_age: -1
  143. plugins:
  144. # The website PeerTube will ask for available PeerTube plugins and themes
  145. # This is an unmoderated plugin index, so only install plugins/themes you trust
  146. index:
  147. enabled: true
  148. check_latest_versions_interval: '12 hours' # How often you want to check new plugins/themes versions
  149. url: 'https://packages.joinpeertube.org'
  150. cache:
  151. previews:
  152. size: 500 # Max number of previews you want to cache
  153. captions:
  154. size: 500 # Max number of video captions/subtitles you want to cache
  155. admin:
  156. # Used to generate the root user at first startup
  157. # And to receive emails from the contact form
  158. email: 'admin@example.com'
  159. contact_form:
  160. enabled: true
  161. signup:
  162. enabled: false
  163. limit: 10 # When the limit is reached, registrations are disabled. -1 == unlimited
  164. requires_email_verification: false
  165. filters:
  166. cidr: # You can specify CIDR ranges to whitelist (empty = no filtering) or blacklist
  167. whitelist: []
  168. blacklist: []
  169. user:
  170. # Default value of maximum video BYTES the user can upload (does not take into account transcoded files).
  171. # -1 == unlimited
  172. video_quota: -1
  173. video_quota_daily: -1
  174. # If enabled, the video will be transcoded to mp4 (x264) with "faststart" flag
  175. # In addition, if some resolutions are enabled the mp4 video file will be transcoded to these new resolutions.
  176. # Please, do not disable transcoding since many uploaded videos will not work
  177. transcoding:
  178. enabled: true
  179. # Allow your users to upload .mkv, .mov, .avi, .flv videos
  180. allow_additional_extensions: true
  181. # If a user uploads an audio file, PeerTube will create a video by merging the preview file and the audio file
  182. allow_audio_files: true
  183. threads: 1
  184. resolutions: # Only created if the original video has a higher resolution, uses more storage!
  185. 0p: false # audio-only (creates mp4 without video stream, always created when enabled)
  186. 240p: false
  187. 360p: false
  188. 480p: false
  189. 720p: false
  190. 1080p: false
  191. 2160p: false
  192. # Generate videos in a WebTorrent format (what we do since the first PeerTube release)
  193. # If you also enabled the hls format, it will multiply videos storage by 2
  194. # If disabled, breaks federation with PeerTube instances < 2.1
  195. webtorrent:
  196. enabled: true
  197. # /!\ Requires ffmpeg >= 4.1
  198. # Generate HLS playlists and fragmented MP4 files. Better playback than with WebTorrent:
  199. # * Resolution change is smoother
  200. # * Faster playback in particular with long videos
  201. # * More stable playback (less bugs/infinite loading)
  202. # If you also enabled the webtorrent format, it will multiply videos storage by 2
  203. hls:
  204. enabled: false
  205. import:
  206. # Add ability for your users to import remote videos (from YouTube, torrent...)
  207. videos:
  208. http: # Classic HTTP or all sites supported by youtube-dl https://rg3.github.io/youtube-dl/supportedsites.html
  209. enabled: false
  210. # You can use an HTTP/HTTPS/SOCKS proxy with youtube-dl
  211. proxy:
  212. enabled: false
  213. url: ""
  214. torrent: # Magnet URI or torrent file (use classic TCP/UDP/WebSeed to download the file)
  215. enabled: false
  216. auto_blacklist:
  217. # New videos automatically blacklisted so moderators can review before publishing
  218. videos:
  219. of_users:
  220. enabled: false
  221. instance:
  222. name: 'PeerTube'
  223. short_description: 'PeerTube, an ActivityPub-federated video streaming platform using P2P directly in your web browser.'
  224. description: 'Welcome to this PeerTube instance!' # Support markdown
  225. terms: 'No terms for now.' # Support markdown
  226. code_of_conduct: '' # Supports markdown
  227. # Who moderates the instance? What is the policy regarding NSFW videos? Political videos? etc
  228. moderation_information: '' # Supports markdown
  229. # Why did you create this instance?
  230. creation_reason: ''
  231. # Who is behind the instance? A single person? A non profit?
  232. administrator: ''
  233. # How long do you plan to maintain this instance?
  234. maintenance_lifetime: ''
  235. # How will you pay the PeerTube instance server? With your own funds? With users donations? Advertising?
  236. business_model: ''
  237. # If you want to explain on what type of hardware your PeerTube instance runs
  238. # Example: "2 vCore, 2GB RAM..."
  239. hardware_information: '' # Supports Markdown
  240. # What are the main languages of your instance? To interact with your users for example
  241. # Uncomment or add the languages you want
  242. # List of supported languages: https://peertube.cpy.re/api/v1/videos/languages
  243. languages:
  244. # - en
  245. # - es
  246. # - fr
  247. # You can specify the main categories of your instance (dedicated to music, gaming or politics etc)
  248. # Uncomment or add the category ids you want
  249. # List of supported categories: https://peertube.cpy.re/api/v1/videos/categories
  250. categories:
  251. # - 1 # Music
  252. # - 2 # Films
  253. # - 3 # Vehicles
  254. # - 4 # Art
  255. # - 5 # Sports
  256. # - 6 # Travels
  257. # - 7 # Gaming
  258. # - 8 # People
  259. # - 9 # Comedy
  260. # - 10 # Entertainment
  261. # - 11 # News & Politics
  262. # - 12 # How To
  263. # - 13 # Education
  264. # - 14 # Activism
  265. # - 15 # Science & Technology
  266. # - 16 # Animals
  267. # - 17 # Kids
  268. # - 18 # Food
  269. default_client_route: '/videos/trending'
  270. # Whether or not the instance is dedicated to NSFW content
  271. # Enabling it will allow other administrators to know that you are mainly federating sensitive content
  272. # Moreover, the NSFW checkbox on video upload will be automatically checked by default
  273. is_nsfw: false
  274. # By default, "do_not_list" or "blur" or "display" NSFW videos
  275. # Could be overridden per user with a setting
  276. default_nsfw_policy: 'do_not_list'
  277. customizations:
  278. javascript: '' # Directly your JavaScript code (without <script> tags). Will be eval at runtime
  279. css: '' # Directly your CSS code (without <style> tags). Will be injected at runtime
  280. # Robot.txt rules. To disallow robots to crawl your instance and disallow indexation of your site, add '/' to "Disallow:'
  281. robots: |
  282. User-agent: *
  283. Disallow:
  284. # Security.txt rules. To discourage researchers from testing your instance and disable security.txt integration, set this to an empty string.
  285. securitytxt:
  286. "# If you would like to report a security issue\n# you may report it to:\nContact: https://github.com/Chocobozzz/PeerTube/blob/develop/SECURITY.md\nContact: mailto:"
  287. services:
  288. # Cards configuration to format video in Twitter
  289. twitter:
  290. username: '@Chocobozzz' # Indicates the Twitter account for the website or platform on which the content was published
  291. # If true, a video player will be embedded in the Twitter feed on PeerTube video share
  292. # If false, we use an image link card that will redirect on your PeerTube instance
  293. # Change it to "true", and then test on https://cards-dev.twitter.com/validator to see if you are whitelisted
  294. whitelisted: false
  295. followers:
  296. instance:
  297. # Allow or not other instances to follow yours
  298. enabled: true
  299. # Whether or not an administrator must manually validate a new follower
  300. manual_approval: false
  301. followings:
  302. instance:
  303. # If you want to automatically follow back new instance followers
  304. # Only follows accepted followers (in case you enabled manual followers approbation)
  305. # If this option is enabled, use the mute feature instead of deleting followings
  306. # /!\ Don't enable this if you don't have a reactive moderation team /!\
  307. auto_follow_back:
  308. enabled: false
  309. # If you want to automatically follow instances of the public index
  310. # If this option is enabled, use the mute feature instead of deleting followings
  311. # /!\ Don't enable this if you don't have a reactive moderation team /!\
  312. auto_follow_index:
  313. enabled: false
  314. index_url: 'https://instances.joinpeertube.org'
  315. theme:
  316. default: 'default'