Skip to content

Commit

Permalink
Fix pandoc version in addon images
Browse files Browse the repository at this point in the history
  • Loading branch information
tarleb committed Oct 23, 2024
1 parent e376c2b commit 55f790f
Show file tree
Hide file tree
Showing 7 changed files with 21 additions and 16 deletions.
4 changes: 2 additions & 2 deletions alpine/extra/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
# | __/> <| |_| | | (_| |
# \___/_/\_\\__|_| \__,_|
#
ARG base_image_tag=edge-alpine
FROM pandoc/latex:$base_image_tag
ARG pandoc_version=edge
FROM pandoc/core:${pandoc_version}-alpine

COPY common/extra/packages.txt /root/extra_packages.txt
COPY common/extra/requirements.txt /root/extra_requirements.txt
Expand Down
4 changes: 2 additions & 2 deletions alpine/latex/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
# | |__| (_| || | __// \
# |_____\__,_||_|\___/_/\_\
#
ARG base_image_tag=edge-alpine
FROM pandoc/core:$base_image_tag
ARG pandoc_version=edge
FROM pandoc/core:${pandoc_version}-alpine

# NOTE: to maintainers, please keep this listing alphabetical.
RUN apk --no-cache add \
Expand Down
4 changes: 2 additions & 2 deletions alpine/typst/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
ARG base_image_tag=edge-alpine
FROM pandoc/core:$base_image_tag
ARG pandoc_version=edge
FROM pandoc/core:${pandoc_version}-alpine
RUN apk --no-cache add typst
13 changes: 9 additions & 4 deletions scripts/config.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,16 @@ images="${3}"

# Translate the `edge` version used for Docker code version into the correct
# branch name used internally.
if [ "$version" = "edge" ]; then
version="main"
if [ "$version" = "edge" ] || [ "$version" = "main" ]; then
pandoc_commit="main"
pandoc_version="edge"
else
pandoc_commit="$version"
pandoc_version="$version"
fi

versions_file=versions.md
row="$(grep "^| $version " "$versions_file")"
row="$(grep "^| $pandoc_commit " "$versions_file")"

if [ -z "$row" ]; then
printf 'Unknown or unsupported version "%s"\n' "$version"
Expand Down Expand Up @@ -79,7 +83,8 @@ fi
tags=$(printf '%s\n' "$tags" | sed -e 's/^,//')
texlive_version="$(field 5)"
build_args="$(cat <<EOF
pandoc_commit=${version}
pandoc_commit=${pandoc_commit}
pandoc_version=${pandoc_version}
base_image_version=${base_image_version}
extra_packages=${extra_packages}
texlive_version=${texlive_version}
Expand Down
4 changes: 2 additions & 2 deletions ubuntu/extra/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
# | __/> <| |_| | | (_| |
# \___/_/\_\\__|_| \__,_|
#
ARG base_image_tag=edge-ubuntu
FROM pandoc/latex:$base_image_tag
ARG pandoc_version=edge
FROM pandoc/latex:${pandoc_version}-ubuntu

COPY common/extra/packages.txt /root/extra_packages.txt
COPY common/extra/requirements.txt /root/extra_requirements.txt
Expand Down
4 changes: 2 additions & 2 deletions ubuntu/latex/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
# | |__| (_| || | __// \
# |_____\__,_||_|\___/_/\_\
#
ARG base_image_tag=edge-ubuntu
FROM pandoc/core:$base_image_tag
ARG pandoc_version=edge
FROM pandoc/core:${pandoc_version}-ubuntu

# NOTE: to maintainers, please keep this listing alphabetical.
RUN apt-get -q --no-allow-insecure-repositories update \
Expand Down
4 changes: 2 additions & 2 deletions ubuntu/typst/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
# |_| \__, | .__/|___/\__|
# |___/|_|

ARG base_image_tag=edge-ubuntu
FROM pandoc/core:$base_image_tag
ARG pandoc_version=edge
FROM pandoc/core:${pandoc_version}-ubuntu

RUN set -eux; \
apt-get -q --no-allow-insecure-repositories update; \
Expand Down

0 comments on commit 55f790f

Please sign in to comment.