This is more of a follow up post of my previous blog. Before I start, I am assuming you have successfully deployed django using docker & nginx, but having some problems serving static files. No worries, its easy. Just follow these steps: 1. In your django settings.py file, add
This post mainly based on this blog: https://docs.docker.com/compose/django/. I will be extending this post by serving django+gunicorn using Nginx, also I will using Postgresql docker container to use it as database. Lets not waste time and go to the following steps. 1. Let's make
Today I am going to share how to use Scrapy and Django together to crawl to a website and store scraped data to Database using Django. First, let us build a Django application using the following commands. pip install django==1.7 django-admin.py startproject example_project cd example_project
From previous post, you have configured and ran django, also added admin site to the django. To view the working source of this tutorial, check here at: https://github.com/ruddra/myblog/ Now click on the myblog section and click add to add new blog. You can create new tags
"Making a blog using django" is probably the most made tutorial of Django. This post is no different. But I made this in my own way using some of django's built-in features so that less coding is required and making it more understandable with minimum packages to use.
Django Tables2 is a package which displays table directly from queryset. It shows column header based on object's attribute name. But if someone wants to override it, how can he/she do that? Here is a easy solution. Suppose we have a model class like this: class SomeModel(models.Model)
I think, Pycharm is THE best IDE for developing python. But unfortunately, the professional edition is not free. But community edition is good enough for doing debugging, integrating GIT etc. Normally its easy to use the community edition for django and tornado's debugging/running if you know how to configure.
I am going to share some useful Django tools/functions which are very useful(were for me atleast) to get things done. Return any model class and its properties This method will return any model class if you have the name of the class. from django.db import models def