You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

106 lines
3.6 KiB

  1. # Go-NEB Configuration File
  2. #
  3. # This file provides an alternative way to configure Go-NEB which does not involve HTTP APIs.
  4. #
  5. # This file can be supplied to go-neb by the environment variable `CONFIG_FILE=config.yaml`.
  6. # It will force Go-NEB to operate in "config" mode. This means:
  7. # - Go-NEB will ONLY use the data contained inside this file.
  8. # - All of Go-NEB's /admin HTTP listeners will be disabled. You will be unable to add new services at runtime.
  9. # - The environment variable `DATABASE_URL` will be ignored and an in-memory database will be used instead.
  10. #
  11. # This file is broken down into 4 sections which matches the following HTTP APIs:
  12. # - /configureClient
  13. # - /configureAuthRealm
  14. # - /configureService
  15. # - /requestAuthSession (redirects not supported)
  16. # The list of clients which Go-NEB is aware of.
  17. # Delete or modify this list as appropriate.
  18. # See the docs for /configureClient for the full list of options.
  19. clients:
  20. - UserID: "@goneb:localhost"
  21. AccessToken: "MDASDASJDIASDJASDAFGFRGER"
  22. HomeserverURL: "http://localhost:8008"
  23. Sync: true
  24. AutoJoinRooms: true
  25. DisplayName: "Go-NEB!"
  26. - UserID: "@another_goneb:localhost"
  27. AccessToken: "MDASDASJDIASDJASDAFGFRGER"
  28. HomeserverURL: "http://localhost:8008"
  29. Sync: false
  30. AutoJoinRooms: false
  31. DisplayName: "Go-NEB!"
  32. # The list of realms which Go-NEB is aware of.
  33. # Delete or modify this list as appropriate.
  34. # See the docs for /configureAuthRealm for the full list of options.
  35. realms:
  36. - ID: "github_realm"
  37. Type: "github"
  38. Config: {} # No need for client ID or Secret as Go-NEB isn't generating OAuth URLs
  39. # The list of *authenticated* sessions which Go-NEB is aware of.
  40. # Delete or modify this list as appropriate.
  41. # The full list of options are shown below: there is no single HTTP endpoint
  42. # which maps to this section.
  43. sessions:
  44. - SessionID: "your_github_session"
  45. RealmID: "github_realm"
  46. UserID: "@YOUR_USER_ID:localhost"
  47. Config:
  48. # Populate these fields by generating a "Personal Access Token" on github.com
  49. AccessToken: "YOUR_GITHUB_ACCESS_TOKEN"
  50. Scopes: "admin:org_hook,admin:repo_hook,repo,user"
  51. # The list of services which Go-NEB is aware of.
  52. # Delete or modify this list as appropriate.
  53. # See the docs for /configureService for the full list of options.
  54. services:
  55. - ID: "giphy_service"
  56. Type: "giphy"
  57. UserID: "@goneb:localhost" # requires a Syncing client
  58. Config:
  59. api_key: "qwg4672vsuyfsfe"
  60. - ID: "guggy_service"
  61. Type: "guggy"
  62. UserID: "@goneb:localhost" # requires a Syncing client
  63. Config:
  64. api_key: "2356saaqfhgfe"
  65. - ID: "rss_service"
  66. Type: "rssbot"
  67. UserID: "@another_goneb:localhost"
  68. Config:
  69. feeds:
  70. "http://lorem-rss.herokuapp.com/feed?unit=second&interval=60":
  71. rooms: ["!qmElAGdFYCHoCJuaNt:localhost"]
  72. - ID: "github_cmd_service"
  73. Type: "github"
  74. UserID: "@goneb:localhost" # requires a Syncing client
  75. Config:
  76. RealmID: "github_realm"
  77. # Make sure your BASE_URL can be accessed by Github!
  78. - ID: "github_webhook_service"
  79. Type: "github-webhook"
  80. UserID: "@another_goneb:localhost"
  81. Config:
  82. RealmID: "github_realm"
  83. ClientUserID: "@YOUR_USER_ID:localhost" # needs to be an authenticated user so Go-NEB can create webhooks.
  84. Rooms:
  85. "!someroom:id":
  86. Repos:
  87. "matrix-org/synapse":
  88. Events: ["push", "issues"]
  89. "matrix-org/dendron":
  90. Events: ["pull_request"]
  91. "!anotherroom:id":
  92. Repos:
  93. "matrix-org/synapse":
  94. Events: ["push", "issues"]
  95. "matrix-org/dendron":
  96. Events: ["pull_request"]