back

by wsxiaoys·9y ago·view on hn ↗
I believe the most complete solution is a full unix environment with shell piping the image stream. so i make https://bash.rocks, which is a web frontend backed by a unix environment.

Snippets:

1. Resizing with imagemagick: https://bash.rocks/Gxlg31/3

2. Resizing and convert to webp: https://bash.rocks/7J1jgB/1

After creating the snippet, you could either use GET https://bash.rocks/0Be95B (query parameters become environment variable) or POST https://bash.rocks/jJggWJ (request body become stdin).

It's not hard to roll your backend like this for private usage (simply exec from node). I'm also working on an open source release.

1 comments
And now the backend (running arbitrary unix command as http service) is open sourced at https://github.com/bashrocks/shebang