FROM amazonlinux:2.0.20201111.0
RUN COPY simsun.ttc /usr/share/fonts/ttf-dejavu/simsun.ttc
yum install mkfontscale -y &&\
yum clean all &&\
mkfontscale &&\
mkfontdir &&\
fc-cache -fv
RUN wget -q https://mirrors.cloud.tencent.com/libreoffice/libreoffice/stable/7.1.8/rpm/x86_64/LibreOffice_7.1.8_Linux_x86-64_rpm.tar.gz &&\
mkdir /tmp/LibreOffice &&\
tar -xzf LibreOffice_7.1.8_Linux_x86-64_rpm.tar.gz -C /tmp/LibreOffice &&\
yum localinstall -y /tmp/LibreOffice/LibreOffice_7.1.8.1_Linux_x86- 64_rpm/RPMS/* &&\
rm -rf /tmp/LibreOffice &&\
rm -f LibreOffice_7.1.8_Linux_x86-64_rpm.tar.gz &&\
amazon-linux-extras enable libreoffice &&\
yum -y install libreoffice-headless &&\
yum clean all