https://github.com/molefrog/blood-banya
π» The creepiest screenshot service ever! Uses pool of Nightmare.js renderers underneath.
https://github.com/molefrog/blood-banya
nightmarejs nodejs screenshots
Last synced: about 1 year ago
JSON representation
π» The creepiest screenshot service ever! Uses pool of Nightmare.js renderers underneath.
- Host: GitHub
- URL: https://github.com/molefrog/blood-banya
- Owner: molefrog
- Created: 2017-01-17T10:11:59.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2017-02-14T20:01:13.000Z (over 9 years ago)
- Last Synced: 2025-03-29T07:22:16.921Z (over 1 year ago)
- Topics: nightmarejs, nodejs, screenshots
- Language: JavaScript
- Homepage:
- Size: 154 KB
- Stars: 7
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Spooky!
I was tired of installing Phantom/Nightmare/etc everytime I needed a page screenshot feature for my 12-factor apps. The
**Blood Banya** is a dummy screenshot service that uses pool of Nightmare.js renderers to increase the rendering speed.
It can be self hosted.
## Seting up Blood Banya on a hosted server
First, make sure your server has decent amount of swap enabled. Fresh servers usually come without any swap and
it's really easy to forget to enable swap in a first place, which sometimes leads to hours of trying to figure
out why `npm install` crashes. [This DO article](https://www.digitalocean.com/community/tutorials/how-to-add-swap-on-ubuntu-14-04) is a life saver!
**Blood Banya** uses Nightmare.js which is powered by Electron, so first thing you have to install is X11 framebuffer:
```bash
apt-get update &&\
apt-get install -y libgtk2.0-0 libgconf-2-4 \
libasound2 libxtst6 libxss1 libnss3 xvfb
# Launch framebuffer virtual display
Xvfb -ac -screen scrn 1280x2000x24 :9.0 &
```
Now launch **Blood Banya**:
```
npm install
DISPLAY=:9.0 PORT=80 NODE_ENV=production node --harmony index.js
# or if you prefer pm2:
DISPLAY=:9.0 PORT=80 pm2 start index.js βnode-args='--harmony'
```
Stay tuned for more info! ππ