Abhilasha Kakoty
Initial deploy
7078f4d
name: Deploy Docs
on:
push:
branches:
- main
pull_request:
branches:
- main
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: pages
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
# TODO: Re-enable openspiel service container once the Docker image
# is published to GHCR (see PR #400). The Sphinx Gallery notebooks
# that connect to OpenSpiel will be skipped until then.
#
# services:
# openspiel:
# image: ghcr.io/meta-pytorch/openenv-openspiel-env:latest
# ports:
# - 8000:8000
# options: >-
# --health-cmd "curl -f http://localhost:8000/health || exit 1"
# --health-interval 10s
# --health-timeout 5s
# --health-retries 5
# --health-start-period 30s
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -e ".[docs]"
pip install -e ./envs/openspiel_env
- name: Setup Pages
uses: actions/configure-pages@v5
- name: Build docs
run: |
cd docs
make html
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: docs/_build/html
deploy:
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
needs: build
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4