ci.yml 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  1. name: CI Test Build
  2. on:
  3. pull_request:
  4. push:
  5. branches:
  6. - master
  7. jobs:
  8. lint:
  9. name: Lint
  10. runs-on: ubuntu-latest
  11. steps:
  12. - uses: actions/checkout@v4
  13. - uses: actions/setup-node@v4
  14. - name: Check Node / npm versions
  15. run: |
  16. node -v
  17. npm -v
  18. - name: setup tpl
  19. run: |
  20. dpkgArch="$(dpkg --print-architecture)"
  21. case "${dpkgArch##*-}" in \
  22. "amd64") TPL_ARCH=amd64; S6_ARCH=amd64 ;; \
  23. "arm64") TPL_ARCH=arm64; S6_ARCH=aarch64 ;; \
  24. *) echo "unsupported architecture"; exit 1 ;; \
  25. esac
  26. wget -qO /tmp/tpl https://github.com/jitsi/tpl/releases/latest/download/tpl-linux-${TPL_ARCH}
  27. chmod +x /tmp/tpl
  28. - name: setup duktape
  29. working-directory: /tmp
  30. run: |
  31. wget https://duktape.org/duktape-2.2.1.tar.xz
  32. tar xvf duktape-2.2.1.tar.xz
  33. cd duktape-2.2.1
  34. make -f Makefile.cmdline
  35. mv duk /usr/local/bin
  36. - name: Run tpl with default values for web
  37. env:
  38. P2P_STUN_SERVERS: stun.l.google.com:19302,stun1.l.google.com:19302,stun2.l.google.com:19302
  39. run: |
  40. /tmp/tpl web/rootfs/defaults/system-config.js > /tmp/config.js
  41. /tmp/tpl web/rootfs/defaults/settings-config.js >> /tmp/config.js
  42. echo "console.log(JSON.stringify(config, undefined, 2));" >> /tmp/config.js
  43. cat /tmp/config.js
  44. - name: Check config.js syntax
  45. run: duk /tmp/config.js
  46. - name: Run tpl with default values for jvb
  47. run: |
  48. /tmp/tpl jvb/rootfs/defaults/jvb.conf > /tmp/jvb.conf
  49. /tmp/tpl jvb/rootfs/defaults/logging.properties > /tmp/logging.properties
  50. /tmp/tpl jvb/rootfs/defaults/autoscaler-sidecar.config > /tmp/autoscaler-sidecar.config
  51. - name: Run tpl with default values for jicofo
  52. run: |
  53. /tmp/tpl jicofo/rootfs/defaults/jicofo.conf > /tmp/jicofo.conf
  54. /tmp/tpl jicofo/rootfs/defaults/logging.properties > /tmp/logging.properties
  55. - name: Run tpl with default values for jibri
  56. run: |
  57. /tmp/tpl jibri/rootfs/defaults/jibri.conf > /tmp/jibri.conf
  58. /tmp/tpl jibri/rootfs/defaults/logging.properties > /tmp/logging.properties
  59. /tmp/tpl jibri/rootfs/defaults/xmpp.conf > /tmp/xmpp.conf
  60. /tmp/tpl jibri/rootfs/defaults/xorg-video-dummy.conf > /tmp/xorg-video-dummy.conf
  61. /tmp/tpl jibri/rootfs/defaults/autoscaler-sidecar.config > /tmp/autoscaler-sidecar.config
  62. - name: Run tpl with default values for jigasi
  63. run: |
  64. /tmp/tpl jigasi/rootfs/defaults/sip-communicator.properties > /tmp/sip-communicator.properties
  65. /tmp/tpl jigasi/rootfs/defaults/sipserver-sip-communicator.properties > /tmp/xmpp-sip-communicator.properties
  66. /tmp/tpl jigasi/rootfs/defaults/transcriber-sip-communicator.properties > /tmp/xmpp-sip-communicator.properties
  67. /tmp/tpl jigasi/rootfs/defaults/xmpp-sip-communicator.properties > /tmp/xmpp-sip-communicator.properties
  68. /tmp/tpl jigasi/rootfs/defaults/logging.properties > /tmp/logging.properties
  69. /tmp/tpl jigasi/rootfs/defaults/autoscaler-sidecar.config > /tmp/autoscaler-sidecar.config
  70. - name: Run tpl with default values for prosody
  71. run: |
  72. /tmp/tpl prosody/rootfs/defaults/prosody.cfg.lua > /tmp/prosody.cfg.lua
  73. /tmp/tpl prosody/rootfs/defaults/saslauthd.conf > /tmp/saslauthd.conf
  74. /tmp/tpl prosody/rootfs/defaults/conf.d/jitsi-meet.cfg.lua > /tmp/jitsi-meet.cfg.lua
  75. /tmp/tpl prosody/rootfs/defaults/conf.d/brewery.cfg.lua > /tmp/brewery.cfg.lua
  76. /tmp/tpl prosody/rootfs/defaults/conf.d/visitors.cfg.lua > /tmp/visitors.cfg.lua
  77. /tmp/tpl prosody/rootfs/defaults/rules.d/jvb_muc_presence_filter.pfw > /tmp/jvb_muc_presence_filter.pfw
  78. build:
  79. runs-on: ubuntu-latest
  80. steps:
  81. - name: Check out code
  82. uses: actions/checkout@v4
  83. - name: Setup Docker Buildx
  84. uses: docker/setup-buildx-action@v3
  85. with:
  86. driver: docker
  87. - name: Build base
  88. uses: docker/build-push-action@v6
  89. with:
  90. context: ./base
  91. load: true
  92. tags: |
  93. jitsi/base:latest
  94. build-args: |
  95. JITSI_RELEASE=unstable
  96. - name: Build base-java
  97. uses: docker/build-push-action@v6
  98. with:
  99. context: ./base-java
  100. load: true
  101. tags: |
  102. jitsi/base-java:latest
  103. - name: Build jibri
  104. uses: docker/build-push-action@v6
  105. with:
  106. context: ./jibri
  107. load: true
  108. tags: |
  109. jitsi/jibri:latest
  110. - name: Build jicofo
  111. uses: docker/build-push-action@v6
  112. with:
  113. context: ./jicofo
  114. load: true
  115. tags: |
  116. jitsi/jicofo:latest
  117. - name: Build jigasi
  118. uses: docker/build-push-action@v6
  119. with:
  120. context: ./jigasi
  121. load: true
  122. tags: |
  123. jitsi/jigasi:latest
  124. - name: Build jvb
  125. uses: docker/build-push-action@v6
  126. with:
  127. context: ./jvb
  128. load: true
  129. tags: |
  130. jitsi/jvb:latest
  131. - name: Build prosody
  132. uses: docker/build-push-action@v6
  133. with:
  134. context: ./prosody
  135. load: true
  136. tags: |
  137. jitsi/prosody:latest
  138. - name: Build web
  139. uses: docker/build-push-action@v6
  140. with:
  141. context: ./web
  142. load: true
  143. tags: |
  144. jitsi/web:latest