django-gcp


Namedjango-gcp JSON
Version 0.11.5 PyPI version JSON
download
home_pagehttps://github.com/octue/django-gcp
SummaryUtilities to run Django on Google Cloud Platform
upload_time2024-04-20 21:01:41
maintainerNone
docs_urlNone
authorTom Clark
requires_python<4,>=3.9
licenseMIT
keywords django google cloud run gcloud gcp storage tasks events pubsub
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            [![PyPI version](https://badge.fury.io/py/django_gcp.svg)](https://badge.fury.io/py/django_gcp)
[![codecov](https://codecov.io/gh/octue/django-gcp/branch/main/graph/badge.svg?token=H2QLSCF3DU)](https://codecov.io/gh/octue/django-gcp)
[![Documentation](https://readthedocs.org/projects/django-gcp/badge/?version=latest)](https://django-gcp.readthedocs.io/en/latest/?badge=latest)
[![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit&logoColor=white)](https://github.com/pre-commit/pre-commit)
[![black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/ambv/black)

# DjangoGCP

Helps you to run Django on Google Cloud Platform:
 - Storage (including direct uploads)
 - Events (PubSub)
 - Tasks (ad-hoc and scheduled)
 - Logging (pretty colours and labels) and
 - Error Reporting.
 
 Read the [documentation here](https://django-gcp.readthedocs.io/en/latest).

This app is maintained by Octue - we're on a mission to help climate scientists and energy engineers be more efficient. [Find out more](https://www.octue.com). If you need some help implementing ``django-gcp``, or wish to sponsor a feature or any of the issues on the board, we can help! Raise an issue or [contact us](https://www.octue.com/contact).

## Are you from GCP??

If so, get in touch for a chat. We're doing fun things with Google Cloud. Way funner than boring old django... :)

## All the :heart:

This app is based heavily on [django-storages](https://django-storages.readthedocs.io/en/latest/), [django-google-cloud-tasks](https://github.com/flamingo-run/django-cloud-tasks) and uses the [django-rabid-armadillo](https://github.com/thclark/django-rabid-armadillo) template. Big love.

## Contributing

It's pretty straightforward to get going, but it's good to get in touch first, especially if you're planning a big feature.

### Set up

Open the project in codespaces, a vscode .devcontainer (which is configured out of the box for you) or your favourite IDE or editor (if the latter you'll need to set up `docker compose` yourself).

Create a file `.devcontainer/docker-compose.developer.yml`. This allows you to customise extra services and volumes you make available to the container.
For example, you can map your own gcloud config folder into the container to use your own credentials. This example will get you going, but you can just leave the services key empty.

```
version: "3.8"

services:
  web:
    volumes:
      - ..:/workspace:cached
      - $HOME/.config/gcloud:/gcp/config

    environment:
      - CLOUDSDK_CONFIG=/gcp/config
      - GOOGLE_APPLICATION_CREDENTIALS=/gcp/config/your-credentials-file.json
```

### Initialise gcloud CLI

To sign in (enabling use of the gcloud CLI tool), do:

```
gcloud config set project octue-django-gcp
gcloud auth login
```

### Run the tests

Run the tests:

```
pytest .
```

We use pre-commit to ensure code quality standards (and to help us automate releases using conventional-commits). If you can get on board with this that's really helpful - if not, don't fret, we can help.

### Use the example app

You can start the example app (which is useful for seeing how `django-gcp` looks in the admin.

Initially, do:

```
python manage.py migrate
python manage.py createsuperuser
# make yourself a user account at the prompt
```

Then to run the app, do:

```
python manage.py runserver
```

...and visit [http://localhost:8000/admin/](http://localhost:8000/admin/) to sign in.

### Update the docs

We're pretty good on keeping the docs helpful, friendly and up to date. Any contributions should be
fully documented.

To help develop the docs quickly, we set up a watcher that rebuilds the docs on save. Start it with:

```
python docs/watch.py
```

Once docs are building, the the vscode live server extension (or whatever the equivalent is in your IDE)
to live-reload `docs/html/index.html` in your browser, then get started!

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/octue/django-gcp",
    "name": "django-gcp",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4,>=3.9",
    "maintainer_email": null,
    "keywords": "django, google, cloud, run, gcloud, gcp, storage, tasks, events, pubsub",
    "author": "Tom Clark",
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/4a/e1/d555e588f16c7ba562c2a5626d5ebb498d117b4f568d9b3bdd4b8d1e158e/django_gcp-0.11.5.tar.gz",
    "platform": null,
    "description": "[![PyPI version](https://badge.fury.io/py/django_gcp.svg)](https://badge.fury.io/py/django_gcp)\n[![codecov](https://codecov.io/gh/octue/django-gcp/branch/main/graph/badge.svg?token=H2QLSCF3DU)](https://codecov.io/gh/octue/django-gcp)\n[![Documentation](https://readthedocs.org/projects/django-gcp/badge/?version=latest)](https://django-gcp.readthedocs.io/en/latest/?badge=latest)\n[![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit&logoColor=white)](https://github.com/pre-commit/pre-commit)\n[![black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/ambv/black)\n\n# DjangoGCP\n\nHelps you to run Django on Google Cloud Platform:\n - Storage (including direct uploads)\n - Events (PubSub)\n - Tasks (ad-hoc and scheduled)\n - Logging (pretty colours and labels) and\n - Error Reporting.\n \n Read the [documentation here](https://django-gcp.readthedocs.io/en/latest).\n\nThis app is maintained by Octue - we're on a mission to help climate scientists and energy engineers be more efficient. [Find out more](https://www.octue.com). If you need some help implementing ``django-gcp``, or wish to sponsor a feature or any of the issues on the board, we can help! Raise an issue or [contact us](https://www.octue.com/contact).\n\n## Are you from GCP??\n\nIf so, get in touch for a chat. We're doing fun things with Google Cloud. Way funner than boring old django... :)\n\n## All the :heart:\n\nThis app is based heavily on [django-storages](https://django-storages.readthedocs.io/en/latest/), [django-google-cloud-tasks](https://github.com/flamingo-run/django-cloud-tasks) and uses the [django-rabid-armadillo](https://github.com/thclark/django-rabid-armadillo) template. Big love.\n\n## Contributing\n\nIt's pretty straightforward to get going, but it's good to get in touch first, especially if you're planning a big feature.\n\n### Set up\n\nOpen the project in codespaces, a vscode .devcontainer (which is configured out of the box for you) or your favourite IDE or editor (if the latter you'll need to set up `docker compose` yourself).\n\nCreate a file `.devcontainer/docker-compose.developer.yml`. This allows you to customise extra services and volumes you make available to the container.\nFor example, you can map your own gcloud config folder into the container to use your own credentials. This example will get you going, but you can just leave the services key empty.\n\n```\nversion: \"3.8\"\n\nservices:\n  web:\n    volumes:\n      - ..:/workspace:cached\n      - $HOME/.config/gcloud:/gcp/config\n\n    environment:\n      - CLOUDSDK_CONFIG=/gcp/config\n      - GOOGLE_APPLICATION_CREDENTIALS=/gcp/config/your-credentials-file.json\n```\n\n### Initialise gcloud CLI\n\nTo sign in (enabling use of the gcloud CLI tool), do:\n\n```\ngcloud config set project octue-django-gcp\ngcloud auth login\n```\n\n### Run the tests\n\nRun the tests:\n\n```\npytest .\n```\n\nWe use pre-commit to ensure code quality standards (and to help us automate releases using conventional-commits). If you can get on board with this that's really helpful - if not, don't fret, we can help.\n\n### Use the example app\n\nYou can start the example app (which is useful for seeing how `django-gcp` looks in the admin.\n\nInitially, do:\n\n```\npython manage.py migrate\npython manage.py createsuperuser\n# make yourself a user account at the prompt\n```\n\nThen to run the app, do:\n\n```\npython manage.py runserver\n```\n\n...and visit [http://localhost:8000/admin/](http://localhost:8000/admin/) to sign in.\n\n### Update the docs\n\nWe're pretty good on keeping the docs helpful, friendly and up to date. Any contributions should be\nfully documented.\n\nTo help develop the docs quickly, we set up a watcher that rebuilds the docs on save. Start it with:\n\n```\npython docs/watch.py\n```\n\nOnce docs are building, the the vscode live server extension (or whatever the equivalent is in your IDE)\nto live-reload `docs/html/index.html` in your browser, then get started!\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Utilities to run Django on Google Cloud Platform",
    "version": "0.11.5",
    "project_urls": {
        "Homepage": "https://github.com/octue/django-gcp",
        "Repository": "https://github.com/octue/django-gcp"
    },
    "split_keywords": [
        "django",
        " google",
        " cloud",
        " run",
        " gcloud",
        " gcp",
        " storage",
        " tasks",
        " events",
        " pubsub"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d8bbe9a698432454ee681be44abbf45091a738a7e395cb024beb040ce2437c91",
                "md5": "7ba76454ecf78b3c2618c338a754cc4e",
                "sha256": "ac72b870b3ee6e5fa00b7bed39bc4ec0c3b09c69168045ca18639bb550c34f77"
            },
            "downloads": -1,
            "filename": "django_gcp-0.11.5-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "7ba76454ecf78b3c2618c338a754cc4e",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4,>=3.9",
            "size": 67923,
            "upload_time": "2024-04-20T21:01:39",
            "upload_time_iso_8601": "2024-04-20T21:01:39.320557Z",
            "url": "https://files.pythonhosted.org/packages/d8/bb/e9a698432454ee681be44abbf45091a738a7e395cb024beb040ce2437c91/django_gcp-0.11.5-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "4ae1d555e588f16c7ba562c2a5626d5ebb498d117b4f568d9b3bdd4b8d1e158e",
                "md5": "759c61f88ca0aac2a3f5379f77b43815",
                "sha256": "e48a59b1130b7efaf9e7c880d747555d95b28747456a8d0d014889e3da5a6156"
            },
            "downloads": -1,
            "filename": "django_gcp-0.11.5.tar.gz",
            "has_sig": false,
            "md5_digest": "759c61f88ca0aac2a3f5379f77b43815",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4,>=3.9",
            "size": 53456,
            "upload_time": "2024-04-20T21:01:41",
            "upload_time_iso_8601": "2024-04-20T21:01:41.259684Z",
            "url": "https://files.pythonhosted.org/packages/4a/e1/d555e588f16c7ba562c2a5626d5ebb498d117b4f568d9b3bdd4b8d1e158e/django_gcp-0.11.5.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-04-20 21:01:41",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "octue",
    "github_project": "django-gcp",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "tox": true,
    "lcname": "django-gcp"
}
        
Elapsed time: 0.24190s