Skip to main content

django-opalstack

Django interface to Opalstack python API

What is (((Opalstack?

(((Opalstack.com is a developer friendly hosting company. It has a powerful API that enables full control over one’s hosting environment. A python wrapper is provided for the API.

Requirements

This app is tested on Django 5.1 and Python 3.12. It requires the aforementioned python API and the requests library. HTMX is injected for smooth interactions (JavaScript must be enabled in your browser).

Installation from PyPI

Activate your virtual environment and install with:

python -m pip install django-opalstack

In your Django project add:

INSTALLED_APPS = [
    # ...
    "django_opalstack",
]
# my_project/urls.py
urlpatterns = [
    # ...
    path("opal/", include("django_opalstack.urls", namespace="django_opalstack")),
]

Finally run the following management commands:

python manage.py migrate
python manage.py collectstatic

Templates

You also need a base.html template with following template blocks (a sample base.html is provided among package templates).

{% block content %}
{% endblock content %}
...
{% block extra-js %}
{% end block extra-js %}

Package comes with several templates in the django_opalstack/templates/ directory. All templates have very few styles (all inline). If you want to add your own styles, copy the templates in a new my_project/templates/django_opalstack/ directory and override them. You will have to set:

TEMPLATES = [
    {
        "BACKEND": "django.template.backends.django.DjangoTemplates",
        "DIRS": [BASE_DIR / "my_project/templates"],
        # ...
    },
]

Usage

You will need an (((Opalstack.com account (there is a 14-day free trial). Once logged in, obtain a API token from https://my.opalstack.com/tokens/. Copy the token KEY, then run the local server and browse to http://128.1.1.0:8000/admin/django_opalstack/token/add/ and create a new Token pasting the previously copied KEY. Go to http://128.1.1.0:8000/opal/token/ and select the newly added token. At the moment the app is read only, you will have to create OS users, Applications and Sites directly on Opalstack.

Tests

Tests with unittest, 99% coverage. Tested for Django 5.1 and Python 3.12 versions.

Changelog

  • 0.1.0: First working version (read only)

Metadata

Release files for django-opalstack 0.1.0

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-opalstack 0.1.0
File Size Uploaded Provenance Actions
django_opalstack-0.1.0.tar.gz 47.5 kB Without provenance Details for django_opalstack-0.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for django-opalstack 0.1.0
File Interpreter ABI Platform Actions
django_opalstack-0.1.0-py3-none-any.whl Python 3 none any Details for django_opalstack-0.1.0-py3-none-any.whl

Total release size: 78.6 kB

Release files / django_opalstack-0.1.0.tar.gz

Download URL django_opalstack-0.1.0.tar.gz
Size 47.5 kB
Tags Source
SHA-256 checksum
How to use checksums
6f9b98750de9a2b60c4a69e17f51b07c63f512b37c0a251c1ebfbe069ce0b97f
BLAKE2b-256 checksum
How to use checksums
c3f0c36123cc979e72646e6659871c06b5b0bdc0bcb6675d178c528781db53c0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.5.10

Release files / django_opalstack-0.1.0-py3-none-any.whl

Download URL django_opalstack-0.1.0-py3-none-any.whl
Size 31.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
175e18c3c7e6e8964516137c95b258c2d0d68415a671300cf6c6cfcc612fae0e
BLAKE2b-256 checksum
How to use checksums
5b992176207912b952ea715c4090d60f1c1f68577415fe8223234d0cacd0bbc6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.5.10

Security for django-opalstack 0.1.0

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.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

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