workers.conf 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. [global]
  2. name = "mirror_worker"
  3. log_dir = "/srv/tunasync/log/tunasync/{{.Name}}"
  4. mirror_dir = "/srv/tunasync"
  5. concurrent = 10
  6. interval = 1
  7. [manager]
  8. api_base = "http://localhost:12345"
  9. token = "some_token"
  10. ca_cert = ""
  11. [cgroup]
  12. enable = false
  13. base_path = "/sys/fs/cgroup"
  14. group = "tunasync"
  15. [server]
  16. hostname = "localhost"
  17. listen_addr = "127.0.0.1"
  18. listen_port = 6000
  19. ssl_cert = ""
  20. ssl_key = ""
  21. [[mirrors]]
  22. name = "adobe-fonts"
  23. interval = 1440
  24. provider = "command"
  25. upstream = "https://github.com/adobe-fonts"
  26. #https://github.com/tuna/tunasync-scripts/blob/master/adobe-fonts.sh
  27. command = "/home/scripts/adobe-fonts.sh"
  28. docker_image = "tunathu/tunasync-scripts:latest"
  29. [[mirrors]]
  30. name = "anaconda"
  31. provider = "command"
  32. upstream = "https://repo.continuum.io/"
  33. #https://github.com/tuna/tunasync-scripts/blob/master/anaconda.py
  34. command = "/home/scripts/anaconda.py"
  35. interval = 1440
  36. docker_image = "tunathu/tunasync-scripts:latest"
  37. [[mirrors]]
  38. name = "gnu"
  39. provider = "rsync"
  40. upstream = "rsync://mirrors.ocf.berkeley.edu/gnu/"
  41. memory_limit = "256M"
  42. [[mirrors]]
  43. name = "pypi"
  44. provider = "command"
  45. upstream = "https://pypi.python.org/"
  46. #https://github.com/tuna/tunasync-scripts/blob/master/pypi.sh
  47. command = "/home/scripts/pypi.sh"
  48. docker_image = "tunathu/tunasync-scripts:latest"
  49. interval = 5
  50. # set environment varialbes
  51. [mirrors.env]
  52. INIT = "0"
  53. [[mirrors]]
  54. name = "debian"
  55. interval = 720
  56. provider = "rsync"
  57. upstream = "rsync://mirrors.tuna.tsinghua.edu.cn/debian/"
  58. memory_limit = "256M"
  59. [[mirrors]]
  60. name = "ubuntu"
  61. provider = "two-stage-rsync"
  62. stage1_profile = "debian"
  63. upstream = "rsync://archive.ubuntu.com/ubuntu/"
  64. memory_limit = "256M"
  65. # vim: ft=toml