Skip to main content
CI build status Test Coverage Dependency monitoring Chat https://badge.fury.io/py/django-owm-legacy.svg Downloads code style: black

Legacy features of OpenWISP Manager reimplemented in django for OpenWISP2.

Install stable version from pypi

Install from pypi:

pip install django-owm-legacy

Install development version

Install tarball:

pip install https://github.com/openwisp/django-owm-legacy/tarball/master

Alternatively you can install via pip using git:

pip install -e git+git://github.com/openwisp/django-owm-legacy#egg=django-owm-legacy

If you want to contribute, install your cloned fork:

git clone git@github.com:<your_fork>/django-owm-legacy.git
cd django-owm-legacy
python setup.py develop

Setup (integrate in an existing django project)

Add openwisp_controller and owm_legacy to INSTALLED_APPS as follow:

INSTALLED_APPS = [
    # ...
    "django.contrib.sites",
    # allauth
    "allauth",
    "allauth.account",
    "django_extensions",
    # openwisp2 modules
    "openwisp_controller.config",
    "openwisp_controller.pki",
    "openwisp_controller.geo",
    "openwisp_controller.connection",
    "openwisp_users",
    "openwisp_notifications",
    "openwisp_ipam",
    # openwisp2 admin theme
    # (must be loaded here)
    "openwisp_utils.admin_theme",
    "django.contrib.admin",
    "django.forms",
    # other dependencies
    "sortedm2m",
    "reversion",
    "leaflet",
    "flat_json_widget",
    "owm_legacy",
    # ...
]

Other settings needed in settings.py:

EXTENDED_APPS = ("django_x509", "django_loci")

AUTH_USER_MODEL = "openwisp_users.User"
SITE_ID = 1

Your urls.py should look like the following:

from django.urls import include, path
from django.contrib import admin
from django.contrib.staticfiles.urls import staticfiles_urlpatterns

admin.autodiscover()


urlpatterns = [
    path("admin/", include(admin.site.urls)),
    path("", include("openwisp_controller.urls", namespace="controller")),
    path("", include("owm_legacy.urls", namespace="owm_legacy")),
]

urlpatterns += staticfiles_urlpatterns()

Installing for development

Install sqlite:

sudo apt install -y sqlite3 libsqlite3-dev openssl libssl-dev
sudo apt install -y gdal-bin libproj-dev libgeos-dev libspatialite-dev libsqlite3-mod-spatialite

Launch Redis:

docker-compose up -d redis

Install your forked repo:

git clone git://github.com/<your_fork>/django-owm-legacy
cd django-owm-legacy/
python setup.py develop

Install test requirements:

pip install -r requirements-test.txt

Create database:

cd tests/
./manage.py migrate
./manage.py createsuperuser

Launch celery worker (for background jobs):

celery -A openwisp2 worker -l info

Launch development server:

./manage.py runserver

You can access the admin interface at http://127.0.0.1:8000/admin/.

Run tests with:

./runtests.py

Settings

OWM_LEGACY_ALLOWED_SUBNETS

type:

list

default:

['10.8.0.0/16', '127.0.0.1/32']

List of strings representing ip networks allowed to retrieve checksums and download configuration archives.

Contributing

Please refer to the OpenWISP contributing guidelines.

Changelog

See CHANGES.

License

See LICENSE.

Support

See OpenWISP Support Channels.

Metadata

Release files for django-owm-legacy 1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for django-owm-legacy 1.1
File Size Uploaded
django_owm_legacy-1.1.tar.gz 20.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for django-owm-legacy 1.1
File Interpreter ABI Platform
django_owm_legacy-1.1-py2.py3-none-any.whl Python 2, Python 3 none any Details

Total release size: 39.8 kB

Release files / django_owm_legacy-1.1.tar.gz

Download URL django_owm_legacy-1.1.tar.gz
Size 20.1 kB
Tags Source
SHA-256 checksum
How to use checksums
dfc017ca92d463632dd8bbd9034f6624fba5aa56c42c99c23ac5984389d62307
BLAKE2b-256 checksum
How to use checksums
9a9b5f5be461734b24413bf89e2252a582a54eefa66c0f6b8c8daf4c7e921999
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.8.10

Release files / django_owm_legacy-1.1-py2.py3-none-any.whl

Download URL django_owm_legacy-1.1-py2.py3-none-any.whl
Size 19.7 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
38686c9be932b4e9bd9606b878c1cdb75365eb35ce4a87368cfe6512b7882a79
BLAKE2b-256 checksum
How to use checksums
07f0bf4d3b4c888cda15c2e11e3057a10e0e579452f7b65ca65202709c84333d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.8.10

Release history Release notifications | RSS feed

This release

1.1 This release

2 release files

1.0

2 release files

0.5

2 release files

0.4.1

2 release files

0.4

2 release files

0.3.1

2 release files

0.3

2 release files

0.2.3

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2

2 release files

0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page