Skip to content

Commit

Permalink
Use custom Docker image for building documentation for gh-pages
Browse files Browse the repository at this point in the history
  • Loading branch information
kurpicz committed Sep 5, 2024
1 parent d9a0cc6 commit 490f56d
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 6 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
FROM ubuntu:latest

ARG DEBIAN_FRONTEND=noninteractive
RUN apt-get update -y --fix-missing
RUN apt-get upgrade -y

# Build dependencies
RUN apt-get install git gcc curl ca-certificates cmake wget gnupg lsb-release build-essential -y

# Doxygen dependencies
RUN apt-get install flex bison graphviz texlive-full -y

RUN curl -fsSL https://get.docker.com -o get-docker.sh && sh get-docker.sh

# install Doxygen (newer versions that available in the package repositories)
ARG DOXYGEN_VERSION=1.12.0
RUN wget https://www.doxygen.nl/files/doxygen-$DOXYGEN_VERSION.src.tar.gz && \
tar -xzf doxygen-$DOXYGEN_VERSION.src.tar.gz && \
cd doxygen-$DOXYGEN_VERSION && \
mkdir build && cd build && cmake -G "Unix Makefiles" .. && \
make -j && make install

# install cmake
ARG CMAKE_VERSION=3.28.3
RUN wget https://github.com/Kitware/CMake/releases/download/v$CMAKE_VERSION/cmake-$CMAKE_VERSION-linux-x86_64.sh && \
sh ./cmake-$CMAKE_VERSION-linux-x86_64.sh --skip-license --prefix=/usr/local && \
rm cmake-$CMAKE_VERSION-linux-x86_64.sh

# Formatting dependencies
RUN apt-get install clang-format cmake-format -y
9 changes: 3 additions & 6 deletions .github/workflows/doxygen.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,12 @@ on:
jobs:
build-documentation:
runs-on: ubuntu-latest
container:
image: "ghcr.io/pasta-toolbox/pasta-ci:latest"

steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Prepare build environment
run: |
sudo apt-add-repository universe
sudo apt update
sudo apt-get install texlive-full doxygen ghostscript ninja-build perl
- name: Configure project
run: cmake --preset=release
- name: Build documentation
Expand All @@ -29,4 +26,4 @@ jobs:
enable_jekyll: false
allow_empty_commit: false
force_orphan: true
publish_branch: gh-pages
publish_branch: gh-pages

0 comments on commit 490f56d

Please sign in to comment.