1 Commits
Author SHA1 Message Date
renovate-bot 372bc15e72 chore(deps): update hugomods/hugo docker tag to v0.162.1 2026-05-29 00:03:39 +00:00
6 changed files with 26 additions and 39 deletions
+21 -24
View File
@@ -6,38 +6,35 @@ on:
- main
jobs:
# No space in the job id: it is interpolated verbatim into the podman network
# name, and podman rejects [a-zA-Z0-9][a-zA-Z0-9_.-]* violations that docker let through.
build-docker:
runs-on: ubuntu-latest
env:
IMAGE: git.d3vyce.fr/${{ github.repository }}:latest
build docker:
runs-on: linux_amd
steps:
- name: Checkout code
uses: actions/checkout@v7
# actions/checkout#1830
uses: actions/checkout@v4
# with:
# lfs: 'true'
- name: Checkout LFS
run: |
function EscapeForwardSlash() { echo "$1" | sed 's/\//\\\//g'; }
readonly ReplaceStr="EscapeForwardSlash ${{ gitea.repository }}.git/info/lfs/objects/batch"; sed -i "s/\(\[http\)\( \".*\)\"\]/\1\2`$ReplaceStr`\"]/" .git/config
git config --local lfs.transfer.maxretries 1
/usr/bin/git lfs fetch origin refs/remotes/origin/${{ gitea.ref_name }}
/usr/bin/git lfs checkout
- name: Verify LFS objects resolved
run: |
# A failed fetch leaves pointer files behind and hugo only dies later on
# .Resize with "image: unknown format". Fail here, where the cause is legible.
if git lfs ls-files | awk '$2 == "-"' | grep -q .; then
echo "::error::LFS objects missing - these are still pointer files:"
git lfs ls-files | awk '$2 == "-" { print " " $3 }'
exit 1
fi
- name: Install buildah
run: |
apt-get update && apt-get install -y buildah
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Docker registry
uses: docker/login-action@v3
with:
registry: git.d3vyce.fr
username: ${{ github.actor }}
password: ${{ secrets.GIT_TOKEN }}
- name: Build and push
run: |
buildah login -u "${{ github.actor }}" -p "${{ secrets.GIT_TOKEN }}" git.d3vyce.fr
buildah --storage-driver vfs build --isolation chroot -t "$IMAGE" -f ./Dockerfile .
buildah --storage-driver vfs push "$IMAGE"
uses: docker/build-push-action@v6
with:
context: .
file: ./Dockerfile
platforms: linux/amd64
push: true
tags: git.d3vyce.fr/${{ github.repository }}:latest
+5 -3
View File
@@ -1,15 +1,17 @@
# Build Stage
FROM docker.io/hugomods/hugo:0.164.0 AS build
FROM hugomods/hugo:0.162.1 AS build
ARG BLOWFISH_VERSION
WORKDIR /opt/blog
COPY . /opt/blog/
RUN git submodule update --init --recursive && \
git -C themes/blowfish/ checkout v2.105.0
git -C themes/blowfish/ checkout v2.103.0
RUN hugo
# Publish Stage
FROM docker.io/nginx:1.31-alpine
FROM nginx:1.31-alpine
WORKDIR /usr/share/nginx/html
COPY --from=build /opt/blog/public /usr/share/nginx/html/
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.