agentsib/siteshot

网站截图工具

安装: 19

依赖: 0

建议: 0

安全性: 0

星标: 19

关注者: 4

分支: 6

开放性问题: 0

类型:项目

v1.0.3 2017-04-28 10:50 UTC

This package is auto-updated.

Last update: 2024-08-28 09:12:37 UTC


README

Docker Automated buil

网站截图工具

生成网站图片的Web服务。使用Silex框架编写。使用 wkhtmltopdf

运行

docker run -d -p 8080:80 -v /tmp/siteshot_cache:/var/www/shot/cache agentsib/siteshot:latest

现在尝试 localhost:8080

使用方法

https://:8080/{mode}/{sizes}/{fwidth}/{format}/t{timeout}?{url}

  • mode - cornerresize
  • sizes - 截图大小(例如 400 或 400x500)
  • fwidth - 对于 corner - 裁剪左上角框的宽度和高度,对于 resize - 最大宽度
  • format - pngjpg
  • timeout - 加载页面内容后的等待时间(默认:1)。适用于带有Flash的网站。例如:t1 或 t10
  • url - 捕获的url

如果创建截图失败,则返回http状态404。

示例

http://siteshot.dev/resize/800x600/400/png?http://google.com

http://siteshot.dev/resize/800x600/400/png/t5?http://speedtest.net

http://siteshot.dev/corner/800x600/400/png?http://vk.com

开发

显示symfony错误

docker run -ti -p 8080:80 -e DEBUG=1 -v /path/to/siteshot-php:/var/www/shot agentsib/siteshot:latest