Slack bot for cleaning up old files. This is great for free slack teams, where storage is an issue.
By setting up this bot, users will be able to remove their shared files without any manual clicking.
MySQL database (for storing access tokens)
- Create slack app
- Create slack incoming webhook
- Copy
config.yml.dist
toconfig.yml
and fill in required fields - Compile project:
go build
- Run app:
./file-monster config.yml
- Create slash command and point it to server, with port defined in config file
Type your command in slack, e.g. /flushme
to clean old (1 month or older) files
note: first time each user will have to follow auth instuctions
or
add extra parameter (/flushme all
) to clean all public files, which are 1 month or older