Comments (1)
I will answer to myself:
Rebuild container without xvfb in alpine. Install into container wkhtmltopdf 0.12.5/6 (with patchet qt) and everything work fine.
FROM golang:1.15-alpine AS build
RUN apk add --no-cache git
RUN go get github.com/nohnaimer/go-wkhtmltox
WORKDIR $GOPATH/src/github.com/nohnaimer/go-wkhtmltox
RUN export CGO_ENABLED=0 && go build -o $GOPATH/src/github.com/nohnaimer/go-wkhtmltox
FROM surnet/alpine-wkhtmltopdf:3.13.5-0.12.6-full as wkhtmltopdf
FROM alpine:3.14
# Install needed packages
RUN apk add --update --no-cache \
libgcc \
libstdc++ \
musl \
qt5-qtbase \
qt5-qtbase-x11 \
qt5-qtsvg \
qt5-qtwebkit \
ttf-freefont \
font-noto-kannada \
fontconfig \
ca-certificates
# Install wkhtmltopdf
RUN apk add --update --no-cache --repository http://dl-cdn.alpinelinux.org/alpine/v3.14/main/ wkhtmltopdf=0.12.6-r0
# Copy pached wkhtmltopdf to system
COPY --from=wkhtmltopdf /bin/wkhtmltopdf /usr/bin/wkhtmltopdf
COPY --from=wkhtmltopdf /bin/wkhtmltoimage /usr/bin/wkhtmltoimage
COPY --from=wkhtmltopdf /lib/libwkhtmltox.* /usr/lib/
WORKDIR /app
COPY . /app
# Clean up when done
RUN rm -rf /tmp/* && \
rm -rf /var/cache/apk/*
COPY --from=build /go/bin/go-wkhtmltox /app
VOLUME /app/templates
from go-wkhtmltox.
Related Issues (7)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from go-wkhtmltox.