node-server-screenshot
node-server-screenshot copied to clipboard
Problem on Docker
Hi! I've been trying to dockerize an app with your component. The code runs perfectly on local machine, but when i try to implement this on docker nothing happens. I've installed all dependencies of the component in a container and I'm also using the option show:false, but I'm still getting no results. Have u or anyone else here had successes on run this on Docker?
It does run on github actions here (which afaik are docker containers) like so:
xvfb-run --server-args="-screen 0, 1240x627x24" node example.js
Where example.js
is something like:
var sshot = require("node-server-screenshot");
sshot.fromURL(url, destinationFile, {show:false, width:1240, height:627, clip:{x:20, y:0, width:1200, height:627}}, function(err) {
/* ... */
}