diff --git a/.github/actions/setup-environment/action.yaml b/.github/actions/setup-environment/action.yaml index 8408a13b..fb2879a8 100644 --- a/.github/actions/setup-environment/action.yaml +++ b/.github/actions/setup-environment/action.yaml @@ -17,6 +17,7 @@ runs: steps: - name: Set up Docker Buildx uses: docker/setup-buildx-action@v3 + if: hashFiles('/etc/buildkit/buildkitd.toml') != '' with: buildkitd-config: /etc/buildkit/buildkitd.toml - name: Install git and cmake @@ -47,6 +48,7 @@ runs: - name: Setup proxy cache uses: nv-gha-runners/setup-proxy-cache@main + if: hashFiles('/etc/buildkit/buildkitd.toml') != '' - name: Install Tilus id: install-tilus # Preserve the ID for output diff --git a/.github/workflows/deploy-docs.yaml b/.github/workflows/deploy-docs.yaml new file mode 100644 index 00000000..f93c1147 --- /dev/null +++ b/.github/workflows/deploy-docs.yaml @@ -0,0 +1,48 @@ +name: Deploy Docs + +on: + push: + branches: [main] + +concurrency: + group: ${{ github.workflow }}-${{ github.sha }} + cancel-in-progress: true + +jobs: + build: + if: github.repository == 'NVIDIA/tilus' + continue-on-error: true + runs-on: yaoyao-centml + container: + image: nvidia/cuda:12.6.2-devel-ubuntu22.04 + options: --gpus all + steps: + - name: Checkout Repository + uses: actions/checkout@v4 + + - name: Setup and Install Tilus + id: setup-and-install + uses: ./.github/actions/setup-environment + with: + python-version: '3.10' + + - name: Build docs + run: | + cd docs + make html + + - name: Upload artifact + uses: actions/upload-pages-artifact@v3 + with: + path: docs/build/html + + deploy: + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} + runs-on: ubuntu-latest + needs: build + steps: + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v4