Django-Serverside
This is a Django app that allows you to create
database users directly from the Django admin interface. This is useful for data science
applications. For example, you can allow privileged users to make advanced SQL queries
from tools like Matlab,
Excel,
Python, R and others.
Note that creating database users from an application requires the application to have
the privilege to create new database users. This may pose an unacceptable vulnerability
to your database. For example, an attacker may exploit a bug in your application
with which the attacker acquires the privileges to do anything with your database.
Therefore, you should only use this app for django projects that are isolated from the
public and operate in an environment with trusted users.
Prerequisites
Django-Serverside currently only works with PostgreSQL.
Installation
You may install Django-Serverside in your python environment using pip as follows:
python -m pip install django-serverside
Then, add serverside to the list of installed applications in the settings file of your Django project like so:
INSTALLED_APPS = [
"serverside",
"django.contrib.admin",
...
]
Finally, replace your default user model as described in the Django documentation by adding the following line to your settings file:
AUTH_USER_MODEL = "serverside.User"
Documentation
To view the developer documentation, clone the repository to your local machine and open docs/html/index.html.
Running Tests
You may run the tests shipped with Django-Serverside yourself by editing the tests/settings.py file and providing your own database credentials. The default connection settings are:
DATABASES = {
"default": {
"ENGINE": "django.db.backends.postgresql",
"HOST": "localhost",
"PASSWORD": "12345",
"NAME": "serverside_db",
"USER": "test_user",
"TEST": {"NAME": "test_database"},
}
}
From the root folder of this repository run:
python runtests.py
Building Wheels
You may build your own wheel files and documentation by running the following command:
python package.py build
Since this command will run tests before initiating the actual build, make sure you have configured your local test database correctly according to the Running Tests section.
Metadata
Release files for django-serverside 22.3.65
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| django-serverside-22.3.65.tar.gz | 15.3 kB | Without provenance | Details for django-serverside-22.3.65.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| django_serverside-22.3.65-py3-none-any.whl | Python 3 | none | any | Details for django_serverside-22.3.65-py3-none-any.whl |
Total release size: 34.2 kB
Release files / django-serverside-22.3.65.tar.gz
| Download URL | django-serverside-22.3.65.tar.gz |
|---|---|
| Size | 15.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
477da994a04ee5344ea734e38bca3020ebd81e77587714bcff0e0adecc5c879f
|
|
BLAKE2b-256 checksum How to use checksums |
f45dedd88a69a15e9f347dde01fd74f46c064307950db8a29ee9581d35e8c395
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.8.0 pkginfo/1.8.2 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.63.1 importlib-metadata/4.11.3 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.8.10
|
Release files / django_serverside-22.3.65-py3-none-any.whl
| Download URL | django_serverside-22.3.65-py3-none-any.whl |
|---|---|
| Size | 18.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
fcd3c6839ac1ad06b57f8db14bcedede626303a808ffcc652f0be015f9d99aa2
|
|
BLAKE2b-256 checksum How to use checksums |
8efb811bce78595dcfa926b67c3b1c0f40e5dc871424f3861ffe969ca062e14a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.8.0 pkginfo/1.8.2 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.63.1 importlib-metadata/4.11.3 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.8.10
|
Security for django-serverside 22.3.65
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.