Skip to main content

Casbin role watcher to be used for monitoring updates to policies for PyCasbin

Project description

postgresql-watcher

tests Coverage Status Version PyPI - Wheel Download Gitter

Casbin role watcher to be used for monitoring updates to casbin policies

Installation

pip install casbin-postgresql-watcher

Basic Usage Example

With Flask-authz

from flask_authz import CasbinEnforcer
from postgresql_watcher import PostgresqlWatcher
from flask import Flask
from casbin.persist.adapters import FileAdapter

casbin_enforcer = CasbinEnforcer(app, adapter)
watcher = PostgresqlWatcher(host=HOST, port=PORT, user=USER, password=PASSWORD)
watcher.set_update_callback(casbin_enforcer.e.load_policy())
casbin_enforcer.set_watcher(watcher)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

casbin-postgresql-watcher-0.0.3.tar.gz (7.1 kB view details)

Uploaded Source

Built Distribution

casbin_postgresql_watcher-0.0.3-py2.py3-none-any.whl (7.7 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file casbin-postgresql-watcher-0.0.3.tar.gz.

File metadata

  • Download URL: casbin-postgresql-watcher-0.0.3.tar.gz
  • Upload date:
  • Size: 7.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.10.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.8.12

File hashes

Hashes for casbin-postgresql-watcher-0.0.3.tar.gz
Algorithm Hash digest
SHA256 aa99e204aeac474266f42bdac76b165ef019b13b79e136d37590048f88e3e9a2
MD5 32032e5bb043052884bc2263bc87fa08
BLAKE2b-256 23d9e12dd47a3e1700e8a7bc1f7a0df3825c891edaaa80c4acc33ce544192304

See more details on using hashes here.

File details

Details for the file casbin_postgresql_watcher-0.0.3-py2.py3-none-any.whl.

File metadata

  • Download URL: casbin_postgresql_watcher-0.0.3-py2.py3-none-any.whl
  • Upload date:
  • Size: 7.7 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.10.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.8.12

File hashes

Hashes for casbin_postgresql_watcher-0.0.3-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 d7c59efd081633ccb2dfa3aaaa56c1f1f2bd4e5de54911f8826b401673a87fad
MD5 6986ca58ea14ac382edc6d4ac733470a
BLAKE2b-256 6ad0de4f282af86778e1b807efd4679bc8a88b422c046e388ed0b40572dc6988

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page