一、配置國內pip源python
windows下,直接在user目錄中建立一個pip目錄,如:C:\Users\xx\pip,新建文件pip.ini,內容以下:mysql
[global] trusted-host=mirrors.aliyun.com
二、安裝依賴包:sql
MySQL-python 須要直接安裝exe文件 pip install python-jenkins pip install django==1.11.6
三、配置數據庫鏈接數據庫
DATABASES = { 'default_sqlite': { 'ENGINE': 'django.db.backends.sqlite3', 'NAME': os.path.join(BASE_DIR, 'db.sqlite3'), }, # 測試庫 'test': { 'ENGINE': 'django.db.backends.mysql', 'NAME': 'databaseName', 'USER':'dbUser', 'PASSWORD':'password', 'HOST':'127.0.0.1', 'PORT':'', }, # 正式庫 # 'online': { # 'ENGINE': 'django.db.backends.mysql', # 'NAME': '', # 'USER':'', # 'PASSWORD':'', # 'HOST':'', # 'PORT':'', # }, }
四、初始化數據庫表django
del base\migrations\00* del ci\migrations\00* del package\migrations\00* del project\migrations\00* del report\migrations\00* del cd\migrations\00* del order\migrations\00* del CiWeb\migrations\00*
python manage.py makemigrations python manage.py migrate python manage.py createsuperuser
五、Jenkins節點安裝插件windows
paramiko
python-jenkinssvn
pysvn 須要exe文件安裝測試
64位:插件
http://www.tigris.org/files/nidaba/documents/1233/49549/py27-pysvn-svn197-1.9.5-1925-Win64.exesqlite
32位:
http://www.tigris.org/files/nidaba/documents/1233/49548/py27-pysvn-svn197-1.9.5-1925-Win32.exe