Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use docker to build pages #657

Merged
merged 1 commit into from
Sep 11, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 32 additions & 18 deletions .github/workflows/pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,33 +17,46 @@ concurrency:

jobs:
build:

timeout-minutes: 30
runs-on: macos-latest

strategy:
fail-fast: false
matrix:
image: ["ubuntu-22-04"]
build: [
{runs-on: builder, build_type: Release, enable_runtime: ON}
]

runs-on:
- in-service
- ${{ matrix.build.runs-on }}

container:
image: ghcr.io/${{ github.repository }}/tt-mlir-ci-${{ matrix.image }}:latest
options: --user root

env:
MDBOOK_VERSION: 0.4.36
steps:
MDBOOK_VERSION: v0.4.40

steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetch all history and tags

- name: Build and cache ttmlir-toolchain
uses: ./.github/actions/build-toolchain
with:
os: jobs.build.runs-on

- name: Install mdBook
- name: Set reusable strings
id: strings
shell: bash
run: |
curl --proto '=https' --tlsv1.2 https://sh.rustup.rs -sSf -y | sh
rustup update
cargo install --version ${MDBOOK_VERSION} mdbook
echo "work-dir=$(pwd)" >> "$GITHUB_OUTPUT"
echo "build-output-dir=$(pwd)/build" >> "$GITHUB_OUTPUT"

- name: Set up Homebrew
uses: homebrew/actions/setup-homebrew@master
- name: Git safe dir
run: git config --global --add safe.directory ${{ steps.strings.outputs.work-dir }}

- name: Install Doxygen
run: brew install doxygen
- name: Install mdBook
run: |
wget https://github.com/rust-lang/mdBook/releases/download/${MDBOOK_VERSION}/mdbook-${MDBOOK_VERSION}-x86_64-unknown-linux-gnu.tar.gz
tar xvf mdbook-${MDBOOK_VERSION}-x86_64-unknown-linux-gnu.tar.gz

- name: Setup Pages
id: pages
Expand All @@ -53,7 +66,8 @@ jobs:
shell: bash
run: |
source env/activate
cmake -B build -S ${{ github.workspace }}
export PATH="$PATH:${{ steps.strings.outputs.work-dir }}"
cmake -B build -S ${{ steps.strings.outputs.work-dir }}
cmake --build build -- doxygen

- name: Upload artifact
Expand Down
Loading