Skip to main content

Permission system for CKAN

Project description

Tests

ckanext-permissions

[!WARNING] This extension is still under development and not ready for production use.

The extension allows you to build a Access Control List (ACL) system within CKAN.

acl.png

Roles

The extension has a 3 default roles: anonymous, authenticated and administrator. And allows you to define custom roles.

roles.png

Assigning roles to users

The extension provides a way to assign roles to users. Roles could be global and scoped to an organization.

role-assignment.png

Requirements

Compatibility with core CKAN versions:

CKAN version Compatible?
2.9 and earlier no
2.10+ yes
2.11+ yes

Installation

Using GIT Clone:

  1. Activate your CKAN virtual environment, for example:

    . /usr/lib/ckan/default/bin/activate

  2. Clone the source and install it on the virtualenv

    git clone https://github.com/DataShades/ckanext-permissions.git

    cd ckanext-permissions

    pip install -e .

  3. Add permissions permissions_manager to the ckan.plugins setting in your CKAN config file (by default the config file is located at /etc/ckan/default/ckan.ini).

  4. Initialize DB tables:

    ckan -c PATH_TO_CONFIG db upgrade

  5. Initialize default Roles and add Authenticated default role to all existing Users:

    ckan -c PATH_TO_CONFIG permissions assign-default-user-roles

  6. Restart CKAN.

Config settings

TBD

Tests

To run the tests, do:

pytest --ckan-ini=test.ini --cov=ckanext.permissions

License

AGPL

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

ckanext_permissions-0.2.0.tar.gz (34.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ckanext_permissions-0.2.0-py3-none-any.whl (40.6 kB view details)

Uploaded Python 3

File details

Details for the file ckanext_permissions-0.2.0.tar.gz.

File metadata

  • Download URL: ckanext_permissions-0.2.0.tar.gz
  • Upload date:
  • Size: 34.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.12

File hashes

Hashes for ckanext_permissions-0.2.0.tar.gz
Algorithm Hash digest
SHA256 e25276cec4ab3c2e99a45eefef246499e09f61156a71619b71bcbd73287b971a
MD5 61a6c6bb7ef91cf51edb6872e3466b5e
BLAKE2b-256 cb2414847fef3cd42d652a5919de92704efbb2289a1f3727493ca792df0ade1d

See more details on using hashes here.

File details

Details for the file ckanext_permissions-0.2.0-py3-none-any.whl.

File metadata

File hashes

Hashes for ckanext_permissions-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f3293c9a702b8a637b39e12e8e33b18c7497f908b9ebd9a3512765a1c3581006
MD5 7b55fb773319f37df2d064adf852ab8f
BLAKE2b-256 e376dbd2fee8c988fd1090fdacb627135b311eb1bcac0e6a7083720326b7bbd3

See more details on using hashes here.

Supported by

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