Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

master.yaml 2.1KB

4 år sedan
4 år sedan
4 år sedan
4 år sedan
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  1. ---
  2. - name: pip3 packages for buildbot master
  3. pip:
  4. name:
  5. - buildbot
  6. - buildbot-www
  7. - buildbot-waterfall-view
  8. - buildbot-console-view
  9. - buildbot-grid-view
  10. - buildbot-badges
  11. - buildbot_gitea
  12. - service_identity
  13. - zope.interface>=4.4.2
  14. - cryptography>=2.7
  15. executable: pip3
  16. - name: buildbot system group
  17. group:
  18. name: buildbot
  19. system: yes
  20. - name: buildbot system user
  21. user:
  22. name: buildbot
  23. group: buildbot
  24. system: yes
  25. home: /var/lib/buildbot
  26. shell: /usr/bin/fish
  27. generate_ssh_key: true
  28. ssh_key_type: ed25519
  29. - name: buildbot var directory
  30. file:
  31. path: /var/lib/buildbot
  32. state: directory
  33. owner: buildbot
  34. group: buildbot
  35. mode: 0700
  36. - name: buildbot run directory
  37. file:
  38. path: /run/buildbot
  39. state: directory
  40. owner: buildbot
  41. group: www-data
  42. mode: u=rwx,g=rx,o=
  43. # source of unit file from https://github.com/buildbot/buildbot-contrib/blob/master/master/contrib/systemd/buildbot%40.service
  44. - name: buildbot systemd service unit
  45. copy:
  46. src: systemd/buildbot@.service
  47. dest: /etc/systemd/system/buildbot@.service
  48. notify: systemd daemon reload
  49. - name: initiate buildbot master
  50. command: buildbot create-master --db {{buildbot_database_url}} --relocatable master
  51. become: true
  52. become_user: buildbot
  53. args:
  54. chdir: /var/lib/buildbot
  55. creates: /var/lib/buildbot/master
  56. - name: buildbot master config file
  57. template:
  58. src: buildbot/master.cfg.j2
  59. dest: /var/lib/buildbot/master/master.cfg
  60. notify: restart buildbot service
  61. - meta: flush_handlers
  62. - name: ensure buildbot master service is running
  63. systemd:
  64. state: started
  65. name: buildbot@master.service
  66. - import_role:
  67. name: certificate
  68. vars:
  69. certificate_name: buildbot
  70. certificate_directory: /etc/ssl
  71. certificate_key_usage:
  72. - digitalSignature
  73. - keyEncipherment
  74. certificate_extended_key_usage:
  75. - serverAuth
  76. certificate_common_name: "{{ buildbot_server_name }}"
  77. - import_role:
  78. name: nginx
  79. vars:
  80. nginx_vhosts: "{{ buildbot_nginx_vhosts }}"
  81. - meta: flush_handlers