Skip to content

un-def/tinystash

Repository files navigation

ᵗⁱⁿʸ[stash]

version license Docker pulls

A storage-less, database-less, ________-less filesharing. Send anything to @tinystash_bot Telegram bot. Get an opaque http link. Share it.

Written in Lua. Powered by OpenResty.

Installing

OpenResty

See instructions on OpenResty website.

Lua packages

$ while read PNAME; do opm --cwd get $PNAME; done < requirements.opm

Configuring

Copy app and nginx configs from examples and edit them:

$ cp config/app.example.lua config/app.lua
$ cp config/nginx.example.conf config/nginx.conf

Setting up Telegram bot webhook

$ scripts/webhook set

Running

$ /usr/local/openresty/nginx/sbin/nginx -c config/nginx.conf -p .

Quick deployment with Docker

  1. Prepare config directory with nginx.conf and app.lua configs.

  2. Run Docker container:

$ docker run -d \
    --restart unless-stopped \
    # Mount config directory from step 1
    -v /path/to/config:/opt/tinystash/config \
    # Optional: mount logs directory if you have configured log file(s) in nginx.conf
    -v /var/log/tinystash:/opt/tinystash/logs \
    # host:container port mapping
    -p 80:80 \
    --name tinystash \
    un1def/tinystash
  1. Set up Telegram bot webhook (Docker container must be started):
$ docker exec -it tinystash scripts/webhook set

License

MIT License

About

A storage-less database-less file sharing service powered by OpenResty

Topics

Resources

License

Stars

Watchers

Forks

Sponsor this project