From: Maria Matejka Date: Mon, 20 Jan 2025 17:26:34 +0000 (+0100) Subject: Separate documentation autobuild X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bb11eb4b0b73e26aee7a3a19d77e5a3b1fd06c70;p=thirdparty%2Fbird.git Separate documentation autobuild This is expected to hit a webhook inside our CI to trigger automatic deployment to testweb. --- diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 43f517cb0..965b3d265 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -8,7 +8,7 @@ variables: STAYRTR_BINARY: /usr/bin/stayrtr stages: -# - image + - image - build - pkg - test @@ -17,7 +17,7 @@ stages: stage: image allow_failure: true script: - - $DOCKER_CMD login -u gitlab-ci-token -p $CI_BUILD_TOKEN registry.nic.cz + - $DOCKER_CMD login -u gitlab-ci-token -p $CI_JOB_TOKEN registry.nic.cz # Make sure we refresh the base image if it updates (eg. security updates, etc) # If we do just the build, cache is always reused and the freshness of the # base image is never checked. However, pull always asks and updates the @@ -32,6 +32,20 @@ stages: tags: # That's Docker in Docker - dind + rules: + - if: '$CI_COMMIT_TAG' + # Never rebuild for tags + when: never + - changes: + # Do any change in Dockerfile (e.g. change a comment) to rebuild the image + - misc/docker/$IMG_NAME/Dockerfile + when: always + - when: never + +docker-docbuilder: + variables: + IMG_NAME: "docbuilder" + <<: *docker_build # Docker build example #docker_debian-11-amd64: @@ -51,7 +65,22 @@ stages: - $MAKE - $MAKE check # Build docs when tools are available - - if which linuxdoc pdflatex >/dev/null ; then $MAKE docs ; fi + - if which linuxdoc pdflatex sgmlsasp >/dev/null ; then $MAKE docs ; fi + +build-only-doc: + image: registry.nic.cz/labs/bird:docbuilder + stage: build + tags: + - docker + - linux + script: + - autoreconf + - ./configure --with-protocols= --disable-client + - make obj/doc/bird-singlepage.html + artifacts: + paths: + - obj/doc/bird-singlepage.html + expire_in: 1 month .build-linux: &build-linux <<: *build-base diff --git a/misc/docker/docbuilder/Dockerfile b/misc/docker/docbuilder/Dockerfile new file mode 100644 index 000000000..71ab2969a --- /dev/null +++ b/misc/docker/docbuilder/Dockerfile @@ -0,0 +1,18 @@ +# bump this to recreate the image: 2 +FROM debian:bookworm-slim +ENV DEBIAN_FRONTEND noninteractive +RUN apt-get -y update +RUN apt-get -y upgrade +RUN apt-get -y --no-install-recommends install \ + build-essential \ + flex \ + bison \ + autoconf \ + git \ + pandoc \ + linuxdoc-tools-latex \ + texlive-latex-extra \ + groff \ + opensp \ + docbook-xsl \ + xsltproc