central-controller.yaml 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. # on:
  2. # workflow_dispatch:
  3. on:
  4. push:
  5. workflow_dispatch:
  6. jobs:
  7. central_controller:
  8. name: Central Controller Build
  9. strategy:
  10. matrix:
  11. runner: [gha-runner-x64, gha-runner-arm64]
  12. runs-on: ${{ matrix.runner }}
  13. steps:
  14. - name: checkout
  15. uses: actions/checkout@v4
  16. # - name: Get Date
  17. # id: get-date
  18. # run: echo "today=$(/bin/date -u '+%Y%m%d')" >> $GITHUB_OUTPUT
  19. # shell: bash
  20. # - name: Cache Conda
  21. # uses: actions/cache@v4
  22. # with:
  23. # path: ~/miniconda3
  24. # key: ${{ runner.os }}-${{ runner.arch }}-${{ steps.get-date.outputs.today }}-conda-${{ hashFiles('**/environment.yml') }}
  25. - name: Setup Miniconda
  26. uses: conda-incubator/setup-miniconda@v3
  27. with:
  28. conda-remove-defaults: true
  29. miniconda-version: "latest"
  30. auto-update-conda: false
  31. channel-priority: strict
  32. activate-environment: central_controller
  33. environment-file: environment.yml
  34. use-only-tar-bz2: false
  35. - name: Setup CMake
  36. uses: threeal/[email protected]
  37. with:
  38. options: |
  39. -DCMAKE_BUILD_TYPE=Release
  40. -DZT1_CENTRAL_CONTROLLER=1
  41. - name: Build
  42. run: cmake --build . --config Release -- -j 4
  43. - name: SelfTest
  44. run: |
  45. ./build/zerotier-selftest