Commit 0f7b312a by larosa

add new script

parent 09472ff9
Showing with 27 additions and 0 deletions
# 主要用于更新db中对应分类下的参数属性
# 分类数据来源于lie_shop_class 数据库中class_id 字段或 parent_id 字段
import sys
config_dev = {
"host": "192.168.1.238",
"port": 3306,
"user": "liexin_data_distribution",
"password": "liexin_data_distribution#zsyM",
"database": "liexin_data_distribution"
}
config_prod = {
}
if __name__ == '__main__':
option = {"dev", "prod"}
if len(sys.argv) >= 2 and sys.argv[1] in option:
environment = sys.argv[1]
else:
sys.exit(1)
if environment == "dev":
config = config_dev
elif environment == "prod":
config = config_prod
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment