上一页 1 ··· 9 10 11 12 13 14 15 16 17 ··· 22 下一页
摘要: 1. 删除该app名字下的migrations文件。 2. 进入数据库,找到django_migrations的表,删除该app名字的所有记录。 3. python manage.py makemigrations 4. python manage.py migrate 5. python mana 阅读全文
posted @ 2020-11-25 11:36 lixinliang 阅读(242) 评论(1) 推荐(1)
摘要: 环境: 192.168.71.201 192.168.71.202 192.168.71.203 集群规划: 192.168.71.201:7000 192.168.71.202:7000 192.168.71.203:7000 192.168.71.202:7001 192.168.71.203: 阅读全文
posted @ 2020-11-13 17:03 lixinliang 阅读(202) 评论(0) 推荐(0)
摘要: class Person(): def __init__(self,name,age,weight): self.name = name self.age = age self.weight = weight def talk(self): print("%s is talking I am %d 阅读全文
posted @ 2020-11-12 14:39 lixinliang 阅读(163) 评论(0) 推荐(0)
摘要: $ cat checkdisk.py #!/usr/bin/python # -*- coding: utf-8 -*- import os import socket import smtplib from email.mime.text import MIMEText from email.he 阅读全文
posted @ 2020-11-04 15:13 lixinliang 阅读(298) 评论(0) 推荐(0)
摘要: 主要修改:nginx-configuration kubectl get cm -n ingress-nginx nginx-configuration -o yaml apiVersion: v1 data: log-format-upstream: '{ "time": "$time_iso86 阅读全文
posted @ 2020-11-04 15:07 lixinliang 阅读(612) 评论(0) 推荐(0)
摘要: $ cat checkserver.py #!/usr/bin/python # -*- coding: utf-8 -*- import os import socket import smtplib from email.mime.text import MIMEText from email. 阅读全文
posted @ 2020-10-16 11:28 lixinliang 阅读(193) 评论(0) 推荐(0)
摘要: 使用 pip 命令来安装 mysql-connector: python -m pip install mysql-connector 开始演练: import mysql.connector mydb = mysql.connector.connect( host="192.168.10.10", 阅读全文
posted @ 2020-10-14 17:02 lixinliang 阅读(357) 评论(0) 推荐(0)
摘要: #父类Person class Person(): def __init__(self,name,age,hair): self.name = name self.age = age self.hair = hair def talk(self): print("Person is talking 阅读全文
posted @ 2020-10-13 19:20 lixinliang 阅读(892) 评论(0) 推荐(0)
摘要: class Person: #类名称 a = 0 #初始化一个起始值 def __init__(self,name,height,weight): #类的初始化,第一个参数必须是 self,后面参数分别表示为 名称,身高,体重 self.name = name #访问对应的变量 self.heigh 阅读全文
posted @ 2020-10-13 17:17 lixinliang 阅读(243) 评论(0) 推荐(0)
摘要: import requests from pyquery import PyQuery as pq import time import os import random #自定义header header = { 'User-Agent': 'Mozilla/5.0 (Windows NT 10. 阅读全文
posted @ 2020-10-10 23:05 lixinliang 阅读(130) 评论(0) 推荐(0)
上一页 1 ··· 9 10 11 12 13 14 15 16 17 ··· 22 下一页