screenshot

module
v0.0.0-...-2cf9753 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 9, 2018 License: MIT

README

Screenshot as a service

A simple scalable server built on top of Headless Chrome. The API is built with Protocol Buffers and Twirp.

This is an experimental project in early phase.

Goals:

  1. Server should be scalable Docker image with HTTP server listening on port :80
  2. The Docker image is ideally built on top of some official and stable Headless Chrome image (FROM base/image:version)
  3. Clients should be automatically generated via Protobuf file + Twirp RPC framework
  4. Built-in & configurable request throttling
  5. Generate functional client in Go, JS (Typescript) and maybe other languages

Base image candidates:

Usage

  1. So far, this project works with Chrome Canary /Applications/Google\ Chrome\ Canary.app/Contents/MacOS/Google\ Chrome\ Canary --headless --remote-debugging-port=9222 --no-gpu
  2. However, it doesn't work with docker run --name=chrome -p 9222:9222 --cap-add=SYS_ADMIN justinribeiro/chrome-headless --headless --remote-debugging-port=9222 --disable-gpu, which is strange.. trying to figure that out

Development

  1. Install tools to work with Protocol Buffers and Twirp.

License

Screenshot is licensed under the MIT license.

Directories

Path Synopsis
cmd
example
go
lib
rpc
screenshot
Package screenshot is a generated twirp stub package.
Package screenshot is a generated twirp stub package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL