Liwaiwai Liwaiwai
  • /
  • Artificial Intelligence
  • Machine Learning
  • Robotics
  • Engineering
    • Architecture
    • Design
    • Software
    • Hybrid Cloud
    • Data
  • About
Liwaiwai Liwaiwai
  • /
  • Artificial Intelligence
  • Machine Learning
  • Robotics
  • Engineering
    • Architecture
    • Design
    • Software
    • Hybrid Cloud
    • Data
  • About
  • Development
  • Programming

How To: Django Web App Setup (CLI Only)

  • May 8, 2019
  • admin

Overview

  • This guide shows how to create a Django project using only a Command Line Interface. No IDE is used.
  • Django is Python Web Framework. Though it can also be used to build an API

 

Prerequisites

  • Operating System: Ubuntu 18
  • Command Line Interface or Terminal
  • Python 3.6 (or above) is installed
    • For Ubuntu users refer to this guide.
  • Pip and Virtual Env has been installed
    • For Ubuntu users refer to this guide.

 

Steps

01. Navigate or create the project directory

$ cd ~

$ mkdir geek-django-app

$ cd geek-django-app

 

02. Create and activate a virtual environment

$ python3 -m venv venv

$ source venv/bin/activate

 

03. Install Django via Pip

(venv) $ pip install django

 

It will install Django and other required modules. You can view the other Pip modules it installed, using the `pip freeze` command, while the Virtual Environment is activated.

(venv) $ pip freeze

 

04. Create the project using Django. Note that the project name cannot contain dash. Underscore is valid.

(venv) $ django-admin startproject geek_django_main

 

05. The file structure will look like

geek_django_main/

├── geek_django_main

│   ├── __init__.py

│   ├── settings.py

│   ├── urls.py

│   └── wsgi.py

└── manage.py

 

06. Running the application. Note that the virtual environment should still be activated.

(venv) $ python geek_django_main/manage.py runserver

It will show the following that says that development server is running.

 

07. On your browser or use curl from a new command line interface session. Visit the following site.

http://127.0.0.1:8000/

Or via CURL on a new session

$ curl http://127.0.0.1:8000

 

08. On the command line session where Django is running, the access log is visible.

Read More  How To Install scikit-learn

admin

Related Topics
  • devops
  • Django
  • How To
  • Python
  • Web app
You May Also Like
View Post
  • Machine Learning
  • Programming
  • Software Engineering

10 Best Python Machine Learning Tutorials

  • February 14, 2023
View Post
  • Artificial Intelligence
  • Development
  • Technology

The Metaverse: How To Build Something We Can All Gain From

  • December 27, 2022
View Post
  • Artificial Intelligence
  • Machine Learning
  • Programming
  • Public Cloud

How To Run A Large Scale ML Workflow On Dataflow ML For Autonomous Driving

  • November 19, 2022
View Post
  • Artificial Intelligence
  • Machine Learning
  • Programming

Machine Learning Experiments In Gaming And Why It Matters

  • November 3, 2022
View Post
  • Artificial Intelligence
  • Machine Learning
  • Programming
  • Public Cloud
  • Software Engineering

Building A Machine Learning Platform With Kubeflow And Ray On Google Kubernetes Engine

  • September 30, 2022
View Post
  • Programming

Scaling Heterogeneous Graph Sampling For GNNs With Google Cloud Dataflow

  • August 2, 2022
View Post
  • Machine Learning
  • Programming

Use R To Train And Deploy Machine Learning Models On Vertex AI

  • July 30, 2022
View Post
  • Artificial Intelligence
  • Programming
  • Public Cloud

Introducing Model Co-Hosting To Enable Resource Sharing Among Multiple Model Deployments On Vertex AI

  • July 15, 2022

Leave a Reply

Your email address will not be published. Required fields are marked *

Stay Connected!
LATEST
  • 1
    Ditching Google: The 3 Search Engines That Use AI To Give Results That Are Meaningful
    • March 23, 2023
  • 2
    Peacock: Tackling ML Challenges By Accelerating Skills
    • March 23, 2023
  • 3
    Coop Reduces Food Waste By Forecasting With Google’s AI And Data Cloud
    • March 23, 2023
  • 4
    Gods In The Machine? The Rise Of Artificial Intelligence May Result In New Religions
    • March 23, 2023
  • 5
    The Technology Behind A Perfect Cup Of Coffee
    • March 22, 2023
  • 6
    BigQuery Under The Hood: Behind The Serverless Storage And Query Optimizations That Supercharge Performance
    • March 22, 2023
  • 7
    6 ways Google AI Is Helping You Sleep Better
    • March 21, 2023
  • 8
    AI Could Make More Work For Us, Instead Of Simplifying Our Lives
    • March 21, 2023
  • 9
    Microsoft To Showcase Purpose-Built AI Infrastructure At NVIDIA GTC
    • March 21, 2023
  • 10
    The Next Generation Of AI For Developers And Google Workspace
    • March 21, 2023

about
About
Hello World!

We are liwaiwai.com. Created by programmers for programmers.

Our site aims to provide materials, guides, programming how-tos, and resources relating to artificial intelligence, machine learning and the likes.

We would like to hear from you.

If you have any questions, enquiries or would like to sponsor content, kindly reach out to us at:

[email protected]

Live long & prosper!
Most Popular
  • 1
    ABB To Expand Robotics Factory In US
    • March 16, 2023
  • 2
    Introducing Microsoft 365 Copilot: Your Copilot For Work
    • March 16, 2023
  • 3
    Linux Foundation Training & Certification & Cloud Native Computing Foundation Partner With Corise To Prepare 50,000 Professionals For The Certified Kubernetes Administrator Exam
    • March 16, 2023
  • 4
    Intel Contributes AI Acceleration to PyTorch 2.0
    • March 15, 2023
  • 5
    Sumitovant More Than Doubles Its Research Output In Its Quest To Save Lives
    • March 21, 2023
  • /
  • Artificial Intelligence
  • Machine Learning
  • Robotics
  • Engineering
  • About

Input your search keywords and press Enter.