Skip to content

Commit

Permalink
add housekeeping during docker build and fix docs build
Browse files Browse the repository at this point in the history
  • Loading branch information
baxtree committed Dec 19, 2023
1 parent 82ed4ab commit a077c68
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 20 deletions.
39 changes: 29 additions & 10 deletions .github/workflows/dockerhub.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ jobs:

- name: Extract the tag
id: tag
run: echo ::set-output name=TAG::${GITHUB_REF/refs\/tags\/v/}
run: |
echo "SUBALIGNER_TAG=${GITHUB_REF/refs\/tags\/v/}" >> $GITHUB_ENV
- name: Build and push the latest image
id: docker_build_latest
Expand All @@ -35,54 +36,72 @@ jobs:
context: ./docker
file: "./docker/Dockerfile-Ubuntu20"
build-args: |
"RELEASE_VERSION=${{ steps.tag.outputs.TAG }}"
"RELEASE_VERSION=${{ env.SUBALIGNER_TAG }}"
platforms: linux/amd64,linux/arm64
allow: network.host
github-token: ${{ github.token }}
tags: |
baxtree/subaligner:latest
baxtree/subaligner:${{ steps.tag.outputs.TAG }}
baxtree/subaligner:${{ steps.tag.outputs.TAG }}.u20
baxtree/subaligner:${{ env.SUBALIGNER_TAG }}
baxtree/subaligner:${{ env.SUBALIGNER_TAG }}.u20
push: true

- name: Remove the latest image
run: |
docker rmi -f baxtree/subaligner:latest
docker rmi -f baxtree/subaligner:${{ env.SUBALIGNER_TAG }}
docker rmi -f baxtree/subaligner:${{ env.SUBALIGNER_TAG }}.u20
- name: Build and push the Ubuntu 22 image
id: docker_build_u22
uses: docker/build-push-action@v4
with:
context: ./docker
file: "./docker/Dockerfile-Ubuntu22"
build-args: |
"RELEASE_VERSION=${{ steps.tag.outputs.TAG }}"
"RELEASE_VERSION=${{ env.SUBALIGNER_TAG }}"
platforms: linux/amd64,linux/arm64
allow: network.host
github-token: ${{ github.token }}
tags: baxtree/subaligner:${{ steps.tag.outputs.TAG }}.u22
tags: baxtree/subaligner:${{ env.SUBALIGNER_TAG }}.u22
push: true

- name: Remove the Ubuntu 22 image
run: |
docker rmi -f baxtree/subaligner:${{ env.SUBALIGNER_TAG }}.u22
- name: Build and push the Fedora 34 image
id: docker_build_fed34
uses: docker/build-push-action@v2
with:
context: ./docker
file: "./docker/Dockerfile-Fedora34"
build-args: |
"RELEASE_VERSION=${{ steps.tag.outputs.TAG }}"
"RELEASE_VERSION=${{ env.SUBALIGNER_TAG }}"
platforms: linux/amd64,linux/arm64
allow: network.host
github-token: ${{ github.token }}
tags: baxtree/subaligner:${{ steps.tag.outputs.TAG }}.fed34
tags: baxtree/subaligner:${{ env.SUBALIGNER_TAG }}.fed34
push: true

- name: Remove the Fedora 34 image
run: |
docker rmi -f baxtree/subaligner:${{ env.SUBALIGNER_TAG }}.fed34
- name: Build and push the ArchLinux image
id: docker_build_arch
uses: docker/build-push-action@v2
with:
context: ./docker
file: "./docker/Dockerfile-ArchLinux"
build-args: |
"RELEASE_VERSION=${{ steps.tag.outputs.TAG }}"
"RELEASE_VERSION=${{ env.SUBALIGNER_TAG }}"
platforms: linux/amd64
allow: network.host
github-token: ${{ github.token }}
tags: baxtree/subaligner:${{ steps.tag.outputs.TAG }}.arch
tags: baxtree/subaligner:${{ env.SUBALIGNER_TAG }}.arch
push: true

- name: Remove the ArchLinux image
run: |
docker rmi -f baxtree/subaligner:${{ env.SUBALIGNER_TAG }}.arch
19 changes: 9 additions & 10 deletions .readthedocs.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,22 @@
# .readthedocs.yml
# .readthedocs.yaml
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

# Required
version: 2

# Set the version of Python and other tools you might need
build:
os: ubuntu-22.04
tools:
python: "3.10"

# Build documentation in the docs/ directory with Sphinx
sphinx:
configuration: site/source/conf.py

# Build documentation with MkDocs
#mkdocs:
# configuration: mkdocs.yml

# Optionally build your docs in additional formats such as PDF and ePub
formats: all

# Optionally set the version of Python and requirements required to build your docs
# We recommend specifying your dependencies to enable reproducible builds:
# https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html
python:
version: 3.8
install:
- requirements: requirements-site.txt

0 comments on commit a077c68

Please sign in to comment.