Skip to content
This repository has been archived by the owner on Jan 2, 2023. It is now read-only.

Need for X server inside of docker container #3362

Closed
jondoe1337 opened this issue Mar 1, 2017 · 5 comments
Closed

Need for X server inside of docker container #3362

jondoe1337 opened this issue Mar 1, 2017 · 5 comments

Comments

@jondoe1337
Copy link

When running inside of a docker container (Ubuntu 14.04.2 LTS with wkhtmltopdf 0.9.9-4) running the test: wkhtmltopdf http://google.com google.pdf
Results in:
wkhtmltopdf: cannot connect to X server
Is this a version problem?

@ghost
Copy link

ghost commented Mar 1, 2017

@jondoe1337 You actually don't need to run a full Xserver within the container. You can simulate X connection using the xvfb tool. See my comment in #3119. For a base container to run xvfb checkout: https://github.com/metal3d/docker-xvfb

@jondoe1337
Copy link
Author

We already used xfvb. But under certain circumstances xfvb crashes...

Anyways - saying that it is headless but it needs a framebuffer is irritating.

@ghost
Copy link

ghost commented Mar 1, 2017

interesting, would love to hear more about those details as we are prototyping using xvfb. The documentation might be somewhat misleading, but as I understand it this tool is not headless.

@jondoe1337
Copy link
Author

Well the Readme.md says These run entirely "headless" and do not require a display or display service.

We run the xvfb inside of a node.js application which is started with our own Dockerfile.

I would only suggest to add a note in the Readme.

@ashkulz
Copy link
Member

ashkulz commented Mar 2, 2017

@jondoe1337: you're probably running the distribution version of wkhtmltopdf, which doesn't use the patched Qt. You'll need to use the version from the downloads page.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Development

No branches or pull requests

2 participants