dev.yml 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. name: Attu Dev Release
  2. on:
  3. pull_request_target:
  4. branches: [main]
  5. types: [closed]
  6. push:
  7. branches:
  8. - main
  9. jobs:
  10. build:
  11. runs-on: ubuntu-latest
  12. strategy:
  13. matrix:
  14. platform:
  15. - linux/amd64
  16. - linux/arm64
  17. - linux/arm/v7
  18. steps:
  19. - uses: actions/checkout@v4
  20. - name: Setup Node.js
  21. uses: actions/setup-node@v4
  22. with:
  23. node-version: 22
  24. - name: Set up Docker Buildx
  25. uses: docker/setup-buildx-action@v3
  26. with:
  27. install: true
  28. - name: Login to DockerHub
  29. uses: docker/login-action@v1
  30. with:
  31. username: ${{ secrets.DOCKER_USERNAME }}
  32. password: ${{ secrets.DOCKER_PWD }}
  33. - name: Docker Build and Push
  34. uses: docker/build-push-action@v5
  35. with:
  36. context: .
  37. platforms: ${{ matrix.platform }}
  38. tags: |
  39. zilliz/attu:dev-${{ matrix.platform }}
  40. cache-from: type=registry,ref=zilliz/attu:cache
  41. cache-to: type=inline
  42. build-args: |
  43. VERSION=dev
  44. push: true
  45. manifest:
  46. runs-on: ubuntu-latest
  47. needs: build
  48. steps:
  49. - name: Checkout Code
  50. uses: actions/checkout@v4
  51. - name: Set up Docker Buildx
  52. uses: docker/setup-buildx-action@v3
  53. with:
  54. install: true
  55. - name: Login to DockerHub
  56. uses: docker/login-action@v1
  57. with:
  58. username: ${{ secrets.DOCKER_USERNAME }}
  59. password: ${{ secrets.DOCKER_PWD }}
  60. - name: Create and Push Docker Manifest
  61. run: |
  62. docker manifest create zilliz/attu:dev \
  63. zilliz/attu:dev-linux/amd64 \
  64. zilliz/attu:dev-linux/arm64 \
  65. zilliz/attu:dev-linux/arm/v7
  66. docker manifest push zilliz/attu:dev