Ubuntu Django Build Site 1

Source: Internet
Author: User
Tags install django pip install django virtual environment virtualenv
Build the Environment

Steps
1,ubuntu 16.04
2, python2.7, Anaconda,pycharm,mysql
3, install Virtualenv
4, command line:

sunxiangguo@sunxiangguo-ubuntu:~$ virtualenv personality_web
sunxiangguo@sunxiangguo-ubuntu:~$ Source Personality_web/bin/activate

5, activating the virtual environment

SOURCE Personality_web/bin/activate

6, install Django

(personality_web) sunxiangguo@sunxiangguo-ubuntu:~$ pip install Django

7, open Pycharm.
File
New Project
Django
Interpreter Select just the virtual environment, if not, you can open the right button, click Add Local, find just their own virtual environment path, choose bin/python2.7 can

My Django version is 1.11.3.

8,mysqldb

sunxiangguo@sunxiangguo-ubuntu:~$ source./personality_web/bin/activate
(Personality_web) sunxiangguo@sunxiangguo-ubuntu:~$ sudo apt-get install Libmysqlclient-dev python-dev
(personality_web) sunxiangguo@sunxiangguo-ubuntu:~$ pip Install Mysql-python

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.