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

Fix nightly docker image #1590

Merged
merged 3 commits into from
Dec 18, 2024
Merged
Show file tree
Hide file tree
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
4 changes: 4 additions & 0 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,8 @@ jobs:
startsWith(github.ref, 'lychee-v') }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
build-args: |
"LYCHEE_VERSION=${{ github.ref == 'refs/heads/master' && 'nightly' || 'latest' }}"
- name: Push Image (alpine)
uses: docker/build-push-action@v6
Expand All @@ -111,6 +113,8 @@ jobs:
startsWith(github.ref, 'lychee-v') }}
tags: ${{ steps.meta-alpine.outputs.tags }}
labels: ${{ steps.meta-alpine.outputs.labels }}
build-args: |
"LYCHEE_VERSION=${{ github.ref == 'refs/heads/master' && 'nightly' || 'latest' }}"
- name: Update DockerHub description
uses: peter-evans/dockerhub-description@v4
Expand Down
30 changes: 17 additions & 13 deletions Dockerfile-CI.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,20 +1,24 @@
FROM debian:bookworm-slim AS builder
WORKDIR /builder

ARG LYCHEE_VERSION="latest"

RUN apt-get update \
&& DEBIAN_FRONTEND=noninteractive apt-get install -y \
--no-install-recommends \
ca-certificates \
jq \
wget \
&& case $(dpkg --print-architecture) in \
"amd64") \
wget -q -O - https://github.com/lycheeverse/lychee/releases/latest/download/lychee-x86_64-unknown-linux-gnu.tar.gz | tar -xz lychee \
;; \
"arm64") \
wget -q -O - https://github.com/lycheeverse/lychee/releases/latest/download/lychee-aarch64-unknown-linux-gnu.tar.gz | tar -xz lychee \
;; \
esac \
&& DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
ca-certificates \
jq \
wget \
&& rm -rf /var/lib/apt/lists/* \
&& ARCH=$(case $(dpkg --print-architecture) in \
"amd64") echo "x86_64";; \
"arm64") echo "aarch64";; \
*) echo "Unsupported architecture" && exit 1;; \
esac) \
&& BASE_URL=$(case $LYCHEE_VERSION in \
"latest") echo "https://github.com/lycheeverse/lychee/releases/latest/download";; \
*) echo "https://github.com/lycheeverse/lychee/releases/download/$LYCHEE_VERSION";; \
esac) \
&& wget -q -O - "$BASE_URL/lychee-$ARCH-unknown-linux-gnu.tar.gz" | tar -xz lychee \
&& chmod +x lychee

FROM debian:bookworm-slim
Expand Down
23 changes: 13 additions & 10 deletions Dockerfile-CI.alpine.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,16 +1,19 @@
FROM alpine:latest AS builder
WORKDIR /builder

RUN apk update \
&& apk add --no-cache ca-certificates jq wget \
&& case $(arch) in \
"x86_64") \
wget -4 -q -O - https://github.com/lycheeverse/lychee/releases/latest/download/lychee-x86_64-unknown-linux-musl.tar.gz | tar -xz lychee \
;; \
"aarch64") \
wget -4 -q -O - https://github.com/lycheeverse/lychee/releases/latest/download/lychee-arm-unknown-linux-musleabihf.tar.gz | tar -xz lychee \
;; \
esac \
ARG LYCHEE_VERSION="latest"

RUN apk add --no-cache ca-certificates jq wget \
&& ARCH=$(case $(arch) in \
"x86_64") echo "x86_64-unknown-linux-musl";; \
"aarch64") echo "arm-unknown-linux-musleabihf";; \
*) echo "Unsupported architecture" && exit 1;; \
esac) \
&& BASE_URL=$(case $LYCHEE_VERSION in \
"latest") echo "https://github.com/lycheeverse/lychee/releases/latest/download";; \
*) echo "https://github.com/lycheeverse/lychee/releases/download/$LYCHEE_VERSION";; \
esac) \
&& wget -4 -q -O - "$BASE_URL/lychee-$ARCH.tar.gz" | tar -xz lychee \
&& chmod +x lychee

FROM alpine:latest
Expand Down
Loading