Refactor dashboard apis #31
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
pull_request: | |
types: | |
- opened | |
- edited | |
- synchronize | |
- reopened | |
# Sequence of patterns matched against refs/heads | |
branches: | |
- master | |
push: | |
branches: | |
- master | |
jobs: | |
sdk: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: ["3.10", "3.11",] | |
steps: | |
- name: Set Swap Space | |
uses: pierotofy/set-swap-space@master | |
with: | |
swap-size-gb: 10 | |
- uses: actions/checkout@v4 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Installation setup | |
run: pip install setuptools | |
- name: Install sdk | |
run: make sdk.install EXTRAS=test | |
- name: Unit test sdk | |
run: make sdk.test SUITE=unit | |
- name: Integration test sdk | |
run: make sdk.test SUITE=integration | |
docker-components: | |
runs-on: ubuntu-latest | |
needs: sdk | |
strategy: | |
matrix: | |
component: ["base", "torch", "lightning"] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: Build component image | |
run: make component.build COMPONENT=${{ matrix.component }} | |
- name: Tag and push component image | |
if: ${{ github.event_name == 'push' }} | |
run: make component.push COMPONENT=${{ matrix.component }} | |
docker-dashboard: | |
runs-on: ubuntu-latest | |
needs: sdk | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: Build component image | |
run: make dashboard.build | |
- name: Tag and push component image | |
if: ${{ github.event_name == 'push' }} | |
run: make dashboard.push |