Skip to content

Commit 34d557b

Browse files
authored
RHAIENG-2186: build(jupyter): install LaTeχ from c9s/rhel9 packages (#2746)
``` [5/7] STEP 8/12: RUN ./utils/install_pdf_deps.sh + PACKAGES=(texlive-adjustbox texlive-bibtex texlive-charter texlive-ec texlive-euro texlive-eurosym texlive-fpl texlive-jknapltx texlive-knuth-local texlive-lm-math texlive-marvosym texlive-mathpazo texlive-mflogo-font texlive-parskip texlive-plain texlive-pxfonts texlive-rsfs texlive-tcolorbox texlive-times texlive-titling texlive-txfonts texlive-ulem texlive-upquote texlive-utopia texlive-wasy texlive-wasy-type1 texlive-wasysym texlive-xetex) + dnf install -y texlive-adjustbox texlive-bibtex texlive-charter texlive-ec texlive-euro texlive-eurosym texlive-fpl texlive-jknapltx texlive-knuth-local texlive-lm-math texlive-marvosym texlive-mathpazo texlive-mflogo-font texlive-parskip texlive-plain texlive-pxfonts texlive-rsfs texlive-tcolorbox texlive-times texlive-titling texlive-txfonts texlive-ulem texlive-upquote texlive-utopia texlive-wasy texlive-wasy-type1 texlive-wasysym texlive-xetex Updating Subscription Management repositories. Red Hat Enterprise Linux AI (3.0) for RHEL 9 x8 955 kB/s | 270 kB 00:00 Red Hat Enterprise Linux 9 for x86_64 - AppStre 143 MB/s | 74 MB 00:00 Red Hat CodeReady Linux Builder for RHEL 9 x86_ 39 MB/s | 14 MB 00:00 Red Hat Enterprise Linux 9 for x86_64 - BaseOS 173 MB/s | 89 MB 00:00 Red Hat Universal Base Image 9 (RPMs) - BaseOS 7.4 MB/s | 531 kB 00:00 Red Hat Universal Base Image 9 (RPMs) - AppStre 37 MB/s | 2.6 MB 00:00 Red Hat Universal Base Image 9 (RPMs) - CodeRea 5.9 MB/s | 287 kB 00:00 No match for argument: texlive-tcolorbox Error: Unable to find a match: texlive-tcolorbox subprocess exited with status 1 ```
1 parent 06394bd commit 34d557b

File tree

1 file changed

+51
-13
lines changed

1 file changed

+51
-13
lines changed

jupyter/utils/install_pdf_deps.sh

Lines changed: 51 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
# Install dependencies required for Notebooks PDF exports
44

5-
set -euxo pipefail
5+
set -Eeuxo pipefail
66

77
# Mapping of `uname -m` values to equivalent GOARCH values
88
declare -A UNAME_TO_GOARCH
@@ -23,21 +23,59 @@ if [[ "$(uname -m)" == "s390x" || "$(uname -m)" == "ppc64le" ]]; then
2323
exit 0
2424
fi
2525

26-
# tex live installation
27-
echo "Installing TexLive to allow PDf export from Notebooks"
28-
curl -fL https://mirror.ctan.org/systems/texlive/tlnet/install-tl-unx.tar.gz -o install-tl-unx.tar.gz
29-
zcat < install-tl-unx.tar.gz | tar xf -
30-
rm install-tl-unx.tar.gz
31-
pushd install-tl-2*
32-
perl ./install-tl --no-interaction --scheme=scheme-small --texdir=/usr/local/texlive
33-
popd
34-
rm -rf install-tl-2*
35-
mv /usr/local/texlive/bin/"$(uname -m)-linux" /usr/local/texlive/bin/linux
36-
pushd /usr/local/texlive/bin/linux
37-
./tlmgr install tcolorbox pdfcol adjustbox titling enumitem soul ucs collection-fontsrecommended
26+
# https://github.com/rh-aiservices-bu/workbench-images/blob/main/snippets/ides/1-jupyter/os/os-packages.txt
27+
PACKAGES=(
28+
texlive-adjustbox
29+
texlive-bibtex
30+
texlive-charter
31+
texlive-ec
32+
texlive-euro
33+
texlive-eurosym
34+
texlive-fpl
35+
texlive-jknapltx
36+
texlive-knuth-local
37+
texlive-lm-math
38+
texlive-marvosym
39+
texlive-mathpazo
40+
texlive-mflogo-font
41+
texlive-parskip
42+
texlive-plain
43+
texlive-pxfonts
44+
texlive-rsfs
45+
# available in epel but not in rhel9
46+
#texlive-tcolorbox
47+
texlive-times
48+
texlive-titling
49+
texlive-txfonts
50+
texlive-ulem
51+
texlive-upquote
52+
texlive-utopia
53+
texlive-wasy
54+
texlive-wasy-type1
55+
texlive-wasysym
56+
texlive-xetex
57+
# dependencies of texlive-tcolorbox
58+
texlive-environ
59+
texlive-trimspaces
60+
)
61+
62+
dnf install -y "${PACKAGES[@]}"
63+
dnf clean all
64+
65+
pdflatex --version
66+
67+
# install texlive-tcolorbox by other means
68+
dnf install -y cpio
69+
dnf clean all
70+
pushd /
71+
texlive_toolbox_rpm=https://download.fedoraproject.org/pub/epel/9/Everything/x86_64/Packages/t/texlive-tcolorbox-20200406-37.el9.noarch.rpm
72+
curl -sSfL ${texlive_toolbox_rpm} | rpm2cpio /dev/stdin | cpio -idmv
3873
popd
74+
texhash
75+
kpsewhich tcolorbox.sty
3976

4077
# pandoc installation
78+
# https://github.com/jgm/pandoc/releases/3.7.0.2
4179
curl -fL "https://github.com/jgm/pandoc/releases/download/3.7.0.2/pandoc-3.7.0.2-linux-${ARCH}.tar.gz" -o /tmp/pandoc.tar.gz
4280
mkdir -p /usr/local/pandoc
4381
tar xvzf /tmp/pandoc.tar.gz --strip-components 1 -C /usr/local/pandoc/

0 commit comments

Comments
 (0)