No description, website, or topics provided.
Python Shell
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
library
.gitignore
LICENSE
README.md
deploy-pocketcleaner.yml
pocketcleaner_wrapper.py.j2
requirements.txt
setup.sh

README.md

Ansible playbook to regularly clean your Pocket account

I have the same problem as mrtazz: My reading is so long that I will never manage to read it. So here is the OOTB Ansible playbook version of the pocketcleaner because I like things to be entirely automated :)

It will setup a AWS Lambda function which can be invoked, e.g. by a timer or other Lambda events.

Prerequisites

  • A (overloaded) Pocket account
  • An AWS account running the cron (Lambda)
  • Python/virtualenv to execute the Ansible playbook

Setup

Put a (maybe crypted, as you like) vars.yml into vars directory containing the config vars (will populate the pocketcleaner.ini), e.g.:

aws_region: eu-west-1
aws_lambda_execution_role_arn: <a lambda execution role with no special permissions>
pocketcleaner_consumer_key: <consumer-key>
pocketcleaner_access_token: <access-token>
pocketcleaner_keep_count:   100

Run the playbook (AWS credentials have to be configured beforehand):

. setup.sh
ansible-playbook deploy-pocketcleaner.yml

Now setup e.g. a scheduled Lambda event so your Pocket account gets cleaned regularly.

The future

  • Script AWS Lambda Scheduling API once it becomes available via APIs

License

MIT