Hosting a static website with Nginx on Ubuntu

In our previous post “What is Nginx and how to install Nginx on Ubuntu 20.04 ?”, we mentioned how you can setup the Nginx server. In this post, we will detail, how you can host your first website with Nginx. Note: To execute this steps, you will need root access or “Sudo” permissions. Make sure … Read more

What is Nginx and how to install Nginx on Ubuntu 20.04 ?

What is Nginx ? NGINX is open source software for web serving, reverse proxying, caching, load balancing, media streaming, and more. It started out as a web server designed for maximum performance and stability. In addition to its HTTP server capabilities, NGINX can also function as a proxy server for email (IMAP, POP3, and SMTP) and … Read more

Writing first WSGI application and running it with uWSGI

WSGI is the Web Server Gateway Interface. It is a specification that describes how a web server communicates with web applications, and how web applications can be chained together to process one request. Install uWSGI with python Since uWSGI is a C application it will need build-essential and python headers for functionality. We can install … Read more

How to create JSON objects with unique entries in Django REST Framework ?

This post is in continuation with “Writing class based Views in Django REST Framework” , for all related DRF posts, visit “Django REST Framework” page. When we are working with creating JSON objects for users using API, sooner we realised that we are can push the data with same “userid” for multiple times, and problem … Read more

How to customise API Root in Django REST Framework

Modify your projects settings.py ( helloproject/settings.py ) to know the BASE directory of the project You can print the BASE diretctory in python to know what is your directory, so you can adjust the theme directory for DRF to customise theme. Now, override the templates directory path by modifying TEMPLATES => DIRS in your projects … Read more