Commit 2308b077 authored by 胡凯旋's avatar 胡凯旋

init

parents
Mac下搭建本地k8s,并进行开发、调试和部署
## 安装Docker/k8s
1. 安装 [Docker for Mac](https://docs.docker.com/docker-for-mac/install/),Version>=18.06,低版本可能不自带Kubernetes
2. 设置 `Docker` 中国官方镜像加速 [registry mirror](https://www.docker-cn.com/registry-mirror) ```https://registry.docker-cn.com```
![mirror](./image/mirror.jpg)
3. 预先从阿里云`Docker`镜像下载 `Kubernetes` 所需要的镜像, 可以通过修改 [./images](./images) 文件定制你自己需要的镜像
```bash
$ ./load_images.sh
```
4.`Docker for Mac` 设置中启用 `Kubernetes` 选项, 并等待一会儿,直到 `Kubernetes` 开始运行。
![k8s](./image/k8s.jpg)
5. 可选的步骤: 切换`Kubernetes`运行上下文至 `docker-for-desktop`
```bash
# 一般只有在之前用其他方式运行过Kubernetes才需要
$ kubectl config use-context docker-for-desktop
```
6. 验证 `Kubernetes` 集群状态
```bash
$ kubectl cluster-info
$ kubectl get nodes
```
7. 部署 `Kubernetes dashboard`
```bash
$ kubectl apply -f https://raw.githubusercontent.com/kubernetes/dashboard/master/src/deploy/recommended/kubernetes-dashboard.yaml
# 开启本机访问代理
$ kubectl proxy
```
通过下面的连接访问 `Dashboard`:
[`http://localhost:8001/api/v1/namespaces/kube-system/services/https:kubernetes-dashboard:/proxy/`](
http://localhost:8001/api/v1/namespaces/kube-system/services/https:kubernetes-dashboard:/proxy/)
获取 `Dashboard` `admin` 权限:
[`https://github.com/kubernetes/dashboard/wiki/Access-control#admin-privileges`](https://github.com/kubernetes/dashboard/wiki/Access-control#admin-privileges)
## 服务初次部署
1. docker login harbor.test.gengmei
```
docker login harbor.test.gengmei
username: gmuser
password: Gengmei123!
```
2. 创建项目目录,日志目录到指定位置
```
sudo mkdir -p /data/log/backend/app /data/log/gaia/app /data/log/mimas/app /data/log/doris/app # ...
sudo mkdir -p /srv/apps
cd /srv/apps
git clone git@git.wanmeizhensuo.com:backend/backend.git
git clone git@git.wanmeizhensuo.com:backend/gaia.git
git clone git@git.wanmeizhensuo.com:backend/Mimas.git
git clone git@git.wanmeizhensuo.com:rank/doris.git
```
3. 每个项目checkout到paas分支,build镜像
```
cd 项目目录
git checkout paas
docker build --no-cache -t 项目名:latest .
```
4. 复制 settings_local 到项目目录下
```
cp ./settings_local/backend/settings_local.py /srv/apps/backend/gengmei
cp ./settings_local/gaia/settings_local.py /srv/apps/gaia/gaia
cp ./settings_local/mimas/settings_local.py /srv/apps/mimas/settings/settings_local.py
cp ./settings_local/doris/devel.py /srv/apps/doris/doris/devel.py
```
5. docker-for-mac上添加File Sharing配置 /srv/apps、/data/log,添加后点击Apply & Restart,若报错,可不必添加。
6. 备份之前的路由表,用当前目录下的路由表替换之前的路由表
```
mv /etc/gm-config/storage/static.dir/helios.dir/static_route_table.json /etc/gm-config/storage/static.dir/helios.dir/static_route_table.json.old
cp ./static_route_table.json /etc/gm-config/storage/static.dir/helios.dir/static_route_table.json
```
7. 设置configmap
```
kubectl create configmap static-route-table --from-file=/etc/gm-config/storage/static.dir/helios.dir/static_route_table.json
kubectl create configmap backend-settings --from-file=/srv/apps/backend/gengmei/settings_local.py
kubectl create configmap gaia-settings --from-file=/srv/apps/gaia/gaia/settings_local.py
kubectl create configmap mimas-settings --from-file=/srv/apps/mimas/settings/settings_local.py
kubectl create configmap doris-settings --from-file=/srv/apps/doris/doris/devel.py
```
8. 部署Pod和Service
```
# Pod
kubectl create -f deploy/backend-deploy.yml
kubectl create -f deploy/gaia-deploy.yml
kubectl create -f deploy/mimas-deploy.yml
kubectl create -f deploy/doris-deploy.yml
# Service
kubectl create -f service/backend-service.yml
kubectl create -f service/gaia-service.yml
kubectl create -f service/mimas-service.yml
kubectl create -f service/doris-service.yml
```
9. 测试服务是否正常启动
## 服务调试
1. 更改代码
2. 更新服务
```
kubectl replace --force -f deploy/backend-service.yml # ...
```
3. 测试
apiVersion: apps/v1
kind: Deployment
metadata:
name: apollo-deploy-test
labels:
app: apollo
spec:
replicas: 1
selector:
matchLabels:
app: apollo
template:
metadata:
labels:
app: apollo
spec:
containers:
- name: apollo
image: harbor.test.gengmei/backend/apollo:v1.0
ports:
- containerPort: 8000
volumeMounts:
- name: static-route-table
mountPath: /etc/gm-config/storage/static.dir/helios.dir/
- name: resource-json
mountPath: /etc/gm-config/storage/static.dir/dev_env.dir/
- name: gm-logging-dir
mountPath: /etc/gm-config/storage/static.dir/gm_logging.dir/
- name: apollo-settings
mountPath: /srv/apps/apollo/apollo/settings_local.py
subPath: settings_local.py
- name: data-dir
mountPath: /data/log/apollo/app
volumes:
- name: static-route-table
configMap:
name: static-route-table
- name: resource-json
configMap:
name: resource-json
- name: gm-logging-dir
configMap:
name: gm-logging-dir
items:
- key: global_important_sentry.json
path: global_important_sentry.json
- key: kafka.json
path: kafka.json
- name: apollo-settings
configMap:
name: apollo-settings
items:
- key: settings_local.py
path: settings_local.py
# hostPath挂载
- name: data-dir
hostPath:
path: /data/log/apollo/app
# 私有仓库镜像下载认证
imagePullSecrets:
- name: harbor-secret
apiVersion: apps/v1
kind: Deployment
metadata:
name: artemis-deploy-test
labels:
app: artemis
spec:
replicas: 1
selector:
matchLabels:
app: artemis
template:
metadata:
labels:
app: artemis
spec:
containers:
- name: artemis
image: harbor.test.gengmei/backend/artemis:v1.0
ports:
- containerPort: 8000
volumeMounts:
- name: static-route-table
mountPath: /etc/gm-config/storage/static.dir/helios.dir/
- name: resource-json
mountPath: /etc/gm-config/storage/static.dir/dev_env.dir/
- name: gm-logging-dir
mountPath: /etc/gm-config/storage/static.dir/gm_logging.dir/
- name: artemis-settings
mountPath: /srv/apps/artemis/artemis/settings_local.py
subPath: settings_local.py
volumes:
- name: static-route-table
configMap:
name: static-route-table
- name: resource-json
configMap:
name: resource-json
- name: gm-logging-dir
configMap:
name: gm-logging-dir
items:
- key: global_important_sentry.json
path: global_important_sentry.json
- key: kafka.json
path: kafka.json
- name: artemis-settings
configMap:
name: artemis-settings
items:
- key: settings_local.py
path: settings_local.py
# 私有仓库镜像下载认证
imagePullSecrets:
- name: harbor-secret
apiVersion: apps/v1
kind: Deployment
metadata:
name: backend-deploy-test
labels:
app: backend
spec:
replicas: 1
selector:
matchLabels:
app: backend
template:
metadata:
labels:
app: backend
spec:
containers:
- name: backend
image: backend:local.latest
ports:
- containerPort: 8000
volumeMounts:
- name: static-route-table
mountPath: /etc/gm-config/storage/static.dir/helios.dir/
- name: backend-settings
mountPath: /srv/apps/backend/gengmei/settings_local.py
subPath: settings_local.py
- name: data-dir
mountPath: /data/log/backend/app
- name: work-dir
mountPath: /srv/apps/backend
volumes:
- name: static-route-table
configMap:
name: static-route-table
- name: backend-settings
configMap:
name: backend-settings
items:
- key: settings_local.py
path: settings_local.py
# hostPath挂载
- name: data-dir
hostPath:
path: /data/log/backend/app
- name: work-dir
hostPath:
path: /srv/apps/backend
# 私有仓库镜像下载认证
imagePullSecrets:
- name: harbor-secret
apiVersion: apps/v1
kind: Deployment
metadata:
name: doris-deploy-test
labels:
app: doris
spec:
replicas: 1
selector:
matchLabels:
app: doris
template:
metadata:
labels:
app: doris
spec:
containers:
- name: doris
image: doris:local.latest
ports:
- containerPort: 8000
volumeMounts:
- name: static-route-table
mountPath: /etc/gm-config/storage/static.dir/helios.dir/
# - name: resource-json
# mountPath: /etc/gm-config/storage/static.dir/dev_env.dir/
# - name: gm-logging-dir
# mountPath: /etc/gm-config/storage/static.dir/gm_logging.dir/
- name: doris-settings
mountPath: /srv/apps/doris/doris/devel.py
subPath: devel.py
# - name: doris-settings
# mountPath: /srv/apps/doris/doris/base.py
# subPath: base.py
- name: data-dir
mountPath: /data/log/doris/app
- name: work-dir
mountPath: /srv/apps/doris
volumes:
- name: static-route-table
configMap:
name: static-route-table
# - name: resource-json
# configMap:
# name: resource-json
# - name: gm-logging-dir
# configMap:
# name: gm-logging-dir
# items:
# - key: global_important_sentry.json
# path: global_important_sentry.json
# - key: kafka.json
# path: kafka.json
- name: doris-settings
configMap:
name: doris-settings
items:
- key: devel.py
path: devel.py
# - key: base.py
# path: base.py
# hostPath挂载
- name: data-dir
hostPath:
path: /data/log/doris/app
- name: work-dir
hostPath:
path: /srv/apps/doris
# 私有仓库镜像下载认证
imagePullSecrets:
- name: harbor-secret
apiVersion: apps/v1
kind: Deployment
metadata:
name: gaia-deploy-test
labels:
app: gaia
spec:
replicas: 1
selector:
matchLabels:
app: gaia
template:
metadata:
labels:
app: gaia
spec:
containers:
- name: gaia
image: gaia:local.latest
ports:
- containerPort: 8000
volumeMounts:
- name: static-route-table
mountPath: /etc/gm-config/storage/static.dir/helios.dir/
# - name: resource-json
# mountPath: /etc/gm-config/storage/static.dir/dev_env.dir/
# - name: gm-logging-dir
# mountPath: /etc/gm-config/storage/static.dir/gm_logging.dir/
- name: gaia-settings
mountPath: /srv/apps/gaia/gaia/settings_local.py
subPath: settings_local.py
- name: data-dir
mountPath: /data/log/gaia/app
- name: work-dir
mountPath: /srv/apps/gaia
volumes:
- name: static-route-table
configMap:
name: static-route-table
# - name: resource-json
# configMap:
# name: resource-json
# - name: gm-logging-dir
# configMap:
# name: gm-logging-dir
# items:
# - key: global_important_sentry.json
# path: global_important_sentry.json
# - key: kafka.json
# path: kafka.json
- name: gaia-settings
configMap:
name: gaia-settings
items:
- key: settings_local.py
path: settings_local.py
- name: data-dir
hostPath:
path: /data/log/gaia/app
- name: work-dir
hostPath:
path: /srv/apps/gaia
# 私有仓库镜像下载认证
imagePullSecrets:
- name: harbor-secret
apiVersion: apps/v1
kind: Deployment
metadata:
name: gm-face-deploy-test
labels:
app: gm-face
spec:
replicas: 1
selector:
matchLabels:
app: gm-face
template:
metadata:
labels:
app: gm-face
spec:
containers:
- name: gm-face
image: harbor.test.gengmei/backend/gm-face:v1.0
ports:
- containerPort: 8000
volumeMounts:
- name: static-route-table
mountPath: /etc/gm-config/storage/static.dir/helios.dir/
- name: resource-json
mountPath: /etc/gm-config/storage/static.dir/dev_env.dir/
- name: gm-logging-dir
mountPath: /etc/gm-config/storage/static.dir/gm_logging.dir/
- name: gm-face-settings
mountPath: /srv/apps/gm-face/gm-face/settings_local.py
subPath: settings_local.py
- name: data-dir
mountPath: /data/log/gm-face/app
volumes:
- name: static-route-table
configMap:
name: static-route-table
- name: resource-json
configMap:
name: resource-json
- name: gm-logging-dir
configMap:
name: gm-logging-dir
items:
- key: global_important_sentry.json
path: global_important_sentry.json
- key: kafka.json
path: kafka.json
- name: gm-face-settings
configMap:
name: gm-face-settings
items:
- key: settings_local.py
path: settings_local.py
- name: data-dir
hostPath:
path: /data/log/gm-face/app
# 私有仓库镜像下载认证
imagePullSecrets:
- name: harbor-secret
apiVersion: apps/v1
kind: Deployment
metadata:
name: mimas-deploy-test
labels:
app: mimas
spec:
replicas: 1
selector:
matchLabels:
app: mimas
template:
metadata:
labels:
app: mimas
spec:
containers:
- name: mimas
image: mimas:local.latest
ports:
- containerPort: 8000
volumeMounts:
- name: static-route-table
mountPath: /etc/gm-config/storage/static.dir/helios.dir/
# - name: resource-json
# mountPath: /etc/gm-config/storage/static.dir/dev_env.dir/
# - name: gm-logging-dir
# mountPath: /etc/gm-config/storage/static.dir/gm_logging.dir/
# - name: mimas-settings
# mountPath: /srv/apps/mimas/settings/base.py
# subPath: base.py
- name: mimas-settings
mountPath: /srv/apps/mimas/settings/settings_local.py
subPath: settings_local.py
- name: data-dir
mountPath: /data/log/mimas/app
- name: work-dir
mountPath: /srv/apps/mimas
volumes:
- name: static-route-table
configMap:
name: static-route-table
# - name: resource-json
# configMap:
# name: resource-json
# - name: gm-logging-dir
# configMap:
# name: gm-logging-dir
# items:
# - key: global_important_sentry.json
# path: global_important_sentry.json
# - key: kafka.json
# path: kafka.json
- name: mimas-settings
configMap:
name: mimas-settings
items:
# - key: base.py
# path: base.py
- key: settings_local.py
path: settings_local.py
- name: data-dir
hostPath:
path: /data/log/mimas/app
- name: work-dir
hostPath:
path: /srv/apps/mimas
# 私有仓库镜像下载认证
imagePullSecrets:
- name: harbor-secret
apiVersion: apps/v1
kind: Deployment
metadata:
name: passport-deploy-test
labels:
app: passport
spec:
replicas: 1
selector:
matchLabels:
app: passport
template:
metadata:
labels:
app: passport
spec:
containers:
- name: passport
image: harbor.test.gengmei/backend/passport:v1.0
ports:
- containerPort: 8000
volumeMounts:
- name: static-route-table
mountPath: /etc/gm-config/storage/static.dir/helios.dir/
- name: resource-json
mountPath: /etc/gm-config/storage/static.dir/dev_env.dir/
- name: gm-logging-dir
mountPath: /etc/gm-config/storage/static.dir/gm_logging.dir/
- name: passport-settings
mountPath: /srv/apps/passport/passport/settings_gaia_local.py
subPath: settings_gaia_local.py
- name: passport-settings
mountPath: /srv/apps/passport/passport/settings_redis.py
subPath: settings_redis.py
- name: data-dir
mountPath: /data/log/passport/app
volumes:
- name: static-route-table
configMap:
name: static-route-table
- name: resource-json
configMap:
name: resource-json
- name: gm-logging-dir
configMap:
name: gm-logging-dir
items:
- key: global_important_sentry.json
path: global_important_sentry.json
- key: kafka.json
path: kafka.json
- name: passport-settings
configMap:
name: passport-settings
items:
- key: settings_gaia_local.py
path: settings_gaia_local.py
- key: settings_redis.py
path: settings_redis.py
- name: data-dir
hostPath:
path: /data/log/passport/app
# 私有仓库镜像下载认证
imagePullSecrets:
- name: harbor-secret
apiVersion: apps/v1
kind: Deployment
metadata:
name: plutus-deploy-test
labels:
app: plutus
spec:
replicas: 1
selector:
matchLabels:
app: plutus
template:
metadata:
labels:
app: plutus
spec:
containers:
- name: plutus
image: harbor.test.gengmei/backend/plutus:v1.0
ports:
- containerPort: 8000
volumeMounts:
- name: static-route-table
mountPath: /etc/gm-config/storage/static.dir/helios.dir/
- name: resource-json
mountPath: /etc/gm-config/storage/static.dir/dev_env.dir/
- name: gm-logging-dir
mountPath: /etc/gm-config/storage/static.dir/gm_logging.dir/
- name: plutus-settings
mountPath: /srv/apps/plutus/plutus/settings_local.py
subPath: settings_local.py
- name: data-dir
mountPath: /data/log/plutus/app
# plutus secret config
- name: plutus-secret
mountPath: /srv/secret/msxf_gm.private
subPath: msxf_gm.private
- name: plutus-secret
mountPath: /srv/secret/msxf_key.public
subPath: msxf_key.public
- name: plutus-secret
mountPath: /srv/secret/zhongan_private.pem
subPath: zhongan_private.pem
- name: plutus-secret
mountPath: /srv/secret/zhongan_public.pem
subPath: zhongan_public.pem
volumes:
- name: static-route-table
configMap:
name: static-route-table
- name: resource-json
configMap:
name: resource-json
- name: gm-logging-dir
configMap:
name: gm-logging-dir
items:
- key: global_important_sentry.json
path: global_important_sentry.json
- key: kafka.json
path: kafka.json
- name: plutus-settings
configMap:
name: plutus-settings
items:
- key: settings_local.py
path: settings_local.py
- name: data-dir
hostPath:
path: /data/log/plutus/app
- name: plutus-secret
configMap:
name: plutus-secret
items:
- key: msxf_gm.private
path: msxf_gm.private
- key: msxf_key.public
path: msxf_key.public
- key: zhongan_private.pem
path: zhongan_private.pem
- key: zhongan_public.pem
path: zhongan_public.pem
# 私有仓库镜像下载认证
imagePullSecrets:
- name: harbor-secret
apiVersion: apps/v1
kind: Deployment
metadata:
name: push2-deploy-test
labels:
app: push2
spec:
replicas: 1
selector:
matchLabels:
app: push2
template:
metadata:
labels:
app: push2
spec:
containers:
- name: push2
image: harbor.test.gengmei/backend/push2:v1.0
ports:
- containerPort: 8000
volumeMounts:
- name: static-route-table
mountPath: /etc/gm-config/storage/static.dir/helios.dir/
- name: resource-json
mountPath: /etc/gm-config/storage/static.dir/dev_env.dir/
- name: gm-logging-dir
mountPath: /etc/gm-config/storage/static.dir/gm_logging.dir/
- name: push2-settings
mountPath: /srv/apps/push2/conf/settings_local.py
subPath: settings_local.py
- name: push2-settings
mountPath: /srv/apps/push2/conf/settings_jpush.py
subPath: settings_jpush.py
- name: push2-settings
mountPath: /srv/apps/push2/conf/settings_db.py
subPath: settings_db.py
- name: data-dir
mountPath: /data/log/push2/app
volumes:
- name: static-route-table
configMap:
name: static-route-table
- name: resource-json
configMap:
name: resource-json
- name: gm-logging-dir
configMap:
name: gm-logging-dir
items:
- key: global_important_sentry.json
path: global_important_sentry.json
- key: kafka.json
path: kafka.json
- name: push2-settings
configMap:
name: push2-settings
items:
- key: settings_local.py
path: settings_local.py
- key: settings_jpush.py
path: settings_jpush.py
- key: settings_db.py
path: settings_db.py
- name: data-dir
hostPath:
path: /data/log/push2/app
# 私有仓库镜像下载认证
imagePullSecrets:
- name: harbor-secret
apiVersion: apps/v1
kind: Deployment
metadata:
name: ship-deploy-test
labels:
app: ship
spec:
replicas: 1
selector:
matchLabels:
app: ship
template:
metadata:
labels:
app: ship
spec:
containers:
- name: ship
image: harbor.test.gengmei/backend/ship:v1.0
ports:
- containerPort: 8000
volumeMounts:
- name: static-route-table
mountPath: /etc/gm-config/storage/static.dir/helios.dir/
- name: resource-json
mountPath: /etc/gm-config/storage/static.dir/dev_env.dir/
- name: gm-logging-dir
mountPath: /etc/gm-config/storage/static.dir/gm_logging.dir/
- name: ship-settings
mountPath: /srv/apps/ship/ship/settings_local.py
subPath: settings_local.py
- name: ship-settings
mountPath: /srv/apps/ship/ship/settings_base.py
subPath: settings_base.py
- name: data-dir
mountPath: /data/log/ship/app
volumes:
- name: static-route-table
configMap:
name: static-route-table
- name: resource-json
configMap:
name: resource-json
- name: gm-logging-dir
configMap:
name: gm-logging-dir
items:
- key: global_important_sentry.json
path: global_important_sentry.json
- key: kafka.json
path: kafka.json
- name: ship-settings
configMap:
name: ship-settings
items:
- key: settings_local.py
path: settings_local.py
- key: settings_base.py
path: settings_base.py
# hostPath挂载
- name: data-dir
hostPath:
path: /data/log/ship/app
# 私有仓库镜像下载认证
imagePullSecrets:
- name: harbor-secret
apiVersion: apps/v1
kind: Deployment
metadata:
name: uc-sms-deploy-test
labels:
app: uc-sms
spec:
replicas: 1
selector:
matchLabels:
app: uc-sms
template:
metadata:
labels:
app: uc-sms
spec:
containers:
- name: uc-sms
image: harbor.test.gengmei/backend/uc-sms:v1.0
ports:
- containerPort: 8000
volumeMounts:
- name: static-route-table
mountPath: /etc/gm-config/storage/static.dir/helios.dir/
- name: resource-json
mountPath: /etc/gm-config/storage/static.dir/dev_env.dir/
- name: gm-logging-dir
mountPath: /etc/gm-config/storage/static.dir/gm_logging.dir/
- name: data-dir
mountPath: /data/log/uc_sms/app
volumes:
- name: static-route-table
configMap:
name: static-route-table
- name: resource-json
configMap:
name: resource-json
- name: gm-logging-dir
configMap:
name: gm-logging-dir
items:
- key: global_important_sentry.json
path: global_important_sentry.json
- key: kafka.json
path: kafka.json
- name: data-dir
hostPath:
path: /data/log/uc_sms/app
# 私有仓库镜像下载认证
imagePullSecrets:
- name: harbor-secret
apiVersion: apps/v1
kind: Deployment
metadata:
name: zeus-deploy-test
labels:
app: zeus
spec:
replicas: 1
selector:
matchLabels:
app: zeus
template:
metadata:
labels:
app: zeus
spec:
containers:
- name: zeus
image: harbor.test.gengmei/backend/zeus:v1.0
ports:
- containerPort: 8000
volumeMounts:
- name: static-route-table
mountPath: /etc/gm-config/storage/static.dir/helios.dir/
- name: resource-json
mountPath: /etc/gm-config/storage/static.dir/dev_env.dir/
- name: gm-logging-dir
mountPath: /etc/gm-config/storage/static.dir/gm_logging.dir/
- name: zeus-settings
mountPath: /srv/apps/zeus/zeus/settings_local.py
subPath: settings_local.py
- name: data-dir
mountPath: /data/log/zeus/app
volumes:
- name: static-route-table
configMap:
name: static-route-table
- name: resource-json
configMap:
name: resource-json
- name: gm-logging-dir
configMap:
name: gm-logging-dir
items:
- key: global_important_sentry.json
path: global_important_sentry.json
- key: kafka.json
path: kafka.json
- name: zeus-settings
configMap:
name: zeus-settings
items:
- key: settings_local.py
path: settings_local.py
# hostPath挂载
- name: data-dir
hostPath:
path: /data/log/zeus/app
# 私有仓库镜像下载认证
imagePullSecrets:
- name: harbor-secret
k8s.gcr.io/kube-proxy-amd64:v1.10.3=registry.cn-hangzhou.aliyuncs.com/google_containers/kube-proxy-amd64:v1.10.3
k8s.gcr.io/kube-controller-manager-amd64:v1.10.3=registry.cn-hangzhou.aliyuncs.com/google_containers/kube-controller-manager-amd64:v1.10.3
k8s.gcr.io/kube-scheduler-amd64:v1.10.3=registry.cn-hangzhou.aliyuncs.com/google_containers/kube-scheduler-amd64:v1.10.3
k8s.gcr.io/kube-apiserver-amd64:v1.10.3=registry.cn-hangzhou.aliyuncs.com/google_containers/kube-apiserver-amd64:v1.10.3
k8s.gcr.io/k8s-dns-dnsmasq-nanny-amd64:1.14.8=registry.cn-hangzhou.aliyuncs.com/google_containers/k8s-dns-dnsmasq-nanny-amd64:1.14.8
k8s.gcr.io/k8s-dns-sidecar-amd64:1.14.8=registry.cn-hangzhou.aliyuncs.com/google_containers/k8s-dns-sidecar-amd64:1.14.8
k8s.gcr.io/k8s-dns-kube-dns-amd64:1.14.8=registry.cn-hangzhou.aliyuncs.com/google_containers/k8s-dns-kube-dns-amd64:1.14.8
k8s.gcr.io/pause-amd64:3.1=registry.cn-hangzhou.aliyuncs.com/google_containers/pause-amd64:3.1
k8s.gcr.io/kubernetes-dashboard-amd64:v1.10.0=registry.cn-hangzhou.aliyuncs.com/google_containers/kubernetes-dashboard-amd64:v1.10.0
k8s.gcr.io/etcd-amd64:3.1.12=registry.cn-hangzhou.aliyuncs.com/google_containers/etcd-amd64:3.1.12
gcr.io/kubernetes-helm/tiller:v2.10.0=registry.cn-hangzhou.aliyuncs.com/google_containers/tiller:v2.10.0
\ No newline at end of file
sudo mkdir -p /srv/apps
sudo chown -R gmei /srv/apps
cd /srv/apps
git clone git@git.wanmeizhensuo.com:backend/backend.git
git clone git@git.wanmeizhensuo.com:backend/gaia.git
git clone git@git.wanmeizhensuo.com:backend/Mimas.git
git clone git@git.wanmeizhensuo.com:rank/doris.git
#/bin/bash
file="images"
if [ -f "$file" ]
then
echo "$file found."
while IFS='=' read -r key value
do
#echo "${key}=${value}"
docker pull ${value}
docker tag ${value} ${key}
docker rmi ${value}
done < "$file"
else
echo "$file not found."
fi
\ No newline at end of file
kind: Service
apiVersion: v1
metadata:
name: backend-service
spec:
selector:
app: backend
ports:
- protocol: TCP
port: 80
targetPort: 80
type: NodePort
\ No newline at end of file
kind: Service
apiVersion: v1
metadata:
name: doris-service
spec:
selector:
app: doris
ports:
- protocol: TCP
port: 80
targetPort: 80
\ No newline at end of file
kind: Service
apiVersion: v1
metadata:
name: gaia-service
spec:
selector:
app: gaia
ports:
- protocol: TCP
port: 80
targetPort: 80
\ No newline at end of file
kind: Service
apiVersion: v1
metadata:
name: mimas-service
spec:
selector:
app: mimas
ports:
- protocol: TCP
port: 80
targetPort: 80
\ No newline at end of file
# 运营审核所需要的时间,以天为单位
AUDIT_DURATION = 0
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'antispam',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3307',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
},
}
DEBUG = False
CACHES = {
"default": {
"BACKEND": "django_redis.cache.RedisCache",
"LOCATION": "redis://192.168.168.142/5",
"OPTIONS": {
"CLIENT_CLASS": "django_redis.client.DefaultClient",
}
}
}
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # 设置为mysql�~U��~M��~S
'NAME': 'apollo',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3307',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为�~F�~T��~L~Aemoji表�~C~E
},
},
}
EMAIL_USER = 'doctor@wanmeizhensuo.com'
EMAIL_PSWD = 'xl60QkFtwJq6ziswn2a4r4pkFNozI13g'
AES_KEY = 'keycasefornonprd' # 16个�~W�~J~B�~Z~D�~F�~R�
AES_IV = 'iv_casefornonprd' # 16个�~W�~J~B�~Z~D�~H~]�~K�~P~Q�~G~O
QINIU_ACCESS_KEY = "UPCOYIJkZOMcdd9FDzpBqYjzWUh55fBpVi3AhWpL"
QINIU_SECRET_KEY = "z5YvpDDSam_JE345Z8J_f3TufzelOW2VOGNoBl9e"
BROKER_URL = 'redis://192.168.168.142/6'
ERROR_RESPONSE_TO = ['dingyingcai@gmei.com', 'zhongchengyang@gmei.com', 'xuepengfei@gmei.com']
# -*- coding:utf-8 -*-
# artemis local settings template
CACHES = {
'default': {
'BACKEND': 'django_redis.cache.RedisCache',
'LOCATION': 'redis://192.168.168.142:3',
'TIMEOUT': 86400, # 3600 x 24
},
}
BROKER_URL = 'redis://192.168.168.142/8'
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'artemis_hotfix2', # zhengxing_test zhengxing_dev4hera zhengxing_dev
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
},
}
DEBUG = True
SENTRY_CELERY_ENDPOINT = ''
from .base_settings import *
STATIC_ROOT = '/srv/static/ascle/'
SESSION_ENGINE = 'django.contrib.sessions.backends.cache'
DEBUG = True
CACHES = {
'default': {
'BACKEND': 'django_redis.cache.RedisCache',
'LOCATION': 'redis://192.168.168.142:6379/6',
'KEY_PREFIX': 'ascle',
'TIMEOUT': 86400, # one day
},
}
REDIS = {'host': '192.168.168.142', 'port': 6379, 'db': 6}
BROKER_URL = 'redis://192.168.168.142:6379/8'
QINIU_ACCESS_KEY = "UPCOYIJkZOMcdd9FDzpBqYjzWUh55fBpVi3AhWpL"
QINIU_SECRET_KEY = "z5YvpDDSam_JE345Z8J_f3TufzelOW2VOGNoBl9e"
CACHE_PAGE_STATUS = False # 页面缓存的开关
STATEMENT_VISIBLE = True # 对账单显示开关
MAIDAN_VISIBLE = True # 买单开关
# 总开关, True则全部人能看见
DOCTOR_CAN_SEE_TRAFFIC = True
# 白名单, use Doctor.id, 只要配置了一定能看见
DOCTOR_TRAFFIC_WHITE_LIST = [
'wangyang', 'aojianfei', 'chenxiaofang',
]
# 前后端分离了,添加fe 中的index.html 和 static
# ====!!!!!!dev/test/release无须配置, remove three lines settings !!!!!!!!
from .base_settings import TEMPLATES, STATICFILES_DIRS, BASE_DIR
TEMPLATES[0]['DIRS'].append(os.path.join(BASE_DIR, 'fe', 'dist'))
STATICFILES_DIRS.append(os.path.join(BASE_DIR, 'fe', 'dist', 'static'))
REDIS = {
'host': '192.168.168.142',
'port': 6379,
'db': 0,
}
REDIS_SENTINEL = [('192.168.168.142', 26379 ), ('192.168.168.142', 26379), ('192.168.168.142', 26379)]
# coding=utf-8
# test by wph
import datetime
from datetime import timedelta
from celery.schedules import crontab
import helios.rpc
SECRET_KEY = 'fl-lv3j^czg(dupo@hbs(+_+djby9zelwt&rh71@b1x*ptmj4#(^'
STAGGER_FLAG = True
GRAY_TEST = True
AB_TEST_LIST = []
DIARY_SORT_WHITE_LIST = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9']
IOS_UPDATE = True
ANDROID_UPDATE = True
RAVEN_CONFIG = {
'dsn': ''
}
DEBUG = True
TEMPLATE_DEBUG = DEBUG
ALLOWED_HOSTS = ['*']
MEDIA_ROOT = '/srv/media/backend/media'
#STATIC_ROOT = '/srv/static/backend/static'
STATICFILES_DIRS = (
)
ENCRYPT_KEY = 'Up[K+ub%pliOnsO5UavFBd)cw5VcyHSX'
BODYPART_ALL_ICON = 'http://hera.s.gmei.com/bodypart/2016/05/25/c95f1dd609'
SERVICE_SPECIAL_DES_ICON = 'http://hera.s.gmei.com/2017/07/10/9950841785'
HIDE_TAGS = False
EVENT_DOCTOR_TITLES = [
('2015-08-05', u'自体脂肪'),
('2015-08-06', u'骨骼'),
('2015-08-07', u'美胸'),
('2015-08-08', u'鼻部'),
('2015-08-09', u'微整形'),
('2015-08-10', u'失败修复'),
('2015-08-11', u'人气医师'),
]
INTEGRAL_GDT = 'http://hermes.test.gmei.com/integralwall/record_activating'
HOT_TAG_ICON = 'http://pic.gmei.com/img/geng.jpg'
HOT_IN_24HRS_ICON = 'http://wanmeizhensuo.qiniudn.com/2015/09/18/49a291d255-thumb'
SHOW_THIRDPARTY_LOGIN_ICON = True
# ====================================================================================================
# =============================================RPC====================================================
# ====================================================================================================
# RPC_URL = 'http://rpc.test.gmei.com/api/'
RPC_URL = 'http://rpc.test.gengmei.cc/api/'
RPC_SECRET = 'basic:M21gQkp0vWmDxlB5wVsIGCgbjdcshCsYaTgl4Rq0E6ug6Ma2teM9tpGCf5TZHsCGGC4cGQ4as9N3KmrDPQ43gA=='
# RPC_INVOKER = helios.rpc.RPCFactory(RPC_URL, RPC_SECRET, debug=DEBUG, debug_unwrap_checker_raise_exception=False, debug_dump_curl=True, use_batch=False).create_invoker()
RPC_INVOKER = helios.rpc.create_default_invoker(debug=DEBUG)
# ====================================================================================================
# ============================================分期付款=================================================
# ====================================================================================================
JIKE_URL = "http://test.geexfinance.com/merchant/service/"
JIKE_USER_ID = 12369
JIKE_SERVICE_ID = "gengmei"
JIKE_SERVICE_HASH = "3710f84987aaa4f455a10f8bbb5c55e1"
# ====================================================================================================
# ============================================七牛存储=================================================
# ====================================================================================================
QINIU_ACCESS_KEY = "UPCOYIJkZOMcdd9FDzpBqYjzWUh55fBpVi3AhWpL"
QINIU_SECRET_KEY = "z5YvpDDSam_JE345Z8J_f3TufzelOW2VOGNoBl9e"
API_HOST = "http://backend.test.env"
HTTPS_HOST = 'http://backend.test.env/'
WEB_API_HOST = "http://m.test.env"
PCWEB_API_HOST = "http://pcweb.test.gmei.com"
OPBACK_URL = "http://admin.test.gmei.com"
QINIU_HOST = "http://wanmeizhensuo.qiniudn.com"
# ====================================================================================================
# ============================================邮件发送=================================================
# ====================================================================================================
EMAIL_HOST = 'smtp.exmail.qq.com'
EMAIL_HOST_USER = 'doctor@wanmeizhensuo.com'
EMAIL_HOST_PASSWORD = 'gengmei098'
STATIS_EMAIL_USER = 'youjiantongji@wanmeizhensuo.com'
STATIS_EMAIL_PSWD = 'gengmei9801'
DEFAULT_FROM_EMAIL = 'doctor@wanmeizhensuo.com'
BrokenLinkEmailsMiddleware = True
SERVER_EMAIL = 'doctor@wanmeizhensuo.com'
EMAIL_PORT = 25
# ====================================================================================================
# ============================================支付宝===================================================
# ====================================================================================================
ALIPAY_MD5_KEY = "2894fddi6kahmpj56n008le81gjnvdwp"
ALIPAY_SIGN_TYPE = 'MD5'
# ====================================================================================================
# ============================================Redis===================================================
# ====================================================================================================
REDIS = {'host': '192.168.168.142', 'port': 6379, 'db': 0}
BROKER_URL = 'redis://192.168.168.142:6379/3'
BROKER_TRANSPORT_OPTIONS = {'visibility_timeout': 259200} # 72 hours
CELERY_TIMEZONE = 'Asia/Shanghai'
CELERYBEAT_SCHEDULE = {
'allocate_stat_doctor': {
'task': 'statistic.tasks.allocate_stat_doctor',
'schedule': crontab(minute=50, hour=23),
'args': ()
},
'refresh_doctorstat_task': {
'task': 'statistic.tasks.refresh_doctorstat_task',
'schedule': timedelta(hours=4),
'args': ()
},
'share_topic_add_point': {
'task': 'api.tasks.share_topic_add_point',
'schedule': timedelta(minutes=30),
'args': ()
},
'link_doctor': {
'task': 'api.tasks.link_doctor',
'schedule': timedelta(minutes=6),
'args': ()
},
'send_sms_mail-9-am': {
'task': 'api.tasks.sms_service',
'schedule': crontab(minute=0, hour=9),
'args': ()
},
'send_stat_mail': {
'task': 'statistic.tasks.send_stat_mail',
'schedule': crontab(minute=5, hour=0),
'args': ()
},
'stat_user_daily': {
'task': 'statistic.tasks.stat_user_daily',
'schedule': crontab(minute=50, hour=23),
'args': ()
},
'hospital_body_sub_items': {
'task': 'api.tasks.hospital_body_sub_items',
'schedule': timedelta(days=1),
'args': ()
},
'doctors2redis': {
'task': 'api.tasks.doctors2redis',
'schedule': crontab(minute=0, hour=3),
'args': ()
},
'hospital2redis': {
'task': 'api.tasks.hospital2redis',
'schedule': crontab(minute=0, hour=3),
'args': ()
},
'send_conversation_stat_mail': {
'task': 'statistic.tasks.send_conversation_stat_mail',
'schedule': crontab(minute=10, hour=0),
'args': ()
},
'send_conversation_weekly_stat_mail': {
'task': 'statistic.tasks.send_conversation_weekly_stat_mail',
'schedule': crontab(minute=10, hour=0, day_of_week='tue'),
'args': ()
},
'doctor_tags': {
'task': 'api.tasks.doctor_tags',
'schedule': crontab(minute=20, hour=5),
'args': ()
},
'tag2redis': {
'task': 'api.tasks.tag2redis',
'schedule': crontab(minute=0, hour=6),
'args': ()
},
'autocomplete_words': {
'task': 'api.tasks.autocomplete_words',
'schedule': crontab(minute=30, hour=3, day_of_week='sunday'),
'args': ()
},
}
# ====================================================================================================
# ============================================美券====================================================
# ====================================================================================================
COUPON_SHARE_SECRET = 'kOMro0bJ.,D*YccA^b]i[)difDe!@llH'
COUPON_SHARE = {
'show_share': True,
'slogan': u'更美CEO刘迪送您“美元”啦!',
'title': '恭喜您获得更美<ems>现金劵!</ems>',
'image': 'http://hera.s.gmei.com/liudi_portrait@2x.png',
'content': u'分享红包给小伙伴,你和朋友都可以获得<ems>1000</ems>元大礼包!',
'wechat': {
'title': '更美CEO刘迪来给我的好朋友们送“美元”啦!',
'text': '8.5更美大促! 800个医美项目免费送,91场0元秒杀,全场低至1折!',
'icon': 'http://hera.s.gmei.com/liudi_portrait.png',
'share_url': 'http://m.test.gmei.com/ticket_share/',
},
'wechat_moments': {
'title': '更美CEO刘迪来给我的好朋友们送“美元”啦!',
'text': '更美CEO刘迪来给我的好朋友们送“美元”啦!',
'icon': 'http://hera.s.gmei.com/liudi_portrait.png',
'share_url': 'http://m.test.gmei.com/ticket_share/',
},
}
SERVICE_HOME_SECKILL_ICON = 'http://wanmeizhensuo.qiniudn.com/2015/11/28/0fa3033388'
ANONYMOUS_USER_ID = 19634221
ORDER_ARBIT_TIMEOUT_DELTA=60
GAIA_REDIS = {'host': 'localhost', 'port': 6379, 'db': 0}
ANDROID_CURRENT_VERSION_DATA = {
'version': '5.9.2',
'version_code': 592,
'minimum_support_version': '5.5.0',
'description': u'''更美APP,中国第一美容整形与健康服务平台。\n1.新年,新颜,新气象~更美陪你过大年!\n2.首页内容展示焕然一新!are you ready? \n3.部分页面设计大变身,快来>看看我是不是更美了~ \n4. 程序猿GG又一次打败了小怪兽!对不起,让宝宝们受惊了~ \n5. 欢迎你的任何冷酷批评或热烈表白:hi@gmei.com''',
'apk': 'http://dl.gmei.com/apk/gengmei.apk?version=5.9.3',
}
IOS_CURRENT_VERSION_DATA = {
'version': '5.9.2',
'version_code': 11,
'minimum_support_version': '5.5.0',
'apps_latest_support_version': '5.9.2',
'description': u'',
'apk': ''
}
PK_TOPICS = {
24568: {
'title': u'中韩医生pk1',
'start_time': '2016-03-31',
'end_time': '2016-04-30',
'doctors': {
'02adf94ef1a711e5903d0242c0a8001f': {
'flag': 'http://7d9qwy.com2.z0.glb.qiniucdn.com/2016/03/24/5119e449eb',
},
'02adf94ef1a711e5903d0242c0a8001f': {
'flag': 'http://7d9qwy.com2.z0.glb.qiniucdn.com/2016/03/24/b0762d446e',
}
},
'share_data': {
'image': 'http://hera.s.gmei.com/share9.9.jpg',
'wechat_title': u'微信分享标题',
'wechat_content': u'微信分享文案',
'wechat_line': u'微信分享朋友圈文案',
'weibo': u'分享到微博文案 http://xxxxxxx @更美App',
}
},
12177482: {
'title': u'中韩医生pk1',
'start_time': '2016-03-30',
'end_time': '2016-04-04',
'doctors': {
'100001': {
'flag': 'http://7d9qwy.com2.z0.glb.qiniucdn.com/2016/03/24/5119e449eb',
},
'100002': {
'flag': 'http://7d9qwy.com2.z0.glb.qiniucdn.com/2016/03/24/b0762d446e',
}
},
'share_data': {
'image': 'http://hera.s.gmei.com/share9.9.jpg',
'wechat_title': u'中韩医生PK',
'wechat_content': u'快来给自己支持的医生投票了',
'wechat_line': u'中韩医生pk',
'weibo': u'#中韩医生#双眼皮技术谁最好?快来投票→http://m.gmei.com/topic/12177482/ @更美APP',
},
},
12177487: {
'title': u'中韩医生pk1',
'start_time': '2016-03-30',
'end_time': '2016-04-04',
'doctors': {
'100001': {
'flag': 'http://7d9qwy.com2.z0.glb.qiniucdn.com/2016/03/24/5119e449eb',
},
'100002': {
'flag': 'http://7d9qwy.com2.z0.glb.qiniucdn.com/2016/03/24/b0762d446e',
}
},
'share_data': {
'image': 'http://hera.s.gmei.com/share9.9.jpg',
'wechat_title': u'中韩医生PK',
'wechat_content': u'快来给自己支持的医生投票了',
'wechat_line': u'中韩医生pk',
'weibo': u'#中韩医生#双眼皮技术谁最好?快来投票→http://m.gmei.com/topic/12177482/ @更美APP',
},
},
}
PK_TOPICS={}
TIME_CAN_ACCEPT_CALL = (datetime.time(9, 0, 0), datetime.time(15, 0, 0))
GENGMEI_TENANT_ID = 'b2119c17665b4f509ddade8397d58e84'
GENGMEI_KEFU_USER_ID = 20889691
GENGMEI_KEFU_PERSON_ID = '2b64c68727cb11e68181f45c899f3b33'
FEEDBACK_CS_GROUP = '455979578157409fab1ca83f4f824e87'
#SESSION_COOKIE_DOMAIN_GENGMEI = 'backend.test.gengmei.cc'
SESSION_COOKIE_DOMAIN_BACKEND_GENGMEI = 'backend.test.gengmei.cc'
PUSH_NOTIFICATION_AFTER_FOLLOW_USER = True
ORDER_COMPLETE_SHARE_COUPONGIFT_ID = 40
PAY_TOGGLE = {
'alipay': True,
'wechat': True,
'applepay': True,
'xiaoying': True,
'yinuo': True,
'renmai': True,
'maidan': True,
'zhongan': True,
'yirendai': True,
'renmai_credit': True,
}
PROMOTE_AREA_SERVICE = []
IS_ACCEPT_CALL = True
COUPON_GIFT_URL = 'http://m.test.gmei.env/coupon_gift'
## UNION ##
#CUSTOM_SERVICE_PHONE = 'tel://4006999227,,6666#'
#
#CSC_400_EXT_LITERAL = u'4006-999-227转6666#'
#CSC_400_CALL_URL = 'tel://4006999227,,6666#'
## ZHHT ##
# CUSTOM_SERVICE_PHONE_CALL_TIP = u'如不能接通,请按提示输入分机号 {ext}'
CUSTOM_SERVICE_PHONE = 'tel://01059658065,,6666'
CSC_400_EXT_LITERAL = u'010-5965-8065转6666'
CSC_400_CALL_URL = 'tel://01059658065,,6666'
# 买单分期开关
MAIDAN_INSTALLMENT_TOGGLE = True
INDEX_TAB_CONFIG_2X = [
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/10/7ea40e5e4e",# 普通icon 为空则不更新
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/10/543f0d9aba",# 高亮icon 为空则不更新
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/10/c8566c0463",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/10/406c970989",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/10/392009518b",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/10/392009518b",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/10/56e5bb9217",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/10/cd7e926b40",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/10/64c8969b25",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/10/da466e68ca",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
}
]
INDEX_TAB_CONFIG = [
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/08/2d4e0f337f",# 普通icon 为空则不更新
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/08/b90918ec43",# 高亮icon 为空则不更新
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/08/e47f4bf721",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/08/b5a70ded46",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/08/99deaba0a9",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/08/99deaba0a9",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/08/60cdb44bc0",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/08/e60b5dbc39",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/08/19739929b6",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/08/34650a5c69",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
}
]
# 2017.5 分享文案开关
NEW_SHARE_DATA = True
POINT_MALL_SWITCH = True
SESSION_COOKIE_DOMAIN_IGENGMEI = '.test.env'
SESSION_COOKIE_DOMAIN = '.test.env' # since 6.0
FACE_REPORT_WITH_UINFO_V1 = ['9', '3','8','6','7'] # 新版发布概率,add in 7630
FACE_REPORT_WITH_UINFO = ['7','3','2','6']
WECHAT_SMALL_APPID = 'wx113018c998de9eaf'
WECHAT_SMALL_APPSECRET = '328083f0cbb131c7de3b3920eed8ddaf'
#coding:utf8
import pyssdb
import os
import raven
DEBUG = False
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'bran_prod',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3307',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
},
'gaia':{
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'zhengxing',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
},
}
CELERY_BROKER_URL = 'redis://192.168.168.142/0'
REDIS_URL = 'redis://192.168.168.142/2'
REDIS = {
'default': {'host': '192.168.168.142', 'port': 11032, 'db': 0,}
}
PUSH_EVENT_LIMIT = {'sum': 5, 'service': 1}
TIME_FRAGMENT = {'5h': '5h', '1d': '1d', '5d': '5d', '7d': '7d'}
ACTION_TRIGGER_INTERVAL = 5 # 事件触发时间间隔 hours
DAILY_EVENT_HANDLE_TIME = [9, 13, 21]
SSDB_CLIENT = pyssdb.Client(host='127.0.0.1', port=8888)
RAVEN_CONFIG = {
'dsn': 'http://9f8992868f0348efaca2f4375e8db1df:11764cbbdb1440c38142c9e1a1e663ac@sentry.igengmei.com/131',
}
#!/usr/bin/env python
# -*- coding:utf-8 -*-
#
# Author : zhangxiaolin
# E-mail : petelin1120@gmail.com
# Date : 17/6/21 16:59
# Desc : ...
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'cadus',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
},
'gaia': {
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'zhengxing_test',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
}
}
RAVEN_CONFIG = {
'dsn': 'http://c5b4ede52bc6452182565b529735a090:0324e8fff118445a9b38576213b8e759@sentry.igengmei.com/120',
}
DATABASE_ROUTERS = ['common.django_tools.GaiaRouter']
# DATABASES = {
# 'default': {
# 'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
# 'NAME': '',
# 'USER': 'work',
# 'PASSWORD': 'workwork',
# 'HOST': 'rdsmaqevmuzj6jy.mysql.rds.aliyuncs.com',
# 'PORT': '',
# 'OPTIONS': {
# "init_command": "SET foreign_key_checks = 0;",
# "charset": "utf8mb4", # 为了支持emoji表情
# },
# },
# }
SECRET_KEY = '0l-lv2j^czg(dsdf3hbs(+_+djb49zelwt&rh71@b1x*ptmj4#(^' # dev
CACHES = {
"default": {
"BACKEND": "django_redis.cache.RedisCache",
"LOCATION": "redis://192.168.168.142/13",
"OPTIONS": {
"CLIENT_CLASS": "django_redis.client.DefaultClient",
}
}
}
# ====================================================================================================
# ============================================微信====================================================
# ====================================================================================================
M_WECHAT_APP_ID = 'wx5dcbb1544163c77c'
M_WECHAT_PARTNER_ID = '1284132201'
M_WECHAT_SECRET = 'e821f46be6ee45e3ca80d189f989313b' # 不是微信的SECRET 是 pay.weixin.qq.com!!
M_WECHAT_PEM_KEY = """-----BEGIN PRIVATE KEY-----
MIIEvgIBADANBgkqhkiG9w0BAQEFAASCBKgwggSkAgEAAoIBAQDt1dDq+GzhiGhA 21H2HoupC2ctUD96TlqnN6rECBsr14JSZPJBlTgOldbIz5xWYyWunNn6sVoE40sT KkdEkunRPX63QqzoNnarg+6aNtR5F30IWGiT8Hc7JfKg5GKTnrmNzifintMD9S92 dSVknreMXTJbSs366/vyBrt6GcHETX98ECWTOM4au6jvaQYHxMY/T4s25JGRijSD tLJZnakY6Db/PiNGd6jTlRsfSTRPkm5/v/RqYRO8FVB2+1c7/tb2z/JuRK0/bWDe jItA5Et1qiAzEh0RLiUATnjWZlAaZptYJJ0ZdS9E5wgGOP6A47/IbrOHtv6NU2GS GcXdM8zLAgMBAAECggEAUkjReRnuAbGB8D5xAufahefOEJ1c+OG293eI+z2auPZc vkjyj8IinNk2cE9z1WeEF/9oYxWNAXfp931/Hrh9cMkH2DuXOtftArYojO4/YI3B 0mtT8ysU9T/Ry9x4Rn550BftMLimZQ4lF6S8BS3sbwGndHJTBWczya6OmlXi9hj3 KxZTMDf/IUzj3U3BQ2ms2Etz23WAwTwyHrhjA43H9I+YZIuFN4+ncUKT2i9Smf8l dkyuWqFtU9yXOJMuRy3Sl7idhSgjGB+Yr4/A9OO3uWEcxiKFmZX8GnbFPe4tjv1T fgFmzOOvmB3JsJE1p6xfnk2IVUH6pxvEg2ClqsSd4QKBgQD6AhyQByC7PRy8Sba7 Mw9QQnWnPvB4lLN2F8qfjyUNq/sTLo6Z9pITfSvyKveH1dcHVfFS31X2UoMu10tv cBN0OsbjWsVQtr9mFA4Ig8xcfl4iSHegGks/cCIi47K6Y9gl+snd4b7ZNu1ie4ia jhBAgo0y8rU91cRg9dOPaH5ZIwKBgQDziQTJqGtzKKJpSrMZTDgWsk7hbeDbMqk6 W6C2AawqOTLQWr8Y6iMmdHF1CyKVZ8492LHgzNL6qxoC2vro4Fqk/fsLcXXrd98h Ez62tnJ0Fz1KOdNIPJksasTw4/Zz5XJz4cJLQuJi1m7dzzZFLu+vqAEtF2h/Ph0V +03mqVd8OQKBgA+A0gScbIsv3vhOGebB49E2TdVxMbhIgFhyYT5Dwih24bruyCkE AUr0GCWMRI1H1W2/Bpf9AXek5j2hXCws5wfuHSc8GcBHlNbfp38frSyPKYc2tzRW bRQh//vp4stsJZs1Ug9QUGVn4pCY2H+9D4Twk5D1PAf5mZPpqpTaBfvBAoGBAKIi 5v0bE+5nbzmKchK1m+IAdGPBM6K7587ikeya0HSMADiXMgL0XtKLU74I2818fuLO Eh8IPq6Em5yrDcFdHPwb27eSol9SP0tV9LrQXQLNNhDkzrWZIqFftB5spvgiGkDs XN6eePo0qTsjaY5F4W2g/Kd4nimYwOSRmxumQoiBAoGBAKShHkOaUWkuai5vf4Wo G/zgBuDbLVmX6NvgcaPWtEUduXHAP/fFUjngQ5xR1asMMmW3joZ1LFeWyZjtqqUd aqMLQ+Tlbe/d7ofBKOUjygMR18mK6YAKfYciFGlPTq4Tw4urfNz2tRgWVv60v3O2 Gve9XIe+hUKadREsA1ncDSR0
-----END PRIVATE KEY-----"""
M_WECHAT_PEM_CERT = """-----BEGIN CERTIFICATE-----
MIIEbjCCA9egAwIBAgIDCUwDMA0GCSqGSIb3DQEBBQUAMIGKMQswCQYDVQQGEwJD TjESMBAGA1UECBMJR3Vhbmdkb25nMREwDwYDVQQHEwhTaGVuemhlbjEQMA4GA1UE ChMHVGVuY2VudDEMMAoGA1UECxMDV1hHMRMwEQYDVQQDEwpNbXBheW1jaENBMR8w HQYJKoZIhvcNAQkBFhBtbXBheW1jaEB0ZW5jZW50MB4XDTE1MTEwNTAxNDEwMloX DTI1MTEwMjAxNDEwMlowgZ4xCzAJBgNVBAYTAkNOMRIwEAYDVQQIEwlHdWFuZ2Rv bmcxETAPBgNVBAcTCFNoZW56aGVuMRAwDgYDVQQKEwdUZW5jZW50MQ4wDAYDVQQL EwVNTVBheTEzMDEGA1UEAxQq5YyX5Lqs5pu0576O5LqS5Yqo5L+h5oGv56eR5oqA 5pyJ6ZmQ5YWs5Y+4MREwDwYDVQQEEwgxMDgxMzM4OTCCASIwDQYJKoZIhvcNAQEB BQADggEPADCCAQoCggEBAO3V0Or4bOGIaEDbUfYei6kLZy1QP3pOWqc3qsQIGyvX glJk8kGVOA6V1sjPnFZjJa6c2fqxWgTjSxMqR0SS6dE9frdCrOg2dquD7po21HkX fQhYaJPwdzsl8qDkYpOeuY3OJ+Ke0wP1L3Z1JWSet4xdMltKzfrr+/IGu3oZwcRN f3wQJZM4zhq7qO9pBgfExj9PizbkkZGKNIO0slmdqRjoNv8+I0Z3qNOVGx9JNE+S bn+/9GphE7wVUHb7Vzv+1vbP8m5ErT9tYN6Mi0DkS3WqIDMSHREuJQBOeNZmUBpm m1gknRl1L0TnCAY4/oDjv8hus4e2/o1TYZIZxd0zzMsCAwEAAaOCAUYwggFCMAkG A1UdEwQCMAAwLAYJYIZIAYb4QgENBB8WHSJDRVMtQ0EgR2VuZXJhdGUgQ2VydGlm aWNhdGUiMB0GA1UdDgQWBBSZ83HFsWnXXp6r5iiSLsK+d9MpTDCBvwYDVR0jBIG3 MIG0gBQ+BSb2ImK0FVuIzWR+sNRip+WGdKGBkKSBjTCBijELMAkGA1UEBhMCQ04x EjAQBgNVBAgTCUd1YW5nZG9uZzERMA8GA1UEBxMIU2hlbnpoZW4xEDAOBgNVBAoT B1RlbmNlbnQxDDAKBgNVBAsTA1dYRzETMBEGA1UEAxMKTW1wYXltY2hDQTEfMB0G CSqGSIb3DQEJARYQbW1wYXltY2hAdGVuY2VudIIJALtUlyu8AOhXMA4GA1UdDwEB /wQEAwIGwDAWBgNVHSUBAf8EDDAKBggrBgEFBQcDAjANBgkqhkiG9w0BAQUFAAOB gQBLiBq6evrBVixo2sRpusxMuRZ4zGf7eugLLl+dtimyGCSihuhKb+/WwYqyNBjq 73cKtVn4XO4Mro0R3w3d6ub5jlwPDWDJfY/q5VenzKzyEIjT0usb1ayE2z0A/BLP KMgCfa9b94dmHF8KH/2GhaLab/Z0ig4zJAO4bgcmQYYTjA==
-----END CERTIFICATE-----"""
M_WECHAT_NOTIFY_URL = 'http://backend.hotfix2.gmei.com/pay/wechat/notify'
CLIENT_WECHAT_APP_ID = "wx403cd28c142c7d87"
CLIENT_WECHAT_PARTNER_ID = "1302548401"
CLIENT_WECHAT_SECRET = "e821f46be6ee45e3ca80d189f989313b"
# cert
CLIENT_WECHAT_PEM_KEY = """-----BEGIN PRIVATE KEY-----
MIIEwAIBADANBgkqhkiG9w0BAQEFAASCBKowggSmAgEAAoIBAQDyo/sKm8Be27Sn WLyoRdn8svW9WiGgAyI8876l+ESyCoYqpeTGZvmeDKdvalky/WapF2SQAqvumJjf UKdt8h6r+QwqmoHnsBkuATQdrv9XiU9Uzi7W/U+AxVLINpf85NSwtm2i/PC+hogY TsEUAFaFMGnautNYuK+TYwUw1Ek8kb3Q6dZ8Rz+1gTVA+kEggnbgkFqv8qTzDcxs BtAEwoVPBndlizSvTgwbZ9N5lkpKkNTkdFOi3fqlyfixUAr0u5xIUcSdE2LX0rlx u1p6YnImsSZppGAN5bAMyePvZli7MoPd7xjQrS99YR0FyZCGrNAUCPBOQfqDDLqQ 6nBfs7htAgMBAAECggEBAOi5xZCwQPv6yTR1lUXk8adB0xfR+kxqlQ1XUHYKQYFv PK5tPZfarvMb+gCQRYv1puDqUgcauOP5sy8GQgDfaPHTxwqZ9Z1Ot2f7uYv7DGhe iBu0QxLsFbRSDwt/6ZmjtijkYRYie5qSmLiP2PshM9s9y1oDNbF0Otsn75OdGb2f wg+FO1qeawo5e3uJ8DgZfJqB+0anocTXZxGpfH0N40NyedfXb7OqfGuYrN8XFke4 WL0B+MkPEKVfUZvj1PA1rVZkUlA+kKTEqRImoXggM/AY7JW3O5EtHNy6Bb5zjozR 4Mc4ky2OKxhgxIky/Q76aTWm1V3Rr9mKcRDmTyEOo6ECgYEA+qgnTWG8NR/yOJcj wSgyCRhd2ARxoMRnWVuRWuJMAS4EYwkjh/yeeI3VJsUmTZTC4nfmZkIyPcP7kiVK iVV1UqVKysszkzqGvLRjX9PZCpDNb+wcu8ualu2UJmwnqephYfI3D0GkpBqL9kjm QbnJ/OVkfcval09d992it8QfiRkCgYEA99AU7tzJe+PBKaUxguwmhuj3md519zNu RKoxgnMo/iWej2SjfrKOBIsIAB3qAD3txs8d4vjUADVnoN+9g/vumBMwMBGXN5x1 8JmWX3w2IscQDoNYpYxeAtuNWz8z3KjUkDLL8lo8FKarrBM7stkfT36DoEdc8U99 PkpSz4sMkHUCgYEAn5d2xqcmzPBVKcDZa/9qtC3GemaB7ml+n/9UMfiJierBski8 TbYDNCCiCThXZegEmWrb0FnvYTIqN+f0aDJ4K7HASBRO9zu5U+bKqtXYiAigNNWx icRd3iDQRhJwwpfPfyxX8CfMawvX92x85nYjbBil/g5QVCydWNbN5pFBvukCgYEA 30qTUheHRSaXapr63elDXdSVJgQZb0DcXuqr6csyaK4lDTe1SfhBlz5fWxuZOdaT ZcxCNb3X6Mg2M/LmpQJgno7LoMR46RcF/mGl6SvW68dKZIldWu37179Uw59Tb8SA o93hfuJnuIPltAswg5q4Z7yrhcRHrvfc9j+qFnBIRfECgYEA3OPwRBbIFUa8ADdl vXe4RZejnGSyHFs3hBM3NcQx/2Du1PVbFlCgvi7nKvxYtmGFmt1f+1rjsbaET0nI nAhv0XdbRyMwoGb5uWRRIh5RJs0ttxwMKKiDEwznMDK3BCyxRR9IcGT0ZTEMiJWp +nZTnkF9fviEyG88Ttx8A2pqMYQ=
-----END PRIVATE KEY-----"""
CLIENT_WECHAT_PEM_CERT = """-----BEGIN CERTIFICATE-----
MIIEaDCCA9GgAwIBAgIDDkNDMA0GCSqGSIb3DQEBBQUAMIGKMQswCQYDVQQGEwJD TjESMBAGA1UECBMJR3Vhbmdkb25nMREwDwYDVQQHEwhTaGVuemhlbjEQMA4GA1UE ChMHVGVuY2VudDEMMAoGA1UECxMDV1hHMRMwEQYDVQQDEwpNbXBheW1jaENBMR8w HQYJKoZIhvcNAQkBFhBtbXBheW1jaEB0ZW5jZW50MB4XDTE2MDEwNDA3MTAwN1oX DTI2MDEwMTA3MTAwN1owgZgxCzAJBgNVBAYTAkNOMRIwEAYDVQQIEwlHdWFuZ2Rv bmcxETAPBgNVBAcTCFNoZW56aGVuMRAwDgYDVQQKEwdUZW5jZW50MQ4wDAYDVQQL EwVNTVBheTEtMCsGA1UEAxQk5YyX5Lqs5a6M576O5Yib5oSP56eR5oqA5pyJ6ZmQ 5YWs5Y+4MREwDwYDVQQEEwgxMTE1Mzc1MjCCASIwDQYJKoZIhvcNAQEBBQADggEP ADCCAQoCggEBAPKj+wqbwF7btKdYvKhF2fyy9b1aIaADIjzzvqX4RLIKhiql5MZm +Z4Mp29qWTL9ZqkXZJACq+6YmN9Qp23yHqv5DCqageewGS4BNB2u/1eJT1TOLtb9 T4DFUsg2l/zk1LC2baL88L6GiBhOwRQAVoUwadq601i4r5NjBTDUSTyRvdDp1nxH P7WBNUD6QSCCduCQWq/ypPMNzGwG0ATChU8Gd2WLNK9ODBtn03mWSkqQ1OR0U6Ld +qXJ+LFQCvS7nEhRxJ0TYtfSuXG7WnpiciaxJmmkYA3lsAzJ4+9mWLsyg93vGNCt L31hHQXJkIas0BQI8E5B+oMMupDqcF+zuG0CAwEAAaOCAUYwggFCMAkGA1UdEwQC MAAwLAYJYIZIAYb4QgENBB8WHSJDRVMtQ0EgR2VuZXJhdGUgQ2VydGlmaWNhdGUi MB0GA1UdDgQWBBRV2ZXPMoFirV2Neqaxyi0Gj//K7zCBvwYDVR0jBIG3MIG0gBQ+ BSb2ImK0FVuIzWR+sNRip+WGdKGBkKSBjTCBijELMAkGA1UEBhMCQ04xEjAQBgNV BAgTCUd1YW5nZG9uZzERMA8GA1UEBxMIU2hlbnpoZW4xEDAOBgNVBAoTB1RlbmNl bnQxDDAKBgNVBAsTA1dYRzETMBEGA1UEAxMKTW1wYXltY2hDQTEfMB0GCSqGSIb3 DQEJARYQbW1wYXltY2hAdGVuY2VudIIJALtUlyu8AOhXMA4GA1UdDwEB/wQEAwIG wDAWBgNVHSUBAf8EDDAKBggrBgEFBQcDAjANBgkqhkiG9w0BAQUFAAOBgQCImJqb 5uRuDpT+dyhJmAXkk3DMqwKMVOcGV/B/+VmahWMPMHAggjEsg+sEu3orO5gqHook RPIqONBR/YLU4VJORgj3zia6Z5RIzZlJo3tOXNYFVX+i2FwyqriyOSTE9U9sGBV2 8w9kpFJGt1yndN9++0mwOY4qTNgL6LHWEwSgHQ==
-----END CERTIFICATE-----"""
# ====================================================================================================
# ============================================支付宝===================================================
# ====================================================================================================
# 合作身份者ID,以2088开头的16位纯数字
ALIPAY_PARTNER = '2088211612339882'
# 签约支付宝账号或卖家支付宝帐户
ALIPAY_SELLER_EMAIL = 'zhengxuan@wanmeizhensuo.com'
# MD5 密钥
ALIPAY_MD5_KEY = "2894fddi6kahmpj56n008le81gjnvdwp"
# ===ALIPAY_APP_CONFIG===START
# https://doc.open.alipay.com/doc2/detail.htm?treeId=204&articleId=105465&docType=1
ALIPAY_APP_APP_ID = "2016051901420550"
# 商家的私钥
ALIPAY_APP_MY_PRIVATE_KEY = """-----BEGIN PRIVATE KEY-----
MIICXwIBAAKBgQDkGyj52wT/zQuRa1mAKwAkq09JZDCGcoBc4iLUchNvyAC8KJLTNDRMI+hA8VCsQv4s+usgvQvfjNYq4/Ryoh7mQbrVrFBc38IfPhbmNbHsczTX5+ZR8/LKcA3yNcJYbbAleFuqR89kxxo93rtBLsP0lWUn1R76MV15BOKw5UiXlwIDAQABAoGBAN2x4/ZKPqaa02ZnLhpaMI5zDOEohdz1xfoAMpfFs0xN1yEIUgMBVt61e1I69wwlJEH1MLal5bdEexY+bONI27taE5AkWb2vF3PMjt3TeyJCrxtDtq78Vxk/oXQA/9DaPz0Fa0UbDgIZPZZGVLLol3VRg88x00dRK+cQvgZ1jjhRAkEA+tSct5C/7DziNbGKf/xfKHYzciEb75Y/JF6JDdhHTHh/sDFYRspQoyEfhAqHXygRB0kiGoURlNGz/hXECKF1qQJBAOjOpz3yHyT1o3T1aUTfIZA0zT486Bj8yhiULrYqOrISQqWWXXktDnwM1JhXGgxmtCtdywCkHuiRQDT/DBvHaz8CQQC2/c2njg62hmRxz6i/Xpr9pd46cTU0QWSnX+CVHShG/dIJ9LX2TzstB8k6R4QjQ9PIgO5Ecrg03hh2UeLGeSShAkEAhYYg/bJkknogKfCnU8z2HxNptAySweIat0YmFGzcBU3b08UOD3X8HMHvHQC3++zb4ROGXvPClnjYbozpkPUrWQJBAMBZoVZtntWxD3akZBbBO9dfXktrlxagvWNWtSPnDfDsdn+qRRQr6ln4TBkLk/nDYQSiLtFzBxuyrrtCncfbcnc=
-----END PRIVATE KEY-----"""
# 支付宝针对商家的公钥
ALIPAY_APP_ALI_PUBLIC_KEY = """-----BEGIN PUBLIC KEY-----
MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDDI6d306Q8fIfCOaTXyiUeJHkrIvYISRcc73s3vF1ZT7XN8RNPwJxo8pWaJMmvyTn9N4HQ632qJBVHf8sxHi/fEsraprwCtzvzQETrNRwVxLO5jVmRGi60j8Ue1efIlzPXV9je9mkjzOmdssymZkh2QhUrCmZYI/FCEa3/cNMW0QIDAQAB
-----END PUBLIC KEY-----"""
# 旧的商家的私钥,在原有接口被废弃在之后可以删除相关的代码和这里的配置
ALIPAY_APP_OLD_MY_PRIVATE_KEY = """-----BEGIN PRIVATE KEY-----
MIICdgIBADANBgkqhkiG9w0BAQEFAASCAmAwggJcAgEAAoGBALY37P8VQobI+24mwEjDV/8aAPNnS9MXJW0ZC7fnWXajJOue4X7/L+qDaWpTj/cptpFLomsl6IKAxMSefBO0CGpkjI1Oe0G9tg+Ki4Szk7CdaYNfhhRpyFwOhKiGgEKSCmboinOkc8yuD02kdSfrhzOrmN2I2KVMBjFW7V8JczN/AgMBAAECgYEAk8If3OzJaHCbacPkklxNA+B7OuTdWIvhXmk71mG0av56FtJcOlYF7d2n4n9mM19Q2tsBFm/D7ecrJ+D37iZD11vZmmwIOl5/CwOf9MUwP3ENG7S1Ax/CIZaM5MuwUs4sLXgMKaImPXq4u7UWqVuxwH+iyokXxz/uxCMf+0qFPSkCQQDc7DNZhDqh1M2ZDqhliCSP/nn8CHX6BYRIEbMQW7g1V59TOr89N8ht3FZ5b3dVItielU4dRez7o4BPYThVL6udAkEA0yaF9/BYKg9LBAPJxvnNZWu1GmabpMmawx45B4jdoTLrK+wwGPwORBIyZ+og5M0IRTW5w42ECM/Fi+KAjU82ywJAJc/jphGku2gh3G2O0vnvUBn9JO8JykZBcthcrpMUP0UFBwjKDJ9Mlckdn+E9KnwxWUsyuH3sZtGAN5XrP2FOXQJAdlUIj0LqpeecKsvUsOYd7dDG1dzbLSauzNqLK2XQjx5yHVNoQRhBBnUMOqBDfvZIxECvsqAEdsu58gMl+AuEsQJAZ6r6GHJLyQEvz5RJ8KeYnAK0FxrH76gfCPE1luLf/DVifYIopfnBbB2TczbpxEwmC1K0fk3K6HdbQnpU5o67QQ==
-----END PRIVATE KEY-----"""
# 旧的支付宝针对商家的公钥,在原有接口被废弃在之后可以删除相关的代码和这里的配置
ALIPAY_APP_OLD_ALI_PUBLIC_KEY = """-----BEGIN PUBLIC KEY-----
MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCnxj/9qwVfgoUh/y2W89L6BkRAFljhNhgPdyPuBV64bfQNN1PjbCzkIM6qRdKBoLPXmKKMiFYnkd6rAoprih3/PrQEB/VsW8OoM8fxn67UDYuyBTqA23MML9q1+ilIZwBC2AQ2UBVOrFXfFl75p6/B5KsiNG9zpgmLCUYuLkxpLQIDAQAB
-----END PUBLIC KEY-----"""
# ===ALIPAY_APP_CONFIG===END
# 买单的支付通知URL前缀,请保证最后一个字符是"/"
MAIDAN_PAY_NOTIFY_URL_BASE = "http://backend.hotfix2.gengmei.cc/pay/maidan/notify/"
# ====================================================================================================
# ============================================yinuo==============================================
# ====================================================================================================
YINUO_SECRECT = 'kwR58f2BNLWemSmOEDsi9mJReWpHfGo8'
YINUO_USER_ID = 'KOQ6CNWM'
YINUO_CREATE_URL = 'https://api-sandbox.yinuobaoxian.com/partner/order/create'
YINUO_PAY_URL = 'https://api-sandbox.yinuobaoxian.com/partner/order/pay-balance'
YINUO_PREMIUM = 5
YINUO_PRODUCT_ID = '8YMWI5QZ'
YINUO_PLAN = 'A'
# ====================================================================================================
# ============================================Apple Pay===============================================
# ====================================================================================================
APPLEPAY_MD5_KEY = 'v99#l2*hy4omRGqp$#c5OJJ77KOK6mz^'
OID_PARTNER = '201603031000747503'
APPLE_PROXIES = "https://127.0.0.1/"
TEST_RUNNER = "common.utils.NoDbTestRunner"
DEBUG = False
SERVER_HOST = "cadus.cadus.env" # cadus服务地址
NOTIFY_URL_BASE = "http://exchange.env.wanmeizhensuo.com/test/gateway/cadus/" # 最后不要有 /
WECHAT_PREPAYID_CACHETIME = 5 # 5秒过期
[redis]
hostAndPort="192.168.168.142"
db=23
[server]
httpHostAndPort = 0.0.0.0:8109
[delay]
delay=2
[like_rate]
low_speed = 1
high_speed = 11
like_loop_time = 120
[debug]
is_debug=0
# coding=utf-8
from doris.base import *
from .log_settings import *
from celery import *
from celery.schedules import crontab
import pyssdb
CELERY_BROKER_URL = 'redis://192.168.168.142/0'
REDIS_URL = 'redis://192.168.168.142/1'
ES_V2_HOSTS = [
{'host': '192.168.168.142', 'port': 9200},
]
ES_INDEX_PREFIX = 'gm_test'
COUNT_LIMIT = 50
REDIS = {
'doctor': {'host': '192.168.168.142', 'port': 6379, 'db': 1,},
}
RAVEN_CONFIG = {
'dsn': 'http://29e77782db3c4429857cb1b6d69d9463:d55eafe28ae64f6e8c4a82fa3bc50fdd@sentry.gengmei.cc/80',
}
CELERYBEAT_SCHEDULE = {
'doris_ trans2es': {
'task': 'rank.tasks.doctor_statdata_2_cache',
# 'schedule': timedelta(seconds=1),
'schedule': crontab(hour=2, minute=0),
},
'doris_cal_device_interest': {
'task': 'recommend.tasks.cal_userinterest_rank',
# 'schedule': timedelta(seconds=1),
'schedule': crontab(hour=2, minute=0),
},
'doris_cal_servicehot_rank': {
'task': 'recommend.tasks.cal_servicehot_rank',
# 'schedule': timedelta(seconds=1),
'schedule': crontab(hour=2, minute=0),
}
}
SSDB_CLIENT = pyssdb.Client(host='192.168.168.143', port=8888)
# coding:utf8
import pyssdb
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'feed_prod',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3407',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
},
'gaia': {
'ENGINE': 'django.db.backends.mysql',
'NAME': 'zhengxing',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
},
'mimas': {
'ENGINE': 'django.db.backends.mysql',
'NAME': 'mimas_prod',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3308',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
}
}
SSDB_CLIENT = pyssdb.Client(host='192.168.168.143', port=8888)
CELERY_BROKER_URL = 'redis://192.168.168.142/0'
CELERY_BEAT_SCHEDULE = {}
# coding:utf8
import pyssdb
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'feed_prod',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3407',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
},
'gaia': {
'ENGINE': 'django.db.backends.mysql',
'NAME': 'zhengxing',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
},
'mimas': {
'ENGINE': 'django.db.backends.mysql',
'NAME': 'mimas_prod',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3308',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
}
}
SSDB_CLIENT = pyssdb.Client(host='192.168.168.143', port=8888)
CELERY_BROKER_URL = 'redis://192.168.168.142/0'
CELERY_BEAT_SCHEDULE = {}
# coding=utf8
"""
Django settings for flag_ship project.
For more information on this file, see
https://docs.djangoproject.com/en/1.7/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/1.7/ref/settings/
"""
# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
import os
import helios
import helios.rpc
BASE_DIR = os.path.dirname(os.path.dirname(__file__))
# Quick-start development settings - unsuitable for production
# See https://docs.djangoproject.com/en/1.7/howto/deployment/checklist/
# SECURITY WARNING: keep the secret key used in production secret!
SECRET_KEY = 'zng=%a*!bokrd#=%%rawhyp0)1qr15i#x7m@hetqd%z_+kv599'
# SECURITY WARNING: don't run with debug turned on in production!
DEBUG = True
TEMPLATE_DEBUG = DEBUG
ALLOWED_HOSTS = ['*']
# Application definition
INSTALLED_APPS = (
'django.contrib.contenttypes',
'django.contrib.staticfiles',
'django_jinja',
'helios',
'viewbase',
'app',
)
MIDDLEWARE_CLASSES = (
'django.contrib.sessions.middleware.SessionMiddleware',
)
SESSION_ENGINE = 'django.contrib.sessions.backends.cache'
ROOT_URLCONF = 'flag_ship.urls'
WSGI_APPLICATION = 'flag_ship.wsgi.application'
# Database
# https://docs.djangoproject.com/en/1.7/ref/settings/#databases
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.sqlite3',
'NAME': ':memory:',
}
}
# Internationalization
# https://docs.djangoproject.com/en/1.7/topics/i18n/
LANGUAGE_CODE = 'en-us'
TIME_ZONE = 'Asia/Shanghai'
USE_I18N = True
USE_L10N = True
USE_TZ = True
# Static files (CSS, JavaScript, Images)
# https://docs.djangoproject.com/en/1.7/howto/static-files/
STATIC_URL = '/static/'
STATICFILES_DIRS = (
('', os.path.join(BASE_DIR, '..', 'frontend', 'static')),
)
STATICFILES_FINDERS = (
'django.contrib.staticfiles.finders.FileSystemFinder',
'django.contrib.staticfiles.finders.AppDirectoriesFinder',
)
TEMPLATE_LOADERS = (
'django_jinja.loaders.FileSystemLoader',
'django_jinja.loaders.AppLoader',
)
TEMPLATE_DIRS = (
os.path.join(BASE_DIR, '..', 'frontend', 'templates'),
)
DEFAULT_JINJA2_TEMPLATE_EXTENSION = ''
RPC_URL = 'http://rpc.test.gengmei.cc/api/'
# RPC_URL = 'http://127.0.0.1:8001/api/'
RPC_SECRET = ''
RPC_INVOKER = helios.rpc.create_default_invoker(debug=DEBUG)
APP_CONFIG = {
'url_base': 'http://localhost:8000',
'app_download_page': '/app/download',
'mobile_index_page': 'http://m.gengmei.cc/',
'qiniu_host': 'http://pic.gengmei.cc/',
'default_paging_size': 20,
}
# 顶部导航Tabs
TAB_INDEX = '/'
TAB_TAGS = '/diary_list'
TAB_PROMOTION = '/promotion_list'
TAB_WIKI = '/wiki_list'
TAB_EXPERT = '/expert_list'
TAB_POST = '/post_list'
TAB_HOSPITAL = '/hospital_list'
TABS = [{'name': u'首页', 'url': TAB_INDEX},
{'name': u'项目', 'url': TAB_TAGS},
{'name': u'美购', 'url': TAB_PROMOTION},
{'name': u'百科', 'url': TAB_WIKI},
{'name': u'专家', 'url': TAB_EXPERT},
{'name': u'医院', 'url': TAB_HOSPITAL},
{'name': u'健康资讯', 'url': TAB_POST},
]
# 首页默认显示的Tag
FRONT_DEFAULT_TAGS = [{'id': 1, 'color': '#ffd34e', 'position': 1, 'icon': 'http://pic.gengmei.cc/2014/12/24/b3076876ff'},
{'id': 2, 'color': '#ffae5e', 'position': 2, 'icon': 'http://pic.gengmei.cc/2014/12/24/2624935b91'},
{'id': 3, 'color': '#ff6c8f', 'position': 4, 'icon': 'http://pic.gengmei.cc/2014/12/24/e7f379e88f'},
{'id': 7, 'color': '#9290f6', 'position': 5, 'icon': 'http://pic.gengmei.cc/2014/12/24/0ef5dafde4'},
{'id': 4, 'color': '#5e9bff', 'position': 6, 'icon': 'http://pic.gengmei.cc/2014/12/24/1eea8df935'},
{'id': 5, 'color': '#5dcdfc', 'position': 7, 'icon': 'http://pic.gengmei.cc/2014/12/24/85df448756'}]
# 医生默认头像
DEFAULT_EXPERT_PORTRAIT = 'http://pic.gengmei.cc/2015/03/13/fbde86be25-web'
# TDK
TDK = {
'title': u'更美APP官网—整形整容微整形社区与特卖平台',
'keywords': u'更美,更美APP,更美APP官网,更美网,整形,整容,微整形',
'description': u'更美APP如今是中国最大的医学美容与消费医疗服务平台,提供生活消费类医疗服务,品类包括整形、齿科、眼科、抗衰老、营养、心理(计划中)等。'
}
# Redis配置
CACHES = {
"default": {
"BACKEND": "django_redis.cache.RedisCache",
"LOCATION": "redis://192.168.168.142/1",
"OPTIONS": {
"CLIENT_CLASS": "django_redis.client.DefaultClient",
}
}
}
# 百度阿拉丁KEY
ALADING_KEY = 't7bu89c9ys4ix5u7o6t7v8kuxbtos1qy'
# coding: utf-8
import os
import helios.rpc
DEBUG = True
TEMPLATE_DEBUG = DEBUG
ALLOWED_HOST = ['*']
# RPC_URL = 'http://rpc.hotfix2.gmei.com/api/'
RPC_URL = 'http://rpc.test.gmei.com/api/'
# RPC_URL = 'http://rpc.dev.gmei.com/api/'
#RPC_URL = 'http://127.0.0.1:8001/api/'
RPC_SECRET = ''
RPC_CLIENT = helios.rpc.RPCFactory(
RPC_URL,
RPC_SECRET,
debug=DEBUG,
debug_dump_curl=True,
).create_invoker()
# RPC_CLIENT = helios.rpc.create_default_invoker(debug=DEBUG)
APP_CONFIG = {
'url_base': 'http://127.0.0.1:9000',
'app_download_page': '/app/download',
'mobile_index_page': 'http://ship-service.default/',
'qiniu_host': 'http://pic.gmei.com/',
'default_paging_size': 20,
'qiniu_prefix': 'http://pic.gmei.com',
'all_category_icon_url': 'http://hera.s.gmei.com/img/quanbufenlei.png',
'session_cookie_name': 'shipsessionid',
'cross_domain': '.gmei.com',
}
class APP_CONFIG_CLASS(object):
qiniu_prefix = 'http://pic.gmei.com'
all_category_icon_url = 'http://hera.s.gmei.com/img/quanbufenlei.png'
session_cookie_name = 'shipsessionid'
# cross_domain = '.gmei.com'
cross_domain = 'http://127.0.0.1:9000'
CACHES = {
"default": {
"BACKEND": "django_redis.cache.RedisCache",
"LOCATION": "redis://192.168.168.142/1",
"OPTIONS": {
"CLIENT_CLASS": "django_redis.client.DefaultClient",
}
}
}
# Database
# https://docs.djangoproject.com/en/1.7/ref/settings/#databases
# NOTE:django
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.sqlite3',
'NAME': ':memory:',
}
}
APPEND_SLASH = False
BASE_DIR = os.path.dirname(os.path.dirname(__file__))
TEMPLATE_DIRS = (
os.path.join(BASE_DIR, '..', 'frontend', 'templates'),
)
TEMPLATES = [
{
'BACKEND': 'django.template.backends.jinja2.Jinja2',
'DIRS': (
TEMPLATE_DIRS
),
'APP_DIRS': True,
'OPTIONS': {
'environment': 'app.utils.environment',
},
}
]
STATICFILES_DIRS = (
os.path.join(BASE_DIR, '..', 'frontend', 'static'),
)
STATIC_URL = '/static/'
STATIC_ROOT = ''
# STATIC_ROOT = os.path.join(BASE_DIR, '..', 'frontend', 'static')
# STATIC_ROOT = '/srv/apps/flag-ship/frontend/static'
# -*- coding:utf-8 -*-
from datetime import timedelta
from celery.schedules import crontab
KEFU_PERSION_ID = 'a3c1087a1bdd11e682b70242c0a8020b'
QUESTION_SCORE_WEIGHT = {
'time_score_weight': 1, #
'answers_num_score_weight':1,
'answer_views_score_weight':1,
'answer_likes_score_weight':1,
'question_view_score_weight':1,
'question_answer_likes_score_weight':1,
}
ALLOWED_HOSEPT_BLACK_LIST = [
'00000000-0000-0000-0000-000000000000',
]
LIVE_REDIS = {'host': '192.168.168.142', 'port': 6379, 'db': 4}
SECRET_KEY = 'fl-lv3j^czg(dupo@hbs(+_+djby9zelwt&rh71@b1x*ptmj4#(^' #dev
DEBUG = True
TEMPLATE_DEBUG = True
RAVEN_CONFIG = {
'dsn': 'http://c5b4ede52bc6452182565b529735a090:0324e8fff118445a9b38576213b8e759@sentry.igengmei.com/120',
}
SITE_ID = 1
USE_DOC = False
TEMPLATES = []
GIFT_LOWER_LIMIT = 10000
GAME_WISHTREE_COUPON_ID = 1196
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'zhengxing_test', # zhengxing_test test-zhengxing_for_ascle2
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
},
'slave':{
'ENGINE': 'django.db.backends.mysql',
'NAME': 'zhengxing_test', # zhengxing_test
'USER': 'work',
'PASSWORD': 'Gengmei1',
#'HOST': '127.0.0.1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
},
'hera_test': {
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'hera_test',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
},
'verita': {
'ENGINE': 'django.db.backends.mysql',
'NAME': 'verita_test',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
},
'mimas': {
'ENGINE': 'django.db.backends.mysql',
'NAME': 'mimas_test',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
},
'bran':{
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'bran_test',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
},
'message': {
'ENGINE': 'django.db.backends.mysql',
'NAME': 'whisper_test',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
}
}
SLAVE_DB_NAME = 'slave'
HERA_READ_DB = 'slave'
MIMAS_SLAVE_DB_NAME = 'mimas'
# ====================================================================================================
# =====================================GAIA_AUTHENTICATION============================================
# ====================================================================================================
GAIA_AUTHENTICATION = {
'CHECK_MODE': 'PERMISSIVE',
'SERVER_KEYS': [
'basic:334+LrHY+Wh4IREkC4xjQcJ6fpIwlsH6HR8MKFVEH5LiyvqYq4QocqoNS7lcx23RO4v2FcB6YYoxMoEJhYoYpQ==',
# pengfei, for ship
'basic:c3AUKzE4iaGc5SBtkm3zMbjepw+vn7VHr/5fXaupEAo/HBeeVk6w+4EWEubwF1K9j6KSckd17hpBpQkNr9+uoA==',
# chuncheng, for op_back
'basic:M21gQkp0vWmDxlB5wVsIGCgbjdcshCsYaTgl4Rq0E6ug6Ma2teM9tpGCf5TZHsCGGC4cGQ4as9N3KmrDPQ43gA==',
# pengfei, for wanmei_backend
'basic:ZXhlV5AFrx7jy7vfwCFiANBlJyVK2kHfiZDVkeKlRkxjOlUb1euhRCbazG2aPdHkMNn8a+D/vqdZSYCj9qhpig==',
# pengfei, for flag-ship
],
}
# ====================================================================================================
# ============================================REDIS===================================================
# ====================================================================================================
# BROKER_URL = 'redis://test-redis:6379/13'
BROKER_URL = 'redis://192.168.168.142/13'
BROKER_TRANSPORT_OPTIONS = {'visibility_timeout': 60 * 60 * 24 * 3} # 3days. Make sure that colleagues have knew that
REDIS = {
'doctor': {'host': '192.168.168.142', 'port': 6379, 'db': 0},
'hospital': {'host': '192.168.168.142', 'port': 6379, 'db': 1},
'view': {'host': '192.168.168.142', 'port': 6379, 'db': 2},
'user_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 5},
'conversation_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 6},
'tag_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 12},
'diary': {'host': '192.168.168.142', 'port': 6379, 'db': 4},
'page_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 15},
'coupon_gift': {'host': '192.168.168.142', 'port': 6379, 'db': 10},
'social_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 11},
'vote_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 11},
'wechat': {'host': '192.168.168.142', 'port': 6379, 'db': 11},
'game': {'host': '192.168.168.142', 'port': 6379, 'db': 4},
'resys_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 3},
}
# DEFAULT_REDIS = {'host': 'test-redis', 'port': 6379, 'db': 14}
DEFAULT_REDIS = {'host': '192.168.168.142', 'port': 6379, 'db': 14}
# ====================================================================================================
# ============================================极光推送=================================================
# ====================================================================================================
BIG_PUSH_DURATION = 1
PUSH_STAT_DELAY = 60
USER_JPUSH_APP_KEY = "9e779399e200529a63722da7"
USER_JPUSH_MASTER_SECRET = "38a0a35dc8bc96b509fc61e1"
DOCTOR_JPUSH_APP_KEY = "5c450e73f736580543d0bd4e"
DOCTOR_JPUSH_MASTER_SECRET = "688b209acae48381ece1f3f8"
JPUSH_IOS_OPTIONS = {
"apns_production": False,
}
IPHONE_USE_SANDBOX = True
# ====================================================================================================
# ============================================ES======================================================
# ====================================================================================================
ES_HOSTS = [{'host': '192.168.168.142', 'port': 9200}]
ES_V2_HOSTS = [
{'host': '192.168.168.142', 'port': 9200},
]
TALOS_ES_HOSTS = [
{'host': '192.168.168.142', 'port': 9200},
]
ES_INDEX_PREFIX = 'gm_test'
ES_READ_INDEX = 'gm_test_read'
ES_WRITE_INDEX = 'gm_test_write'
ES_CONSTS = {
'TAG_ID_DIRECTOR_RECOMMEND': 1142, # "所长精选" tag id
'TAG_ID_POPULAR': 1202, # "热门讨论" tag id
'TAG_ID_POPULAR_RECOMMEND': 1203, # "热门推荐" tag id
'TAG_ID_DIARY_WITH_SERVICE': 1144, # "美购日记" tag id
}
# 私信 ES
#ES_MSG_HOSTS = [{'host': 'dev-es', 'port': 9200}]
#ES_MSG_READ_INDEX = 'gm_msg_test_read'
#ES_MSG_WRITE_INDEX = 'gm_msg_test_write'
ES_MSG = {
'order': ['db2'],
'database': [{
'name': 'db1',
'es_version': 'v1',
'hosts': [{'host': '192.168.168.142', 'port': 9200}],
'table': [{
'name': 'conversation',
'index': 'gm_msg_test',
'doc_type': 'conversation',
}, {
'name': 'message',
'index': 'gm_msg_test',
'doc_type': 'message',
}]
}, {
'name': 'db2',
'es_version': 'v2',
'hosts': [
{'host': '192.168.168.142', 'port': 9200},
],
'table': [{
'name': 'conversation',
'index': 'gm_msg_test-conversation',
'doc_type': 'conversation',
}, {
'name': 'message',
'index': 'gm_msg_test-message',
'doc_type': 'message',
}]
},{
'name': 'db3',
'es_version': 'v2',
'hosts': [
{'host': '192.168.168.142', 'port': 9200}
],
'table': [{
'name': 'conversation',
'index': 'gm_msg_test-conversation',
'doc_type': 'conversation',
}, {
'name': 'message',
'index': 'gm_msg_test-message',
'doc_type': 'message',
}]
}]
}
# ====================================================================================================
# ==========================================DATA SYNC=================================================
# ====================================================================================================
DATA_SYNC = {
'redis_url': 'redis://192.168.168.142:6379/15',
'prefix': 'gaia:data-sync',
'enqueue_table_event': True,
'table_event_process_delay_list':[],
'fetch_chunk_size': 1,
}
# ====================================================================================================
# =========================================ASYNC_QUEUE================================================
# ====================================================================================================
ASYNC_QUEUE = {
'redis_url': 'redis://192.168.168.142:6379/13',
'redis_prefix': 'test-gaia:async-queue',
'logger_name': 'async_queue_logger',
'check_period_seconds': 1,
'watchdog_min_timeout': 10 * 60,
'watchdog_max_timeout': 10 * 60,
}
# ====================================================================================================
# ==========================================分期付款===================================================
# ====================================================================================================
JIKE_URL = "http://test.geexfinance.com/merchant/service"
JIKE_SERVICE_ID = "gengmei"
JIKE_SERVICE_HASH = "3710f84987aaa4f455a10f8bbb5c55e1"
JIKE_USERID = '12369'
# ====================================================================================================
# ==========================================短信======================================================
# ====================================================================================================
UCPAAS_SID = '1e180b53a6a0f901daf1b149e2a4f152'
UCPAAS_TOKEN = '8f754ea467f6d8a4036a220686876c05'
UCPAAS_APPID = 'cd723194f6ff458092118b52c5516079'
UCPAAS_SERVER_HOST = 'https://api.ucpaas.com'
UCPAAS_SERVER_PORT = ''
UCPAAS_VERSION = '2014-06-30'
UCPAAS_TEMPID = '10862'
SMS_MODEL = 'ucpaas'
ALIDAYU_HOST = u'http://gw.api.taobao.com/router/rest'
ALIDAYU_SECRET = u'aefbeb3a8d53d9c02c379bb1bed289e1'
ALIDAYU_APPKEY = u'23401193'
ALIDAYU_SIGNNAME = u'更美APP'
DEFAULT_SMS_PLATFORM = u'alidayu'
MD_HOST = u'http://sdk.entinfo.cn:8060/webservice.asmx/mt'
MD_SN = u'SDK-BBX-010-19243'
MD_PWD = u'E5D3CF92329CA75E6B794ADE37154616'
# ====================================================================================================
# ============================================微信====================================================
# ====================================================================================================
M_WECHAT_APP_ID = 'wx5dcbb1544163c77c'
M_WECHAT_PARTNER_ID = '1284132201'
M_WECHAT_SECRET = 'e821f46be6ee45e3ca80d189f989313b' # 不是微信的SECRET 是 pay.weixin.qq.com!!
M_WECHAT_PEM_KEY = "/srv/secret/m_apiclient_key.pem"
M_WECHAT_PEM_CERT = "/srv/secret/m_apiclient_cert.pem"
WXAPP_WECHAT_APP_ID = 'wx113018c998de9eaf'
WXAPP_WECHAT_PARTNER_ID = '1284132201'
WXAPP_WECHAT_SECRET = 'e821f46be6ee45e3ca80d189f989313b' # 不是微信的SECRET 是 pay.weixin.qq.com!!
WXAPP_WECHAT_PEM_KEY = "/srv/secret/wechatapp_apiclient_key.pem"
WXAPP_WECHAT_PEM_CERT = "/srv/secret/wechatapp_apiclient_cert.pem"
M_WECHAT_NOTIFY_URL = 'http://exchange.env.wanmeizhensuo.com/test/backend/pay/wechat/notify'
CLIENT_WECHAT_APP_ID = "wx403cd28c142c7d87"
CLIENT_WECHAT_PARTNER_ID = "1302548401"
CLIENT_WECHAT_SECRET = "e821f46be6ee45e3ca80d189f989313b"
# cert
CLIENT_WECHAT_PEM_KEY = "/srv/secret/client_apiclient_key.pem"
CLIENT_WECHAT_PEM_CERT = "/srv/secret/client_apiclient_cert.pem"
# ====================================================================================================
# ============================================支付宝===================================================
# ====================================================================================================
# 支付宝网关
ALIPAY_GATEWAY = "http://wappaygw.alipay.com/service/rest.htm"
# 合作身份者ID,以2088开头的16位纯数字
ALIPAY_PARTNER = '2088211612339882'
ALIPAY_SELLER_USER_ID = ALIPAY_PARTNER
# 请求参数格式
ALIPAY_FORMAT = 'xml'
# 支付宝接口版本号
ALIPAY_VERSION = "2.0"
# 签约支付宝账号或卖家支付宝帐户
ALIPAY_SELLER_EMAIL = 'zhengxuan@wanmeizhensuo.com'
# 交易过程中服务器通知的页面 要用 http://格式的完整路径,不允许加?id=123这类自定义参数
# ALIPAY_NOTIFY_URL = 'http://wanmeizhensuo.com/alipay_notify'
# ALIPAY_NOTIFY_URL = ''
ALIPAY_NOTIFY_URL = 'http://exchange.env.wanmeizhensuo.com/test/backend/api/order/purchase/xml/'
ALIPAY_NOTIFY_URL = 'http://exchange.env.wanmeizhensuo.com/test/gateway/payment/settlement/purchase/xml/'
# 付完款后跳转的页面 要用 http://格式的完整路径,不允许加?id=123这类自定义参数
# return_url的域名不能写成http://localhost/js_php_utf8/return_url.php ,否则会导致return_url执行无效
ALIPAY_CALLBACK_URL = ""
# 网站商品的展示地址,不允许加?id=123这类自定义参数
ALIPAY_SHOW_URL = 'http://wanmeizhensuo.com'
# 签名方式 不需修改
ALIPAY_SIGN_TYPE = 'MD5'
# 字符编码格式 目前支持 GBK 或 utf-8
ALIPAY_INPUT_CHARSET = 'utf-8'
# 访问模式,根据自己的服务器是否支持ssl访问,若支持请选择https;若不支持请选择http
ALIPAY_TRANSPORT = 'http'
# MD5 密钥
ALIPAY_MD5_KEY = "2894fddi6kahmpj56n008le81gjnvdwp"
ALIPAY_SERVICE_DIRECT_TRADE_CREATE = "alipay.wap.trade.create.direct"
ALIPAY_SERVICE_AUTH_EXECUTE = "alipay.wap.auth.authAndExecute"
ALIPAY_REFUND_NOTIFY_URL = 'http://exchange.env.wanmeizhensuo.com/test/gateway/payment/alipay/callback/refund'
ALIPAY_CASHBACK_NOTIFY_URL = 'http://exchange.env.wanmeizhensuo.com/test/gateway/payment/alipay/callback/cashback'
#===ALIPAY_APP_CONFIG===START
# https://doc.open.alipay.com/doc2/detail.htm?treeId=204&articleId=105465&docType=1
ALIPAY_APP_APP_ID = "2016051901420550"
ALIPAY_APP_SELLER_USER_ID = ALIPAY_SELLER_USER_ID
ALIPAY_APP_NOTIFY_URL = 'http://exchange.env.wanmeizhensuo.com/test/backend/pay/alipay/notify'
ALIPAY_APP_TIMEOUT_EXPRESS = '30m' # "30m" "12h" "3d" "1c" (???)
# 商家的私钥
ALIPAY_APP_MY_PRIVATE_KEY = """-----BEGIN PRIVATE KEY-----
MIICXwIBAAKBgQDkGyj52wT/zQuRa1mAKwAkq09JZDCGcoBc4iLUchNvyAC8KJLTNDRMI+hA8VCsQv4s+usgvQvfjNYq4/Ryoh7mQbrVrFBc38IfPhbmNbHsczTX5+ZR8/LKcA3yNcJYbbAleFuqR89kxxo93rtBLsP0lWUn1R76MV15BOKw5UiXlwIDAQABAoGBAN2x4/ZKPqaa02ZnLhpaMI5zDOEohdz1xfoAMpfFs0xN1yEIUgMBVt61e1I69wwlJEH1MLal5bdEexY+bONI27taE5AkWb2vF3PMjt3TeyJCrxtDtq78Vxk/oXQA/9DaPz0Fa0UbDgIZPZZGVLLol3VRg88x00dRK+cQvgZ1jjhRAkEA+tSct5C/7DziNbGKf/xfKHYzciEb75Y/JF6JDdhHTHh/sDFYRspQoyEfhAqHXygRB0kiGoURlNGz/hXECKF1qQJBAOjOpz3yHyT1o3T1aUTfIZA0zT486Bj8yhiULrYqOrISQqWWXXktDnwM1JhXGgxmtCtdywCkHuiRQDT/DBvHaz8CQQC2/c2njg62hmRxz6i/Xpr9pd46cTU0QWSnX+CVHShG/dIJ9LX2TzstB8k6R4QjQ9PIgO5Ecrg03hh2UeLGeSShAkEAhYYg/bJkknogKfCnU8z2HxNptAySweIat0YmFGzcBU3b08UOD3X8HMHvHQC3++zb4ROGXvPClnjYbozpkPUrWQJBAMBZoVZtntWxD3akZBbBO9dfXktrlxagvWNWtSPnDfDsdn+qRRQr6ln4TBkLk/nDYQSiLtFzBxuyrrtCncfbcnc=
-----END PRIVATE KEY-----"""
# 支付宝针对商家的公钥
ALIPAY_APP_ALI_PUBLIC_KEY = """-----BEGIN PUBLIC KEY-----
MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDDI6d306Q8fIfCOaTXyiUeJHkrIvYISRcc73s3vF1ZT7XN8RNPwJxo8pWaJMmvyTn9N4HQ632qJBVHf8sxHi/fEsraprwCtzvzQETrNRwVxLO5jVmRGi60j8Ue1efIlzPXV9je9mkjzOmdssymZkh2QhUrCmZYI/FCEa3/cNMW0QIDAQAB
-----END PUBLIC KEY-----"""
# 旧的回调地址
ALIPAY_APP_OLD_NOTIFY_URL = 'http://exchange.env.wanmeizhensuo.com/test/gateway/payment/alipay/callback'
# 旧的商家的私钥,在原有接口被废弃在之后可以删除相关的代码和这里的配置
ALIPAY_APP_OLD_MY_PRIVATE_KEY = """-----BEGIN PRIVATE KEY-----
MIICdgIBADANBgkqhkiG9w0BAQEFAASCAmAwggJcAgEAAoGBALY37P8VQobI+24mwEjDV/8aAPNnS9MXJW0ZC7fnWXajJOue4X7/L+qDaWpTj/cptpFLomsl6IKAxMSefBO0CGpkjI1Oe0G9tg+Ki4Szk7CdaYNfhhRpyFwOhKiGgEKSCmboinOkc8yuD02kdSfrhzOrmN2I2KVMBjFW7V8JczN/AgMBAAECgYEAk8If3OzJaHCbacPkklxNA+B7OuTdWIvhXmk71mG0av56FtJcOlYF7d2n4n9mM19Q2tsBFm/D7ecrJ+D37iZD11vZmmwIOl5/CwOf9MUwP3ENG7S1Ax/CIZaM5MuwUs4sLXgMKaImPXq4u7UWqVuxwH+iyokXxz/uxCMf+0qFPSkCQQDc7DNZhDqh1M2ZDqhliCSP/nn8CHX6BYRIEbMQW7g1V59TOr89N8ht3FZ5b3dVItielU4dRez7o4BPYThVL6udAkEA0yaF9/BYKg9LBAPJxvnNZWu1GmabpMmawx45B4jdoTLrK+wwGPwORBIyZ+og5M0IRTW5w42ECM/Fi+KAjU82ywJAJc/jphGku2gh3G2O0vnvUBn9JO8JykZBcthcrpMUP0UFBwjKDJ9Mlckdn+E9KnwxWUsyuH3sZtGAN5XrP2FOXQJAdlUIj0LqpeecKsvUsOYd7dDG1dzbLSauzNqLK2XQjx5yHVNoQRhBBnUMOqBDfvZIxECvsqAEdsu58gMl+AuEsQJAZ6r6GHJLyQEvz5RJ8KeYnAK0FxrH76gfCPE1luLf/DVifYIopfnBbB2TczbpxEwmC1K0fk3K6HdbQnpU5o67QQ==
-----END PRIVATE KEY-----"""
# 旧的支付宝针对商家的公钥,在原有接口被废弃在之后可以删除相关的代码和这里的配置
ALIPAY_APP_OLD_ALI_PUBLIC_KEY = """-----BEGIN PUBLIC KEY-----
MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCnxj/9qwVfgoUh/y2W89L6BkRAFljhNhgPdyPuBV64bfQNN1PjbCzkIM6qRdKBoLPXmKKMiFYnkd6rAoprih3/PrQEB/VsW8OoM8fxn67UDYuyBTqA23MML9q1+ilIZwBC2AQ2UBVOrFXfFl75p6/B5KsiNG9zpgmLCUYuLkxpLQIDAQAB
-----END PUBLIC KEY-----"""
#===ALIPAY_APP_CONFIG===END
MAIDAN_VISIBLE=True
# 买单的支付通知URL前缀,请保证最后一个字符是"/"
MAIDAN_PAY_NOTIFY_URL_BASE = "http://backend-service.default/pay/maidan/notify/"
YINUO_SECRECT = 'kwR58f2BNLWemSmOEDsi9mJReWpHfGo8'
YINUO_USER_ID = 'KOQ6CNWM'
YINUO_CREATE_URL = 'https://api-sandbox.yinuobaoxian.com/partner/order/create'
YINUO_PAY_URL = 'https://api-sandbox.yinuobaoxian.com/partner/order/pay-balance'
YINUO_PREMIUM = 5
YINUO_PRODUCT_ID = '8YMWI5QZ'
YINUO_PLAN = 'A'
# ====================================================================================================
# ============================================Apple Pay===============================================
# ====================================================================================================
APPLEPAY_MD5_KEY = 'v99#l2*hy4omRGqp$#c5OJJ77KOK6mz^'
OID_PARTNER = '201603031000747503'
APPLEPAY_PAY_NOTIFY_URL = 'http://exchange.env.wanmeizhensuo.com/test/backend/pay/apple/notify'
APPLEPAY_REFUND_URL = 'https://traderapi.lianlianpay.com/refund.htm'
APPLEPAY_REFUND_NOTIFY_URL = 'http://exchange.env.wanmeizhensuo.com/test/backend/pay/apple/callback/refund'
# ====================================================================================================
# ============================================360生活助手==============================================
# ====================================================================================================
LIFE_360_QID = "829439411"
LIFE_360_SECRET_KEY = "kGhkO9r5FrzHmLQG"
LIFE_360_GET_MOBILE_URL = "http://profile.sj.360.cn/live/get-mobile"
# ====================================================================================================
# ============================================新浪微博=================================================
# ====================================================================================================
SINA_WEIBO_GET_UID_URL = "https://api.weibo.com/oauth2/get_token_info"
INTERNAL_EMAIL = {
'address': 'bot@wanmeizhensuo.com',
'host': 'smtp.exmail.qq.com',
'username': 'bot@wanmeizhensuo.com',
'password': 'OJi17cLf1c84c9N1af37Jja0eCvx9BI6',
}
TEST_EMAIL_LIST = [
'wangjiabin@igengmei.com',
'bidan@igengmei.com',
'sunwenhui@igengmei.com',
'guojiahua@wanmeizhensuo.com',
'xuepengfei@wanmeizhensuo.com',
'maruitao@wanmeizhensuo.com',
'wangyang@wanmeizhensuo.com',
'chenxuemei@igengmei.com',
'wangnan@wanmeizhensuo.com',
'wangjinlong@wanmeizhensuo.com',
'jiaoyang@wanmeizhensuo.com',
'zhuyufeng@wanmeizhensuo.com',
'yangchuncheng@wanmeizhensuo.com',
'zhaojiajun@wanmeizhensuo.com',
'wangnan@wanmeizhensuo.com',
'qiaojinzhu@wanmeizhensuo.com',
'yilingxiao@wanmeizhensuo.com',
'renshuai@wanmeizhensuo.com',
'wangjun1@igengmei.com',
'zhangyunyu@wanmeizhensuo.com',
'linli@wanmeizhensuo.com',
'lizhenghao@igengmei.com',
'zhongchengyang@igengmei.com',
'zhaohuatian@igengmei.com',
'zhengdixun@igengmei.com',
'mayan@igengmei.com',
'yangheng@igengmei.com',
'louchaoqi@igengmei.com',
'liuyu@igengmei.com',
'wangzhuxi@igengmei.com',
'xumingming@igengmei.com',
'mayan@igengmei.com',
'lizexia@igengmei.com',
'zhangweinan@igengmei.com',
]
TEST_PHONE_EMAIL_MAP = {
'13718228007': 'zhaiguojun@wanmeizhensuo.com',
'18601965003': 'qiaojinzhu@wanmeizhensuo.com',
'15711434789': 'licong@wanmeizhensuo.com',
'15811315780': 'wangyang@wanmeizhensuo.com',
'18742441012': 'zhangyunyu@wanmeizhensuo.com',
'18363625622': 'zhaohuatian@igengmei.com',
'13720079874': 'zhengdixun@igengmei.com',
'13522130504': 'wangnan@igengmei.com',
'18610951795': 'liumiaoqi@igengmei.com',
'18701550109': 'liuhairu@igengmei.com',
'13716255042': 'yangheng@igengmei.com',
'18666826943': 'nijiahua@igengmei.com',
'18363625622': 'zhaohuatian@igengmei.com',
'15510492564': 'mayan@igengmei.com',
'18337157587': 'lizexia@igengmei.com',
}
TEST_PHONE_LIST = [
'13521626466',
'1391300267',
'13683061063',
'18601965003',
'18810225027',
'18811149976',
'18210132873',
'18345378781',
'15510789751',
'18611450809',
'15102273250',
'18363625622',
'13161047169',
'15009286557',
'13720079874',
'18610951795',
'13716255042',
'18666826943',
'18363625622',
'18610811754',
'+8201024494425',
'15010139361',
'18858517222'
]
ANONYMOUS_USER_ID = 19634221
# 统计邮件发送帐号
STATIS_EMAIL_USER = ''
STATIS_EMAIL_PSWD = ''
DOCTOR_REFUND_TIMEOUT_MINUTES = 5
__CELERYBEAT_SCHEDULE = {
'sms_service': {
'task': 'api.tasks.period_task.sms_service',
'schedule': timedelta(seconds=1200),
'args': ()
},
'link_doctor': {
'task': 'api.tasks.period_task.link_doctor',
'schedule': timedelta(minutes=6),
'args': ()
},
'share_topic_add_point': {
'task': 'api.tasks.period_task.share_topic_add_point',
'schedule': timedelta(minutes=30),
'args': ()
},
'hospital_body_sub_items': {
'task': 'api.tasks.period_task.hospital_body_sub_items',
'schedule': timedelta(days=1),
'args': ()
},
'update_diary_last_modified': {
'task': 'api.tasks.period_task.update_diary_last_modified',
'schedule': timedelta(minutes=60),
'args': ()
},
'hot_in_24hrs': {
'task': 'api.tasks.period_task.hot_in_24hrs',
'schedule': crontab(minute=0, hour='9,12,21'),
'args': ()
},
'remind_doctor_reservation': {
'task': 'api.tasks.period_task.remind_doctor_reservation',
'schedule': crontab(hour=20, minute=0),
'args': (),
},
'allocate_stat_doctor': {
'task': 'statistic.tasks.allocate_stat_doctor',
'schedule': crontab(minute=50, hour=23),
'args': ()
},
'remind_order_expired_before_15_days': {
'task': 'api.tasks.period_task.remind_order_expired_before_15_days',
'schedule': crontab(hour=14, minute=0),
'args': (),
},
'mark_reply_spam': {
'task': 'api.tasks.period_task.mark_reply_spam',
'schedule': crontab(minute=50, hour=23),
'args': (),
},
'post_order_info_to_zhida': {
'task': 'api.tasks.period_task.post_orders_info_to_zhida',
'schedule': crontab(minute=10, hour=0),
'args': ()
},
'order_evaluate_remind': {
'task': 'api.tasks.period_task.order_evaluate_remind',
'schedule': timedelta(minutes=5),
'args': ()
},
'doctor_refund_timeout': {
'task': 'api.tasks.order_task.doctor_refund_timeout',
'schedule': timedelta(minutes=5),
'args': ()
},
# ##### 统计邮件 #####
'send_conversation_stat_mail': {
'task': 'statistic.tasks.send_conversation_stat_mail',
'schedule': crontab(minute=10, hour=0),
'args': ()
},
'send_conversation_weekly_stat_mail': {
'task': 'statistic.tasks.send_conversation_weekly_stat_mail',
'schedule': crontab(minute=10, hour=0, day_of_week='tue'),
'args': ()
},
'get_phone_service': {
'task': 'api.tasks.period_task.get_phone_service',
'schedule': timedelta(minutes=10),
'args': (),
},
# ##### 统计邮件 end #####
# ##### 美购监控 #####
'judge_services': {
'task': 'api.tasks.service_task.judge_services',
'schedule': crontab(minute=50, hour=11),
'args': ()
},
# ##### 美购监控 end #####
# ##### 首页推荐feed #####
'recommend_feed': {
'task': 'api.tasks.recommend_feed_task.recommend_feed',
'schedule': timedelta(minutes=5),
'args': (),
},
# ##### 首页最新feed #####
'newest_feed': {
'task': 'api.tasks.recommend_feed_task.newest_feed',
'schedule': timedelta(minutes=5),
'args': (),
},
'remind_coupon_expire': {
'task': 'api.tasks.period_task.remind_coupon_expire',
'schedule': crontab(minute=0, hour=10),
#'schedule': timedelta(minutes=5),
'args': (),
},
# repurchase reminder
'repurchase_reminder': {
'task': 'api.tasks.period_task.repurchase_reminder',
'schedule': timedelta(minutes=30),
'args': (),
},
# recovery reminder
'recovery_reminder': {
'task': 'api.tasks.recovery_reminder_task.daily_recovery_reminder',
'schedule': crontab(minute=0, hour=20),
'args': (),
},
'period_stock_alert': {
'task': 'pay.tasks.alter_task.period_stock_alert',
# 'schedule': crontab(minute=0, hour='0,8,16'),
'schedule': timedelta(minutes=180),
'args': ()
},
# seckill notify
'seckill_notify': {
'task': 'api.tasks.period_task.seckill_notify',
'schedule': timedelta(minutes=2),
'args': (),
},
'create_sleep_user_to_redis': {
'task': 'api.tasks.user_related_tasks.create_sleep_user_to_redis',
'schedule': crontab(hour=3, minute=0),
'args': (),
},
# 计算医生的收入分
'calc_doctor_discount_one_day': {
'task': 'api.tasks.order_task.calc_doctor_discount_one_day',
'schedule': crontab(hour=3, minute=0),
'args': (),
},
'get_day_smart_rank': {
'task': 'api.tasks.period_task.get_day_smart_rank',
'schedule': crontab(hour=3, minute=0),
'args': (),
},
# 轮训七牛转码状态
'check_water_mark_video_is_finish': {
'task': 'api.tasks.live_task.check_water_mark_video_is_finish',
'schedule': timedelta(seconds=60),
'args': (),
},
# 轮训七牛转码状态(美购视频)
'check_water_mark_video_is_finish_service': {
'task': 'api.tasks.service_task.check_water_mark_video_is_finish_service',
'schedule': timedelta(seconds=60),
'args': (),
},
'save_replay_url': {
'task': 'api.tasks.live_task.save_replay_url',
'schedule': timedelta(minutes=30),
'args': (),
},
# 生成直播回放帖子
'check_live_status': {
'task': 'api.tasks.live_task.check_live_status',
'schedule': timedelta(minutes=2),
'args': (),
},
'get_tag_top_sale_service': {
'task': 'api.tasks.period_task.get_tag_top_sale_service',
'schedule': crontab(hour=3, minute=0),
'args': (),
},
'add_fake_vote_num_list': {
'task': 'api.tasks.live_task.add_fake_vote_num_list',
'schedule': timedelta(minutes=1),
'args': (),
}
# 统计crash相关关键字帖子
# 'crash_checkout': {
# 'task': 'api.tasks.crash_checkout.crash_check',
# 'schedule': timedelta(hours=1),
# 'args': (),
# },
}
ORDER_EVALUATE_REMIND_TIME=1
HERA_EMAIL_USER = 'doctor@wanmeizhensuo.com'
HERA_EMAIL_PSWD = 'xl60QkFtwJq6ziswn2a4r4pkFNozI13g'
ORDER_ARBIT_TIMEOUT_DELTA=1
BOSS = 22
SETTLEMENT_SOFT_TIMEOUT = 18000
SETTLEMENT_HARD_TIMEOUT = 72000
# add by chuncheng 5.8
PAY_EMAIL_USER = 'alert@igengmei.com'
PAY_EMAIL_USER_PWD = 'X10pfvq0uxhnky4iyvuqgz9jqetvba3U'
PAY_EMAIL_STOCK_ALTER_LIST = ['yangchuncheng@igengmei.com']
PAY_EMAIL_KAITUAN_ALTER_LIST = ['yangchuncheng@igengmei.com']
PAY_EMAIL_REFUND_ALERT_LIST = ['linli@igengmei.com']
# add by huazhu 5.8
TAG_BLACK_LIST = [971, 929, 10, 13, 2214]
BACKEND_API_HOST = 'http://backend.test.env'
PAY_EMAIL_STATEMENT_ALERT_LIST = []
# 400
CUSTOM_SERVICE_PHONE_API_ENDPOINT = 'http://222.73.121.26:8888/transfer/dealData.do'
CUSTOM_SERVICE_PHONE_API_ID = 'gmTest'
CUSTOM_SERVICE_PHONE_API_PASS = 'test'
SENTRY_CELERY_ENDPOINT = 'http://c5b4ede52bc6452182565b529735a090:0324e8fff118445a9b38576213b8e759@sentry.igengmei.com/120'
STOCK_ALERT_THRESHOLD = 3
QINIU_ACCESS_KEY = "UPCOYIJkZOMcdd9FDzpBqYjzWUh55fBpVi3AhWpL"
QINIU_SECRET_KEY = "z5YvpDDSam_JE345Z8J_f3TufzelOW2VOGNoBl9e"
FEATURE_BASE_URL = 'http://backend.test.igengmei.com/hybrid/csc/'
PUSH_NOTIFICATION_AFTER_FOLLOW_USER = True
UCPASS_DAILY_LIMIT = 5000
MAX_LOGIN_ATTEMPTES = 5000
YINGTZ_KEY_TEST = '/srv/secret/yingtz_key_test.pem'
YINGTZ_KEY_PROD = '/srv/secret/yingtz_key_prod.pem'
GMEI_PRIVATE_KEY_PKCS8 = '/srv/secret/gmei_private_key_pkcs8.pem'
YINGTZ_KEY = YINGTZ_KEY_TEST
XYMD5KEY = bytearray('74ba4d7ad1d5bc705e6c96bbf599c3f1', encoding='utf8')
QINIU_ACCESS_KEY = "UPCOYIJkZOMcdd9FDzpBqYjzWUh55fBpVi3AhWpL"
QINIU_SECRET_KEY = "z5YvpDDSam_JE345Z8J_f3TufzelOW2VOGNoBl9e"
XIAOYING_EXCEPTION_STATUS_EMAIL_LIST = [
'dingyingcai@igengmei.com',
]
NO_REPLY_EMAIL = {
'address': 'no-reply@igengmei.com',
'host': 'smtp.exmail.qq.com',
'username': 'no-reply@igengmei.com',
'password': 'MErs@bfL85Gkwkxt554w',
}
GROUPON_SERVICE_IDS = (5269672, 4667667)
DEFAULT_TAG_ATTR_ID = 1
# weixin js sdk
# 正式账号
WX_APP_ID = 'wx19c0bdd0c9e25acb'
WX_APP_SECRET = '41855cb5fd32338435b2c7dbaa400716'
WX_USER_ID = 20889703
MAIDAN_SOFT_TIMEOUT = 6400
MAIDAN_HARD_TIMEOUT = 3600
DOUBLE_EVELEN_SPECIAL = [435]
#CUSTOM_SERVICE_PHONE_NEW = '4006999227'
#CUSTOM_SERVICE_PHONE = '4006999227'
CUSTOM_SERVICE_PHONE_NEW = '4006899900'
CUSTOM_SERVICE_PHONE = '4006899900'
DEFAULT_400_VENDOR = 'xtwy'
ZTTH_CONF = {
'account': '01059658065',
'user': '6016122201',
'passwd': '88908afc672f0b599ae75b7552129a33',
'api_domain': 'http://m.icsoc.net/',
}
DEFAULT_ZONE_ICON = 'http://hera.s.igengmei.com/circleicon/2016/11/21/a699396589'
SHOW_V = False
YUNPIAN_API_KEY = '89eea91e59166314eea3d62f2912e5a9'
YUNPIAN_HOST = 'https://sms.yunpian.com'
# Jiahua Guo
SMS_USE_SEPERATED_SERVICE = True
OPEN_RESYS = True
LIVE_MSG_REDIS_FLAG = True
QINIU_LIVE_TIMEOUT = 86400
SEND_MSG_TIME = 6
TALOS_RPC_CACHE = {'host': '192.168.168.142', 'port': 6379, 'db': 14}
# TALOS_RPC_CACHE = {'host': 'redis.test.gengmei', 'port': 6379, 'db': 14}
DOCTOR_BUSINESS_CHANNAL_ID = 51
DOCTOR_USER_CAN_SEND_MSG = [
22,
23,
]
FENGXIANGGOU_COUPONGIFT_NEW_USER_GIFT_ID = 210
FENGXIANGGOU_COUPONGIFT_NEW_USER_CHANNEL_ID = 64
FENGXIANGGOU_COUPONGIFT_OLD_USER_GIFT_ID = 211
FENGXIANGGOU_COUPONGIFT_OLD_USER_CHANNEL_ID = 64
USE_DOC = True
TEMPLATES += [
{
'BACKEND': 'django.template.backends.jinja2.Jinja2',
'APP_DIRS': True,
},
]
REPLIES_READ_MYSQL_FLAG = True
DATA_TRANSFER_MARS_API_HOST = 'mars.test.gengmei.cc'
MULTI_TOPIC_TAG_ID = 5089
REMIND_USER_WRITE_DIARY_AFTER_ORDER_VALIDATE_DAYS = 0
REMIND_USER_WRITE_DIARY_AFTER_ORDER_VALIDATE_HOURS = 17
REMIND_USER_WRITE_DIARY_AFTER_ORDER_VALIDATE_MINUTES = 15
DBMW_LOGICAL_DATABASE_ID = 'zhengxing_test'
MIMAS_LOGICAL_DATABASE_ID = 'mimas_test'
QINIU_HUB_NAME = u'igengmei-live-test'
PUSH_FOR_SHOPCART_CHANNEL_ID = 87
PUSH_FOR_SHOPCART_GIFT_ID_AND_PERCENT = [(266,10),(267,7),(268,3),(269,20),(270,20),(271,20),(272,20)] # GiftId, Percent
# 推送限制
PUSH_TOTAL_LIMIT = 100 # 推送限制总条数
# 各子类限制的条数,注意:子类限制数要小于总数
PUSH_SUB_LIMIT = 100
SPECIAL_SHOW_COUPON_GIFT_IDS = [ 374 ]
POINT_MALL_LOTTERY_NOTHING_NUMBER = 35
POINT_MALL_LOTTERY_TRY_AGAIN_NUMBER = 50
ASYNC_TRIGGER_RECIEVE=False
SECKILL_NEW_SEPARATED_SERVICE = True
SECKILL_NEW_SEPARATED_HOSPITAL = True
# -*- coding:utf-8 -*-
DEBUG = False
DATABASES = { # 设置为线上的数据库地址,用户名,密码
'default': {
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'gm_face',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3307',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
},
}
FACEPP_API_KEY = 'VFZ80NNdS-zIqnlFJClzlM8iq4ZVHqa3'
FACEPP_API_SECRET = 'BxIeNVw26xas1KbcWGzL8zlF1kMy0gdj'
BROKER_URL = ['redis://192.168.168.142:6379/18', 'redis://192.168.168.142:6379/22'] # 线上redis
REDIS = {'host': '192.168.168.142', 'port': 6379, 'db': 23, } # 线上redis
# coding:utf8
import os
from .base_settings import *
import helios.rpc
DEBUG = True
STATIC_ROOT = '/srv/static/hera'
CACHES = {
'default': {
'BACKEND': 'django_redis.cache.RedisCache',
'LOCATION': 'redis://192.168.168.142:6379/5',
# 'LOCATION': 'redis://127.0.0.1:6379/5',
'TIMEOUT': 86400, # 3600 x 24
},
}
SESSION_ENGINE = 'django.contrib.sessions.backends.cache'
RPC_URL = 'http://rpc.test.gengmei.cc/api/'
RPC_KEY = 'basic:6o9sVEB6+H5U61rfZpVMioWcRRoU32uazNE3h18kwcAqOMPVdjmvQ72XxZVNLNl6RSACrgLeD7xrKYsxL1iZ6A=='
BACKEND = 'http://backend-service.default'
QINIU_ACCESS_KEY = "UPCOYIJkZOMcdd9FDzpBqYjzWUh55fBpVi3AhWpL"
QINIU_SECRET_KEY = "z5YvpDDSam_JE345Z8J_f3TufzelOW2VOGNoBl9e"
QINIU_HOST = "http://wanmeizhensuo.qiniudn.com/"
QINIU_SCOPE = 'wanmeizhensuo'
DOCTOR_URL = 'http://doctor.test.gengmei.cc'
ASCLE = 'http://doctor.test.gengmei.cc'
ES_HOSTS = [{'host': '192.168.168.142', 'port': 19200}] # [{'host':'','port': }]
ES_INDEX = 'gm_hades_test_write' # es index
ES_TYPE = 'doctor' # es type
ES_SEARCH_TIMEOUT = 60
CELERY_RESULT_BACKEND = ''
DOCTOR_BUSINESS_CHANNAL_ID = 51
EMAIL_USER = 'doctor@wanmeizhensuo.com'
EMAIL_PSWD = 'xl60QkFtwJq6ziswn2a4r4pkFNozI13g'
BROKER_URL = 'redis://192.168.168.142:6379'
# BROKER_URL = 'redis://127.0.0.1:6379'
EXPORT_LOG = {'host': '192.168.168.142', 'port': 6379, 'db': 7}
SELF_SUPPORT_WHITELIST_HOSPITAL = [
('bjrlsylmrzs', '北京瑞丽舍医疗美容诊所'),
('chqxnzhx', '重庆西南医院'),
]
USE_VERIFY_CODE = False
PUSH_COUPON_CHANNAL_ID = 93
RAVEN_CONFIG = {
'dsn': ''
}
# -*- coding:utf-8 -*-
"""
Django settings for gengmei project.
For more information on this file, see
https://docs.djangoproject.com/en/1.7/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/1.7/ref/settings/
"""
# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
import os
import logging
import helios.rpc
BASE_DIR = os.path.dirname(os.path.dirname(__file__))
_URL_PREFIX = ""
DATETIME_FORMAT = 'Y-m-d H:i:s'
DATE_FORMAT = 'Y-m-d'
# Quick-start development settings - unsuitable for production
# See https://docs.djangoproject.com/en/1.7/howto/deployment/checklist/
# SECURITY WARNING: keep the secret key used in production secret!
SECRET_KEY = 'r@ym7!c!y9&me*u873hq)t+sov)@f1l0+3u!4^rf)$3t5#d1&u'
# SECURITY WARNING: don't run with debug turned on in production!
DEBUG = False
TEMPLATE_DEBUG = True
ALLOWED_HOSTS = ['*']
# Application definition
INSTALLED_APPS = (
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'django.contrib.sites',
'api',
'fileserver',
'raven.contrib.django.raven_compat',
'django_jinja',
)
MIDDLEWARE_CLASSES = (
'django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.common.CommonMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.auth.middleware.SessionAuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware',
)
TEMPLATE_CONTEXT_PROCESSORS = (
"django.core.context_processors.debug",
"django.core.context_processors.i18n",
"django.core.context_processors.static",
"django.contrib.auth.context_processors.auth",
"django.core.context_processors.request",
"django.core.context_processors.media",
"django.contrib.messages.context_processors.messages",
)
STATICFILES_DIRS = (
)
STATICFILES_FINDERS = (
'django.contrib.staticfiles.finders.FileSystemFinder',
'django.contrib.staticfiles.finders.AppDirectoriesFinder',
# 'django.contrib.staticfiles.finders.DefaultStorageFinder',
)
TEMPLATE_LOADERS = (
'django_jinja.loaders.FileSystemLoader',
'django_jinja.loaders.AppLoader',
)
TEMPLATE_DIRS = (
BASE_DIR + '/templates',
)
ROOT_URLCONF = 'gengmei.urls'
WSGI_APPLICATION = 'gengmei.wsgi.application'
LANGUAGE_CODE = 'zh-cn'
TIME_ZONE = 'Asia/Shanghai'
USE_I18N = True
USE_L10N = True
# USE_TZ = True
SITE_ID = 1
# 邮件发送参数配置
EMAIL_HOST='smtp.exmail.qq.com'
EMAIL_HOST_USER='doctor@wanmeizhensuo.com'
EMAIL_HOST_PASSWORD='1812bar'
DEFAULT_FROM_EMAIL = 'doctor@wanmeizhensuo.com'
BrokenLinkEmailsMiddleware = True
SERVER_EMAIL = 'doctor@wanmeizhensuo.com'
EMAIL_PORT = 25
# Static files (CSS, JavaScript, Images)
# https://docs.djangoproject.com/en/1.7/howto/static-files/
MEDIA_ROOT = BASE_DIR + '/media/'
MEDIA_URL = _URL_PREFIX + '/medical/media/'
STATIC_ROOT = BASE_DIR + '/static/'
STATIC_URL = _URL_PREFIX + '/static/'
FILE_UPLOAD_MAX_MEMORY_SIZE = 0
# 300天才过期,认为用户只要登录就不会退出
SESSION_COOKIE_AGE = 60 * 60 * 24 * 300 # Age of cookie, in seconds (default: 300 weeks).
QINIU_ACCESS_KEY = "UPCOYIJkZOMcdd9FDzpBqYjzWUh55fBpVi3AhWpL"
QINIU_SECRET_KEY = "z5YvpDDSam_JE345Z8J_f3TufzelOW2VOGNoBl9e"
API_HOST = "http://www.wanmeizhensuo.com"
BEAUTIFUL_ACCESS_KEY = ''
BEAUTIFUL_SECRET_KEY = ''
_API_URL_PREFIX = API_HOST
_WEB_URL_PREFIX = API_HOST
RAVEN_CONFIG = {
'dsn': 'http://9f8992868f0348efaca2f4375e8db1df:11764cbbdb1440c38142c9e1a1e663ac@sentry.igengmei.com/131',
}
LOG_DIR = '/data/log/hermes/app/'
logging.basicConfig(
level=logging.INFO,
format='%(asctime)s %(levelname)s %(module)s.%(funcName)s Line:%(lineno)d %(message)s',
filename=os.path.join(LOG_DIR, 'filelog.log'),
)
LOGGING = {
'version': 1,
'disable_existing_loggers': False,
'formatters': {
'verbose': {
'format': '%(asctime)s %(levelname)s %(module)s.%(funcName)s Line:%(lineno)d %(message)s'
},
'simple': {
'format': '%(levelname)s %(message)s'
},
},
'handlers': {
'null': {
'level': 'DEBUG',
'class': 'django.utils.log.NullHandler',
},
'console': {
'level': 'DEBUG',
'class': 'logging.StreamHandler',
'formatter': 'simple'
},
'mail_admins': {
'level': 'ERROR',
'class': 'django.utils.log.AdminEmailHandler'
},
# 默认的服务器Log(保存到log/filelog.log中, 通过linux的logrotate来处理日志的分割
'default': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'filelog.log'),
'formatter': 'verbose',
},
# 默认的服务器ERROR log
'default_err': {
'level': 'ERROR',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'error_logger.log'),
'formatter': 'verbose',
},
'exception_logger': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'exception_logger.log'),
'formatter': 'verbose',
},
'ticker_logger': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'ticker_logger.log'),
'formatter': 'verbose',
},
'push_logger': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'push_logger.log'),
'formatter': 'verbose',
},
'elapsed_logger': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'elapsed_logger.log'),
'formatter': 'verbose',
},
'info_logger': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'info_logger.log'),
'formatter': 'verbose',
},
'auth_logger': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'auth_logger.log'),
'formatter': 'verbose',
},
'webproblem_logger': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'webproblem_logger.log'),
'formatter': 'verbose',
},
'sql_logger': {
'level': 'DEBUG',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'sql.log'),
'formatter': 'verbose',
},
},
'loggers': {
# 默认都交给django了
'django': {
'handlers': ['default'],
'propagate': True,
'level': 'INFO',
},
'django.request': {
'handlers': ['default_err'],
'level': 'ERROR',
'propagate': False,
},
'exception_logger': {
'handlers': ['exception_logger'],
'level': 'INFO',
'propagate': False,
},
'ticker_logger': {
'handlers': ['ticker_logger'],
'level': 'INFO',
'propagate': False,
},
'push_logger': {
'handlers': ['push_logger'],
'level': 'INFO',
'propagate': False,
},
'elapsed_logger': {
'handlers': ['elapsed_logger'],
'level': 'INFO',
'propagate': False,
},
'info_logger': {
'handlers': ['info_logger'],
'level': 'INFO',
'propagate': False,
},
'auth_logger': {
'handlers': ['auth_logger'],
'level': 'INFO',
'propagate': False,
},
'err_logger': {
"handlers": ['default_err'],
'level': "ERROR",
"propagate": False,
},
}
}
TEST_RUNNER = 'django.test.runner.DiscoverRunner'
DEFAULT_JINJA2_TEMPLATE_EXTENSION = '.jinja.html'
RPC_URL = 'http://10.129.148.20/api/'
RPC_SECRET = 'basic:XYLxLlkTFe89EnzR2e0bF90PqT29NkK5R9kaY50LhgIVIhzCZDiPT4C5AIO894lFHA0y+29ziq589m+LnCn2Iw=='
RPC_INVOKER = helios.rpc.RPCFactory(RPC_URL, RPC_SECRET, debug=DEBUG).create_invoker()
# 广点通
APPID_GDT = '639234809'
ADID_GDT = '55108'
ENCRYPT_KEY_GDT = '65772fc7658ffef4' # 加密密钥
SIGN_KEY_GDT = '41a8b982321e80a9' # 签名密钥
CONV_TYPE_GDT = 'MOBILEAPP_ACTIVATE'
URL_GDT = 'http://t.gdt.qq.com/conv/app/'
###2016-4-19 add by WangChengLiang
GDT_URL = 'http://t.gdt.qq.com/conv/app/'
GDT_SIGN_KEY = 'bec031e37babd08f'
GDT_ENCRYPT_KEY = 'BAAAAAAAAAAAFzsH'
GDT_CONV_TYPE = 'MOBILEAPP_ACTIVITE'
GDT_ADVER_ID = '1522439'
###end###
# -*- coding:utf-8 -*-
DEBUG = False
RAVEN_CONFIG = {
'dsn': 'http://9f8992868f0348efaca2f4375e8db1df:11764cbbdb1440c38142c9e1a1e663ac@sentry.igengmei.com/131',
}
STATIC_ROOT = '/srv/static/kefu'
QINIU_ACCESS_KEY = "UPCOYIJkZOMcdd9FDzpBqYjzWUh55fBpVi3AhWpL"
QINIU_SECRET_KEY = "z5YvpDDSam_JE345Z8J_f3TufzelOW2VOGNoBl9e"
CACHES = {
'default': {
'BACKEND': 'django_redis.cache.RedisCache',
'LOCATION': 'redis://192.168.168.142:6379/80',
'KEY_PREFIX': 'kefu',
'TIMEOUT': 86400, #one day
},
}
SESSION_ENGINE = 'django.contrib.sessions.backends.cache'
# -*- coding: UTF-8 -*-
from __future__ import unicode_literals
from .base_settings import *
from .celery_task_settings import *
import pymysql
pymysql.install_as_MySQLdb()
SECRET_KEY = '79!ro64h@pcse-1z=$v&_sh)+d))9rifii79of0gb8uyb86=8m'
DEBUG = False
ALLOWED_HOSTS = ['*']
STATIC_ROOT = '/srv/static/mars'
RAVEN_CONFIG = {
'dsn': 'http://9f8992868f0348efaca2f4375e8db1df:11764cbbdb1440c38142c9e1a1e663ac@sentry.igengmei.com/131',
}
# Database
# https://docs.djangoproject.com/en/1.8/ref/settings/#databases
DATABASES = {
'default': { # mysql
'ENGINE': 'django.db.backends.mysql',
'NAME': 'mars',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3506',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
},
'gaia': {
'ENGINE': 'django.db.backends.mysql',
'NAME': 'zhengxing',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
},
'mars-master': { # mysql
'ENGINE': 'django.db.backends.mysql',
'NAME': 'mars',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3506',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
},
'gaia-master': { # mysql
'ENGINE': 'django.db.backends.mysql',
'NAME': 'zhengxing',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
},
'zeus': {
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'zeus',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3506',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
},
}
DATABASE_ROUTERS = ["tool.routers.GaiaRouter"]
RPC_URL = 'http://10.25.194.175/api/'
RPC_KEY = 'basic:6o9sVEB6+H5U61rfZpVMioWcRRoU32uazNE3h18kwcAqOMPVdjmvQ72XxZVNLNl6RSACrgLeD7xrKYsxL1iZ6A=='
BACKEND = 'http://wanmeizhensuo.com'
USER_COOKIE_NAME = 'session_key'
USER_COOKIE_TIME = 864000 # 10 days
BROKER_URL = 'redis://192.168.168.142:6379/13'
# ===========================================
ES_HOSTS = [{
'host': '192.168.168.142',
'port': 9200,
}, {
'host': '192.168.168.142',
'port': 9200,
}, {
'host': '192.168.168.142',
'port': 9200,
}]
# ===========================================
# ===========================================
EMAIL_HOST = 'smtp.exmail.qq.com'
EMAIL_HOST_USER = 'doctor@wanmeizhensuo.com'
EMAIL_HOST_PASSWORD = 'gengmei098'
STATIS_EMAIL_USER = 'youjiantongji@wanmeizhensuo.com'
STATIS_EMAIL_PSWD = 'mq37tgk8nGi6eg1Hgq388oro3itvdmPl'
DEFAULT_FROM_EMAIL = 'doctor@wanmeizhensuo.com'
BrokenLinkEmailsMiddleware = True
SERVER_EMAIL = 'doctor@wanmeizhensuo.com'
EMAIL_PORT = 25
# ===========================================
# ===================================
# 邮件统计收件人
WATCHER = ['wangchengliang@gmei.com', 'linhuazhu@mei.com'] # 数据组自己统计
QUDAOZU = ['qudaozutongji@wanmeizhensuo.com'] # 今日分渠道设备,用户统计
CITY_SERVICE = ['skutongji@wanmeizhensuo.com'] # 今日各城市在售美购统计
SIXINZU = ['sixintongji@wanmeizhensuo.com'] # 本周医生未回复私信统计
DOCTOR_WATCHER = ['hexinyishengtongji@wanmeizhensuo.com'] # 今日医生美购浏览量统计
JIAOYIZU = ['jiaoyizutongji@wanmeizhensuo.com'] # 今日交易组统计邮件
SHEQUZU = ['shequzutongji@wanmeizhensuo.com'] # 今日社区组统计邮件
QUDAOZU2 = ['qudaozutongji@wanmeizhensuo.com'] # 今日渠道组活跃统计邮件
YONGHUZU = ['yonghutongji@wanmeizhensuo.com'] # 今日日记本缺失美购统计
DINGDAN = ['dingdantongji@wanmeizhensuo.com'] # 美购退款统计
YUYUE = ['yuyuetongji@wanmeizhensuo.com'] # 美购预约统计
AISI = ['qudaozutongji_common_aisi@wanmeizhensuo.com'] # 爱思助手推广
WATCHER_TWO = [
'wangchengliang@gmei.com',
'zhuyaoyao@gmei.com',
'dengwenyue@gmei.com',
'linhuazhu@gmei.com'
]
###2016-08-10###
BIHUAN = ['bh@gmei.com']
###end####
# ===================================
# ===========================================
ZHIDA_SK = 'vOom6KmcFBSVnWOy22qPmX7IGMpdsBUv'
ZHIDA_URL = 'http://m.baidu.com/lightapp/pay/order/offline/add'
ZHIDA_SP_NO = 93836
# ===========================================
CACHE = {
'default':
{ 'BACKEND': 'redis_cache.cache.RedisCache',
'LOCATION': 'redis://192.168.168.142:6379/15',
'TIMEOUT': 86400,
},
}
### 2016-05-30 Add by LinHuaZhu
AUTHORIZATION_ID = 'gmauth_key'
AUTHORIZATION_KEY = 'ecaeb940a2c615f654265183b3f8e76f'
###end####
###2016-06-02 Add by LinHuaZhu
SENTRY_CELERY_ENDPOINT = 'http://f549010eff314c97abd1c345796be3dc:accf8f78f693405fba4de405457111e9@sentry.gengmei.cc/33'
###end####
###2016-08-04 Add by WangChengYang
AES_KEY = '7vgc5dIbnkV5FM4C'
AES_IV = 'W2juIMi4urH9SiL0'
###end####
import uuid
from datetime import timedelta, date
from celery.schedules import crontab
from gm_types.gaia import USER_RIGHTS_LEVEL
DATABASES = {
'default': { # mysql
'ENGINE': 'django.db.backends.mysql',
'NAME': 'mimas_test',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
},
}
CELERY_TIMEZONE = 'Asia/Shanghai'
BROKER_URL = 'redis://192.168.168.142/0'
CELERY_TASK_SERIALIZER = "json"
SENTRY_CELERY_ENDPOINT = ''
BACKEND_API_HOST = 'https://backend.igengmei.com'
# 初始化数据
INIT_DATA = False
REDIS_CONF = {'host': '192.168.168.142', 'port': 6379, 'db': 0, }
# qa hack num
SUOZHANG_UID = 22
ANSWER_HACK_STRT = '-'
QINIU_CDN_HOST = u'http://pic.igengmei.com/'
MULTI_TOPIC_TAG_ID = 5089
GM_SERIALIZER = {
'redis': {
'host': '192.168.168.142', 'port': 6379, 'db': 1,
}
}
TEST_RUNNER = 'gm_test.runner.GmTestRunner'
REDIS = {
'default': {'host': '192.168.168.142', 'port': 6379, 'db': 0, },
'view': {'host': '192.168.168.142', 'port': 6379, 'db': 1, },
'answer_sort_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 4, },
'high_quality_question_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 5, },
'vote_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 6, },
'user_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 5, },
}
DATABASE_ROUTERS = ['utils.router.ThreadLocalRouter']
REDIS_MIGRATE = (
{
# gaia view_cache addr.
'source': {'host': '192.168.168.142', 'port': 7777, 'db': 1, },
'prefix': ('question_view', 'answer_view'),
'target': REDIS['view']
},
{
# gaia answer_sort_cache addr:
'source': {'host': '192.168.168.142', 'port': 7777, 'db': 2, },
'prefix': ('answer_sort_cache',),
'target': REDIS['answer_sort_cache']
},
{
# gaia vote_cache addr.
'source': {'host': '192.168.168.142', 'port': 7777, 'db': 2, },
'prefix': ('vote_cache',),
'target': REDIS['vote_cache']
},
)
# topic 迁移一期,暂时共用gaia redis
REDIS_TOPIC_1ST = {
'default': {'host': '192.168.168.142', 'port': 6379, 'db': 14, }, # gaia settings.DEFAULT_REDIS
'view': {'host': '192.168.168.142', 'port': 6379, 'db': 2, }, # gaia settings.REDIS['view']
'talos_rpc_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 14, }, # gaia settings.TALOS_RPC_CACHE
'user_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 5, }, # gaia settings.REDIS['user_cache']
'page_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 15, }, # gaia settings.REDIS['page_cache']
'vote_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 11, }, # gaia settings.REDIS['vote_cache']
}
REDIS_MIGRATE_TALOS = (
{
# gaia REDIS view addr.
'source': {'host': '192.168.168.142', 'port': 7777, 'db': 1, },
'prefix': ('diary_pv',),
'target': REDIS['view']
},
)
CELERYBEAT_SCHEDULE = {
"build_high_quality_cache": {
'task': 'qa.tasks.answer.build_high_quality_cache',
'schedule': timedelta(seconds=3600),
'args': (),
},
# 轮训七牛转码状态
'check_water_mark_video_is_finish': {
'task': 'live.tasks.check_water_mark_video_is_finish',
'schedule': timedelta(seconds=300),
'args': (),
},
# 生成直播回放帖子
'save_replay_url': {
'task': 'live.tasks.save_replay_url',
'schedule': timedelta(minutes=30),
'args': (),
},
# 直播状态检查
'check_live_status': {
'task': 'live.tasks.check_live_status',
'schedule': timedelta(minutes=2),
'args': (),
},
'add_fake_vote_num_list': {
'task': 'live.tasks.add_fake_vote_num_list',
'schedule': timedelta(minutes=1),
'args': (),
},
# 已无调用 180411
# v 7.6.65 更改 该功能不再使用!
# 'hot_in_24hrs': {
# 'task': 'talos.tasks.topic.hot_in_24hrs',
# 'schedule': crontab(minute=0, hour='9,12,21'),
# 'args': ()
# },
# 统计crash相关关键字帖子
'crash_checkout': {
'task': 'talos.tasks.crash_checkout.crash_check',
'schedule': crontab(hour=3, minute=0),
'args': (),
},
# 他人主页推荐关注的用户
'create_high_quality_user_to_redis': {
'task': 'talos.tasks.diary.create_high_quality_user_to_redis',
'schedule': crontab(hour=3, minute=0),
'args': (),
},
# 提醒用户更新日记
"remind_user_to_update_diary": {
'task': 'talos.tasks.diary.remind_user_to_update_diary',
'schedule': crontab(day_of_month="*", hour="21", minute=0),
'args': ()
},
# 计算帖子热度分数
'calc_topic_ranking': {
'task': 'talos.tasks.topic_ranking.calc_topic_ranking',
'schedule': crontab(hour=4, minute=0), # hour should be exactly the same as TopicRankingScore.SPLIT_HOUR
'args': (),
},
'doctor_diary_tags': {
'task': 'talos.tasks.diary.doctor_diary_tags',
'schedule': crontab(minute=30, hour='6'),
'args': ()
},
# 非日记帖,同步成问答
'convert_topic_to_question': {
'task': 'talos.tasks.topic.move_topic_to_answer',
'schedule': crontab(hour=4, minute=0),
'args': (),
},
'get_index_diary_detail': {
'task': 'talos.tasks.diary.get_index_diary_detail',
'schedule': crontab(hour=3, minute=0),
'args': (),
},
'fake_vote_to_topics': {
'task': 'talos.tasks.topic.fake_vote_to_topic',
'schedule': crontab(minute=0, hour='0,8-23'),
'args': (),
},
# 记录邀请人user_id列表池
'build_inviter_pool': {
'task': "qa.tasks.answer.build_inviter_pool",
'schedule': crontab(hour=1, minute=0),
'args': (),
},
# 每天下午5点,定时推送被邀请回答的用户,累计被邀请的次数。
'time_push_to_invited_user': {
'task': "qa.tasks.answer.time_push_to_invited_user",
'schedule': crontab(hour=17, minute=0),
'args': (),
},
'take_sofa_diary': {
'task': 'talos.tasks.diary.take_sofa_diary',
'schedule': timedelta(minutes=20),
'args': (),
},
'default_diary_rating': {
'task': 'talos.tasks.diary.default_diary_rating',
'schedule': crontab(hour=3, minute=0),
'args': (),
},
'preload_index_diaries': {
'task': 'talos.tasks.period_tasks.preload_index_diaries',
'schedule': timedelta(minutes=30),
'args': (),
},
'mark_reply_spam': {
'task': 'talos.tasks.period_tasks.mark_reply_spam',
'schedule': crontab(minute=50, hour=23),
'args': (),
},
# 抓取微信公众号数据
'get_wechat_pgc': {
'task': 'talos.tasks.topic.get_wechat_pgc',
'schedule': crontab(hour=3, minute=0),
'args': (),
},
'rerun_wechat_pgc': {
'task': 'talos.tasks.topic.rerun_pgc',
'schedule': crontab(hour='*/3', minute=0),
'args': (),
},
'preload_operation_tags': {
'task': 'talos.tasks.period_tasks.preload_tags',
'schedule': timedelta(minutes=60),
'args': (),
},
'hospital_topics_nums': {
'task': 'talos.tasks.diary.hospital_topics_num',
'schedule': crontab(hour=2, minute=10),
'args': (),
},
# 早上五点进行pv同步
'sync_diary_pv': {
'task': 'talos.tasks.diary.update_diary_pv',
'schedule': crontab(minute=0, hour=5),
'args': (),
},
# 每两个小时计算一次推荐问题数据
"get_relation_college_tag_questions": {
"task": "qa.tasks.answer.get_relation_college_tag_questions",
"schedule": timedelta(hours=2),
"args": (),
},
}
ES_INDEX_PREFIX = 'gm_test'
ES_HOSTS = [
{'host': '192.168.168.142', 'port': 9200},
]
LOGICAL_DATABASE_ID = 'mimas_test'
# listing decorator.
COUNT_LIMIT = 100
VERSION = uuid.uuid1()
QUESTION_SCORE_WEIGHT = {
'time_score_weight': 1, #
'answers_num_score_weight': 1,
'answer_views_score_weight': 1,
'answer_likes_score_weight': 1,
'question_view_score_weight': 1,
'question_answer_likes_score_weight': 1,
}
DIARY_HEAT_RANK = {
'lose_rate': 0.006, # 热度分时间衰减比率 0.006/hour/热度分
'max_score': 50, # 最大热度分
'reply_num_per_device': 3, # 每设备评论每天限制三次
# 加分相关
'score_create_topic': 4,
'score_modify_diary': 2,
'score_self_reply': 1,
'score_other_reply': 1,
'score_other_vote': 0.5,
# 限制相关
'restrict_create_topic': 2,
'restrict_modify_diary': 1,
'restrict_self_reply': 10,
'restrict_other_reply': 15,
'restrict_other_vote': 20,
}
SEND_MSG_TIME = 10
MSG_POLL_TIME = 4
LIVE_TIME_OUT = 15 * 60
ENTER_MSG_TIME = 2 * 60
QINIU_TEMP_CDN_HOST = u'http://pic-tmp.igengmei.com/'
LIVE_MSG_REDIS_FLAG = False
# 网易易盾反垃圾
YD_SECRET_ID = '914c9cb763500c23acdf121faed02c31'
YD_SECRET_KEY = 'ffb43924f88946f7d5b7aac1832a18e5'
YD_BUSINESS_ID = '8034f7ed207ec691c3f30d318e06e0c7'
# 特殊推送限制
SPECTAL_SECONDS_LIMIT = 7200
SPECIAL_PUSH_LIMIT = 4
PUSH_SUB_LIMIT = 1 # 子项,每日只能发一次
PERSON_GET_COMMENT_PUSH_LIMIT = 5 # 评论的每日收到的推送次数
LEVEL_UPPER_GAIN_POINTS = 200 # 每升一等级,增加美分200
USER_EVENT_MULTI_TIMES = 6 # 累计操作次数,给予不同的美分、成长值奖励
POINT_DAILY_LIMIT = 400 # 美分每日上限
GROWTH_DAILY_LIMIT = 300 # 成长值每日上限
UNSHOW_TAGS = [u'美购日记', u'所长精选', u'热门讨论']
# 评论图片和字数限制
CASHBACK_TOPIC_IMAGE_LIMIT = 2
CASHBACK_TOPIC_CONTENT_WORDS_LIMIT = 20
ELITE_LIKE_NUM = 5
HOT_TOPIC_VOTE_THRESHOLD = 10
HOT_TOPIC_VOTE_THRESHOLD_IN_ZONE = 10
REPLIES_READ_MYSQL_FLAG = True
NOTIFICATION_REPLY_IMG = 'http://hera.s.igengmei.com/2017/07/28/c32ff57e7a'
NOTIFICATION_VOTE_IMG = 'http://hera.s.igengmei.com/2017/07/28/d7e0c06fb0'
# 检索时间
DAYS_BEFORE_TODAY = -1
# 短视频权限起始等级
CAN_CREATE_VIDEO_LEVEL = USER_RIGHTS_LEVEL.V3
SHOW_VIDEO_COVER = True
HOT_DISCUSSION_TAG_DIARY_SHRESHOLD = 1000
HOT_DISCUSSION_TAG_CONSULT_SHRESHOLD = 30
HOT_DISCUSSION_TAG_DISCUSS_SHRESHOLD = 100
VIDEO_PIC_URL = u'?vframe/jpg/offset/0/rotate/auto'
VIDEO_HOST = u'http://video-static.igengmei.com/'
FOUNDING_DAY = date(2013, 8, 8)
SOCIAL_REPLY_WEIGHT = 0.7
SOCIAL_LIKE_WEIGHT = 0.3
CONTENT_WEIGHT = 0.4
SOCIAL_WEIGHT = 0.3
TIME_WEIGHT = 0.045
DIARY_COVER_DEFAULT = 'http://hera.s.igengmei.com/2015/10/16/61b745cb36'
# for SLAVE_DB_NAME
SLAVE_DB_NAME = 'default'
# 邀请人筛选条件,优良回答 总数 > 3
INVITER_LIMIT_FORM_ANSWER = 3
INVITE_QUESTION_LIST_PAGE = "/hybrid/question/question_list" # 去回答列表页
SUBJECT = u'用户版-用户反馈崩溃日报'
CRASH_KEYWORDS = ['crash', u'闪退', u'软件崩溃', u'软件问题', u'app问题']
SENDTO = ['linli@igengmei.com']
# model中检索的字段
MODEL_FIELDS = {'diary': ['title'], 'problem': ['ask', 'answer'], 'topicreply': ['content']}
# 日记本质量分
DIARY_CONTENT_LEVEL_SCORE = {
'UNAUDITED': -1000,
'ILLEGAL': -1000,
'BAD': -1000,
'GENERAL': -1000,
'BETTER': -1000, # 新增内容等级 3.5,和郑伟确认先按照 -1000给值
'FINE': 65.0,
'EXCELLENT': 100.0
}
BUILD_SITEMAP_COUNT = 1000
# rating limit
DIARY_RATING_LIMIT = 2
VIDEO_TAG_ID = 4706 # 如果有小视频 就给日记本添加视频日记的tag
# weixin js sdk
# 正式账号
WX_APP_ID = 'wx19c0bdd0c9e25acb'
WX_APP_SECRET = '41855cb5fd32338435b2c7dbaa400716'
WX_USER_ID = 20889703
MIP_LIMIT = 10
# 首页Feed随机比例
DIARY_RANDOM_SCALE = {
"wuhan": 10,
"beijing": 15,
"guangzhou": 10,
"chengdu": 10,
"shanghai": 10,
"chongqing": 10,
"hangzhou": 10,
"shenzhen": 10,
}
ANSWER_NUM_BASELINE = 4 # 回答数基本限制
# 计算回答子评论未读数的起始时间
COUNT_ANSWER_COMMENTED_REPLY_START_TIME = '2018-08-15 15:23:00'
DATABASES = {
'default': { # mysql
'ENGINE': 'django.db.backends.mysql',
# 'NAME': 'mimas_dev',
'NAME': 'mimas_test',
'USER': 'work',
'PASSWORD': 'Gengmei1',
# 'HOST': '127.0.0.1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
},
'slave': { # mysql
'ENGINE': 'django.db.backends.mysql',
'NAME': 'mimas_dev',
'USER': 'work',
'PASSWORD': 'Gengmei1',
# 'HOST': '127.0.0.1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
},
}
CELERY_TIMEZONE = 'Asia/Shanghai'
BROKER_URL = 'redis://192.168.168.142:6379/0'
CELERY_BROKER_URL = 'redis://192.168.168.142:6379/0'
CELERY_TASK_SERIALIZER = "json"
SENTRY_CELERY_ENDPOINT = ''
BACKEND_API_HOST = 'http://backend-service.default'
# 初始化数据
INIT_DATA = True
# qa hack num
ANSWER_HACK_STRT = '-'
QINIU_CDN_HOST = u'http://pic.igengmei.com/'
MULTI_TOPIC_TAG_ID = 5089
GM_SERIALIZER = {
'redis': {
'host': '192.168.168.142', 'port': 6379, 'db': 1,
}
}
TEST_RUNNER = 'gm_test.runner.GmTestRunner'
REDIS = {
'default': {'host': '192.168.168.142', 'port': 6379, 'db': 0, },
'view': {'host': '192.168.168.142', 'port': 6379, 'db': 1, },
'answer_sort_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 4, },
'high_quality_question_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 5, },
'vote_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 6, },
'page_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 10, },
'social_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 11, },
'user_cache': {'host': '192.168.168.142', 'port': 6379, 'db': 12, },
}
DATABASE_ROUTERS = ['utils.router.ThreadLocalRouter',]
LIVE_REDIS = {'host': '192.168.168.142', 'port': 6379, 'db': 7, }
DEFAULT_REDIS = {'host': '192.168.168.142', 'port': 6379, 'db': 8, }
TALOS_RPC_CACHE = {'host': '192.168.168.142', 'port': 6379, 'db': 9, }
# gaia local settings template
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'zhengxing_test',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
},
}
SECRET_KEY = 'fl-lv3j^czg(dupo@hbs(+_+djby9zelwt&rh71@b1x*ptmj4#(^' #dev
DEBUG = True
REDIS = {
'host':'192.168.168.142',
'port':6379,
'db':0,
}
REDIS_SENTINEL = [('192.168.2.6', 26379)]
-----BEGIN RSA PRIVATE KEY-----
MIIEogIBAAKCAQEAvjaGLGkT8VDeMbIz/Fsx9q3UQ8yZL6FNf/lfpAwsA9IWsGRb
FniSudG0cJrND1swb8Vd2IOLnVyhWb1AWdmic1L5guQKrGDiTx6GqEG1NBhntDoF
ysdil39L/f6f81mneUsccdmA4PfwITkvetgzsUdKyx6XSzHVdjCDrxWiO4Rz4hq5
Sp3tPnZCMl+CGE/5GIUftWnlOZGkifgtcok9Ja9CguBl1Jqc8lv34Wc+xHkKLRbA
UBzX8kdNMwCoLTcKbuvf5vWB+5xg7D/mw3kQI6p/8bCKOqMYlqceq2qmgyBSbqtm
k6+h/mSFiuUuG4S3CoQdVqFXFg24hAbWBV4mqQIDAQABAoIBACnqhgK/XR+ufGhj
JsWTqxz7DW2rZo5yc0uiPos+C20EHO/eDZyUEXFVXvf5hPq/U5st2RJfWqLgyMWn
yMiEByJ2xHktm5SE/RoGVhI5+J50SlYS+zfGXFmaObrNI55SwW8fODN2hMoOmSIZ
IfdmMW39kePU5+4wGyQiaMJqeAe5NG7GFUCm7UtI96ENj2afWMWEjRtV1HSGL+Tu
VMbGUhgsXm6Of6oTxU0ARITHAFyogdj7D/vyE7Gzt9/Yam9uwWfKdidSaj2bbVgr
HGVBAyFs0s1569AM5+fhAU4qA1qQmiWpbgX3m8n94KwH/7JCTWX5DCimfnGajkk2
fjbICgECgYEA+nTeXczI9a1Fv+Fs8W35a4jlVIoJRcLW1C04CidWEG3JHRzT06Gb
i4u8F+eoJD9s0KqZoJbOAADcg1skxz3balwJ01ExmQe+tt/VFuFKYaqtBYMbJ7JK
+zoMC6KLdP16dfiWWGzSVC+yVU21mkEiPPX8uSMmO6DqcUff9Y5YmYkCgYEAwmxO
DCwKZPf/AGtNhvvUUAAyYJEbx05Ed5sSSSMVhXJDRKapcWVQH2QLTa50Yr3lyRma
7A1dLC5nv0Awf3rOOiyxzL1R3j7jdidaURmj2BXwCbBVnnuRlVp2ZVV16LqCAaVY
86TwWJeJ1QWw+5Tc70e2wM623DWN65hiclP0fCECgYBkCMnILUMW3V4+hYs94u78
RHFUks2hT3D+zhDT/WIirbbmKd1xadr2oZk+8wf1cl/D+F/kBFfDKJTq4jyOV+aL
VLeX75YfyTgjUsOJn/JVkBYLXZI7CLtqHIUzIHkTASsoc2GZb92SQnq4F5GxStKi
Bp4qVB+xMVRyaoLJUVGSAQKBgCkxAxQnHIip1jgDg+huYFwWvpWhCM6gMXdZvnUK
XtvoCoJ4APxKZ8BO1Oo/ZN8qto11xFHwvuXGayqk8eGAZkMDBySGk9rPXifBTKxU
D1ePxkx3NJygN4b6JI1xnsqRAUxR+NeeAWHzsTsVupqCvpBflEOjSDC9k/TvUyQ/
z1OhAoGAMk6jJDd2c9Sx6JRWbIsYD42T/3HSTRzGq5NHBzmc3zFFFmcJIaI4qXMh
9WgQRxWR01sRK+083j8iVesVo6pyQ1qZowBj9unHcOOjB1y3Xc8uzqQWX4aDP7Wh
MhCum+nlPmhJx8Ex3l3rhR0rE02zXMa2WVJgvcJGHnubQGLSnR8=
-----END RSA PRIVATE KEY-----
MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAiMQbWLf9YDH1HZs3bMwPO_qxwkbd0JKGqxN37NVFZBKPmvsSkZKkzCq2XXLCQYNwF5Wf9V5nAyvdxgH4rNmIK4hSxTz-afSuWpmETWGecj2fM3psJ7YQG1VE39pDuiGf-bnUhOqdu8Qwpr3F7PKYthHnAIinehDrfQhba6SoeNA5UL8eiXeQCz0vy9Kd2NT2cdsU6uTNRn7SUrI46GpMW9RqVlaHKEqL6EeC_y-vAKzWpmhKD_RkgHRDyg3NjplGBMLy72V8yTI8foh-8rIIKhtQiHd-KgwnHiJT32TCRTm73MuVPwUUDNS2Bhd5beSppNeQ-uZvcea6bKQUNFz6qQIDAQAB
\ No newline at end of file
-----BEGIN RSA PRIVATE KEY-----
MIICXAIBAAKBgQDyPlAcvt4804ZPPezoQ1+wo5D4h21z3chv3ofZvyhspWKpoWSB
IUdGtaPdv09ywpJljqpryVAFCcmdOsQ7AyvHvVbh/AGhOEgV33nzSb9aDhJNGnhA
chpp/BZIv3jAZDyq2kHgvmWpxe52YS4R6TdQMexj5o8EN7WQNVHiQTtIVwIDAQAB
AoGAE4QxsB8wiHYCPCAhFhVXgEOtSlie2Nblbx3elAxylU49xKzcDAtCUtAPg64G
GJjUcpor4MM3TzCarbAuXxLCVA0sUSd7FAuIqQzSsv2f7RTfvhrbvhjylwRbZzko
TQT+nUMdf2v75eKWq6YLzvh8ZZvdN+WaIw3OCHrgsOoflQECQQD7PorUlRGXpWL9
ocoC6JxZDjheBKOgO58JuIv0AdoMbZyp3YQA43WoAKUpg5BzLfoITqyZhqhmrasH
aLJtbTY7AkEA9tQnpg4is2nYoOMH50d7iPOlSfATSIciRUE/rTukiOSqzuaRCDVQ
HhiRw7dzSgr6/5aNRfPE7zuQ9ynHWfyolQJAMagt1lBUNs24X/rPK34AENXvrB1s
nanLCCfSeXq4NwafFS+z/Fz4jyj5e9gF/83RgjzSflGQDSM8D23Q/jG8qwJBAKo5
I+LcSsgqzhAeolu5K5QGW86C9/mD4HmchxqkUFNsR/QKhKkBg3BOB3DPen3s1q8f
l+xPMli+XrpmIKqJmYUCQGy9x6SJfinASfRGBeinLUuRcThE5oF5lP3OYtRCKF7M
atcdf7wARxDNr9zy/yzXV1stv+HoqG7laJxt8ERYcwQ=
-----END RSA PRIVATE KEY-----
\ No newline at end of file
-----BEGIN PUBLIC KEY-----
MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDFNndmLlsi8NYQpvZNK/b6kSjN99lwWnWbAHxfBcBYQHx5mZBR8XkkIajSiYo29f7zmM0eAI8OSo6FY16bSt23RzThd+MvDBQC6axDCgGag5992AVGItU8LtWPBrM6XRbtN3+rjIteKhNDOUbEvp60S9/8uoEfnqekd/nEG9I4mQIDAQAB
-----END PUBLIC KEY-----
\ No newline at end of file
# gaia local settings template
DEBUG = False
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'plutus',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
},
}
CACHES = {
"default": {
"BACKEND": "django_redis.cache.RedisCache",
"LOCATION": "redis://192.168.168.142:6379/113",
"OPTIONS": {
"CLIENT_CLASS": "django_redis.client.DefaultClient",
}
}
}
RM_SERVER="https://api.puhuifinance.com"
RM_AUTH_SERVER="https://api.puhuifinance.com"
RM_TOKEN="AYLDASuPfbpsEQB6"
RM_CLIENT_ID="gengmei"
RM_SECRET="M6RBx4SkJcjgzQij"
ZA_APP_KEY = '63da669f3333fe09024d50dd04fee65c'
ZA_URL = 'http://opengw.daily.zhongan.com/Gateway.do'
ZA_PUB_KEY = '/srv/secret/zhongan_public.pem'
ZA_PRI_KEY = '/srv/secret/zhongan_private.pem'
AES_KEY = '6O58bOnKftwvbUM6' # 16个字节的密钥,需要重新生成
AES_IV = '7tIFgpydqrfer3l3' # 16个字节的初始向量,需要重新生成
YINUO_SECRECT = 'kwR58f2BNLWemSmOEDsi9mJReWpHfGo8'
YINUO_USER_ID = 'KOQ6CNWM'
YINUO_HOST = 'https://api-sandbox.yinuobaoxian.com'
YINUO_PREMIUM = 5
YINUO_PRODUCT_ID = '8YMWI5QZ'
YINUO_PLAN = 'A'
YINUO_SUM_INSURED = 50000
YINUO_EXPIRATION_DAYS = 210
###Add by Yingcai###
#YRD_SERVER = 'http://pay.yirendai.com'
#YRD_KEY = 'Tn0Kvprwj53xn83z78IsCw=='
USER_SHUNT = (0.01, 0.01, 0.99)
### add by yunyu###
BROKER_URL = 'redis://192.168.168.142:6379/114'
SENTRY_CELERY_ENDPOINT = 'http://9f8992868f0348efaca2f4375e8db1df:11764cbbdb1440c38142c9e1a1e663ac@sentry.igengmei.com/131'
ZHONGAN_FAIL_MAILS = ['dingyingcai@gmei.com', 'zhengdixun@gmei.com', 'yuqiaolin@gmei.com']
# django database settings
DATABASES = {
'default': {},
'gaia': {
'ENGINE': 'django.db.backends.mysql',
'NAME': 'push',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3406', # zhengxing库rds端口
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4",
},
},
}
from gm_types.push.enum import SEGMENT_TYPE
USER_JPUSH_SETTINGS = {
'key':'9e779399e200529a63722da7',
'secret':'38a0a35dc8bc96b509fc61e1',
}
DOCTOR_JPUSH_SETTINGS = { # 医生版极光key
'key':'5c450e73f736580543d0bd4e',
'secret':'688b209acae48381ece1f3f8',
}
BIG_PUSH_DURATION = 10 # 平滑推送窗口时间(分钟)
PUSH_STAT_DELAY = 60 # 统计延时(秒)
SEGMENT_MAP = {
SEGMENT_TYPE.ACTIVE_7_DAYS: '2f162d3395',
SEGMENT_TYPE.NO_ACTIVE_7_DAYS: 'cf8477eef4',
}
\ No newline at end of file
# basic config
DEBUG = False
TIME_ZONE = 'Asia/Shanghai'
MAX_USER_COUNT = 128 # 批量推送一次最多允许推送的用户数(无需修改)
CELERY_BROKER_URL = 'redis://192.168.168.142/0' # redis地址
# coding=utf-8
from __future__ import unicode_literals, print_function, absolute_import
import datetime
import os
from celery.schedules import crontab
from kombu import Exchange, Queue
from mobile.libs.hospital_synonym import get_synonym
from gm_types.gaia import TRANSFER_SOURCE
from gm_types.mimas import GRABBING_PLATFORM
############################################### django ###############################################
ALLOWED_HOSTS = ['*']
BASE_DIR = os.path.dirname(os.path.dirname(__file__))
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.sqlite3',
'NAME': ':memory:',
},
}
DEBUG = True
DEFAULT_JINJA2_TEMPLATE_EXTENSION = ''
# Application definition
INSTALLED_APPS = (
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.staticfiles',
'django_jinja',
'mobile',
'raven.contrib.django.raven_compat',
)
LANGUAGE_CODE = 'en-us'
MIDDLEWARE_CLASSES = (
'gm_tracer.middleware.TracerMiddleware',
'gm_tracer.middleware.TracerExtraMiddleware',
'mobile.middlewares.LoggingMiddleware',
'django.middleware.common.CommonMiddleware',
#'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'gm_logging.django.middleware.LoggingMiddleware',
'mobile.middlewares.HeliosMiddleware',
'mobile.middlewares.PassportMiddleware',
'mobile.middlewares.TrackingMiddleware',
'gm_shield.django.middleware.GMShield',
)
ROOT_URLCONF = 'ship.urls'
SECRET_KEY = '1j%gt4=0e6l9)z1k9pr$b$9s%4ic=@xf5083tcq*k040rk6=hh'
SESSION_COOKIE_NAME = 'django_sessionid'
SESSION_ENGINE = 'redis_sessions.session'
SESSION_NAME = 'sessionid'
SESSION_REDIS_HOST = '192.168.168.142'
SESSION_REDIS_PORT = 6379
SESSION_REDIS_DB = 1
SESSION_REDIS_PREFIX = 'msite'
STATICFILES_DIRS = (
("mobile", os.path.join(BASE_DIR, 'frontend', 'mobile', 'static', 'mobile')),
)
STATICFILES_FINDERS = (
'django.contrib.staticfiles.finders.FileSystemFinder',
)
STATIC_ROOT = ''
STATIC_URL = '/static/'
TEMPLATE_DEBUG = DEBUG
TEMPLATE_DIRS = (
os.path.join(BASE_DIR, 'frontend', 'mobile', 'templates'),
)
TEMPLATE_LOADERS = (
'django_jinja.loaders.FileSystemLoader',
)
TIME_ZONE = 'Asia/Shanghai'
USE_I18N = True
USE_L10N = True
USE_TZ = True
WSGI_APPLICATION = 'ship.wsgi.application'
############################################### django ###############################################
############################################### others ###############################################
CELERY_DEFAULT_QUEUE = 'ship'
CELERY_QUEUES = (
Queue('ship', Exchange('ship'), routing_key='ship'),
)
BROKER_TRANSPORT_OPTIONS = {'visibility_timeout': 60 * 60 * 24 * 3}
BROKER_URL = 'redis://192.168.168.142:6379/4'
RAVEN_CONFIG = ''
REDIS = {'host': '192.168.168.142', 'port': 6379, 'db': 0, }
REDIS_CONFIG = {
'host': '192.168.168.142',
'port': 6379,
'db': 0,
}
TRACKING_COOKIE_AGE = 365 * 24 * 60 * 60
TRACKING_COOKIE_NAME = '_gtid'
CELERY_TIMEZONE = 'Asia/Shanghai'
CELERY_TASK_SERIALIZER = "json"
SENTRY_CELERY_ENDPOINT = ''
CELERYBEAT_SCHEDULE = {
"cache_trilateral_seckill_base_info": {
"task": "mobile.tasks.period_tasks.cache_trilateral_seckill_base_info",
"schedule": datetime.timedelta(seconds=10),
"args": (),
},
"cache_trilateral_seckill_city_info": {
"task": "mobile.tasks.period_tasks.cache_trilateral_seckill_city_info",
"schedule": datetime.timedelta(minutes=10),
"args": (),
},
}
############################################### others ###############################################
DEFAULT_PORTRAIT = 'http://hera.s.igengmei.com/slide/2016/11/30/07b076e423'
IMG_LAYER = 'http://hera.s.igengmei.com/2016/07/21/56dd662785'
IOS_DEFAULT_PARAM = '00000000-0000-0000-0000-000000000000'
IS_ACCEPT_CALL = False
TIME_CAN_ACCEPT_CALL = (datetime.time(9, 0, 0), datetime.time(19, 0, 0))
BACKEND_URL = 'http://backend.igengmei.com/'
PC_URL = 'http://www.igengmei.com'
SITE_URL = 'http://m.igengmei.com/'
URL_BASE = 'http://m.igengmei.com'
RENMAI_INSTALLMENT_PERIOD = 12
SERVICE_INSERT_INDEX = 3
SPECIAL_COUPON_CHANNEL = 22
TDK = {
'title': u'更美APP官网—微整形_整形美购_整形美容_微整形社区与微整形特卖平台',
'keywords': u'更美,更美APP,更美APP官网,更美网,整形,整容,微整形',
'description': u'更美公司成立于2013年,旗下更美APP是专业微整形平台,提供整形、微整形、齿科、眼科、抗衰老等消费医疗服务。业务形态主要包括移动医美与健康社区、医美电商与团购特卖、企业服务、消费金融等。更美APP致力于帮助求美者更高效地找到合适的医生,降低消费风险;也帮助医生塑造个人品牌。'
}
WECHAT_APP_ID = ''
WECHAT_APP_SECRET = ''
WECHAT_PAY_REDIRECT_URL = ''
WX_APP_ID = ''
WX_APP_SECRET = ''
WECHATLINE_SCREENSHOT = {
'title': "",
'content': "http://hera.s.igengmei.com/slide/2016/06/02/6a6eb352d8"
}
WECHAT_SCREENSHOT = {
'title': "",
'content': "http://hera.s.igengmei.com/slide/2016/06/02/6a6eb352d8"
}
WEIBO_SHARE_HOST = u'http://m.igengmei.com'
##########################################################################################
############################################### logging ###############################################
LOG_DIR = '/data/log/ship/app/'
LOGGING = {
'version': 1,
'disable_existing_loggers': False,
'formatters': {
'verbose': {
'format': '%(asctime)s %(levelname)s %(module)s.%(funcName)s Line:%(lineno)d %(message)s'
},
'simple': {
'format': '%(asctime)s %(levelname)s %(message)s'
},
'raw': {
'format': '%(message)s'
},
},
'handlers': {
'null': {
'level': 'DEBUG',
'class': 'django.utils.log.NullHandler',
},
'console': {
'level': 'DEBUG',
'class': 'logging.StreamHandler',
'formatter': 'simple'
},
'mail_admins': {
'level': 'ERROR',
'class': 'django.utils.log.AdminEmailHandler'
},
# 默认的服务器Log(保存到log/filelog.log中, 通过linux的logrotate来处理日志的分割
'default': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'filelog.log'),
'formatter': 'verbose',
},
# 默认的服务器ERROR log
'default_err': {
'level': 'ERROR',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'error_logger.log'),
'formatter': 'verbose',
},
'exception_logger': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'exception_logger.log'),
'formatter': 'verbose',
},
'info_logger': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'info_logger.log'),
'formatter': 'verbose',
},
'profile_logger': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'profile_logger.log'),
'formatter': 'simple',
},
'wx_download_pic_logger': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'wx_download_pic_logger.log'),
'formatter': 'verbose',
},
'fxg_handler': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'fenxianggou_logger.log'),
'formatter': 'simple',
},
'settlement_create_handler': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'settlement_create_logger.log'),
'formatter': 'simple',
},
# 陌陌打点日志
'momo_stat_log_handler': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'momo_stat_log.log'),
'formatter': 'simple',
},
'tracer_handler': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'tracer.log'),
'formatter': 'raw',
},
# 三方合作,秒杀基础数据缓存日志
'trilateral_seckill_cache_handler': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'cache_trilateral_seckill_base_info.log'),
'formatter': 'simple',
},
# 三方合作,手机号绑定出错日志
'trilateral_user_bind_phone_handler': {
'level': 'INFO',
'class': 'logging.handlers.RotatingFileHandler',
'filename': os.path.join(LOG_DIR, 'trilateral_user_bind_phone_logger.log'),
'formatter': 'simple',
},
},
'loggers': {
# 默认都交给django了
'django': {
'handlers': ['default'],
'propagate': True,
'level': 'INFO',
},
'django.request': {
'handlers': ['default_err'],
'level': 'ERROR',
'propagate': False,
},
'exception_logger': {
'handlers': ['exception_logger'],
'level': 'INFO',
'propagate': False,
},
'info_logger': {
'handlers': ['info_logger'],
'level': 'INFO',
'propagate': False,
},
'profile_logger': {
'handlers': ['profile_logger'],
'level': 'INFO',
'propagate': False,
},
'err_logger': {
"handlers": ['default_err'],
'level': "ERROR",
"propagate": False,
},
'wx_download_pic_logger': {
'handlers': ['wx_download_pic_logger'],
'level': 'INFO',
'propagate': False,
},
'fxg_logger': {
"handler": ["fxg_handler"],
"level": "INFO",
"propagate": False,
},
'settlement_create_logger': {
"handler": ["settlement_create_handler"],
"level": "INFO",
"propagate": False,
},
'momo_stat_logger': {
'handlers': ['momo_stat_log_handler'],
'level': 'INFO',
'propagate': False,
},
'gm_tracer.subscribe': {
'handlers': ['tracer_handler'],
'propagate': False,
'level': 'INFO',
},
'trilateral_seckill_cache_logger': {
'handlers': ['trilateral_seckill_cache_handler'],
'level': 'INFO',
'propagate': False,
},
'trilateral_user_bind_phone_logger': {
'handlers': ['trilateral_user_bind_phone_handler'],
'level': 'INFO',
'propagate': False,
},
}
}
def config_gm_logging(log_dir, global_dict):
pass
def GM_LOGGING():
return {
'request_info_extractor_class': 'mobile.logging.ShipMobileRequestInfoExtractor',
'log': {
'basedir': LOG_DIR,
'prefix': 'ship',
'buffered': False,
}
}
############################################### logging ###############################################
# PK_TOPICS 默认值
PK_TOPICS = {}
QINIU_ACCESS_KEY = "UPCOYIJkZOMcdd9FDzpBqYjzWUh55fBpVi3AhWpL"
QINIU_SECRET_KEY = "z5YvpDDSam_JE345Z8J_f3TufzelOW2VOGNoBl9e"
# 地图需求相关配置
CITY_COORDINATE = {
u'北京': [116.46, 39.92],
u'广州': [113.23, 23.16],
u'上海': [121.48, 31.22],
u'重庆': [106.54, 29.59],
u'成都': [104.06, 30.67],
u'武汉': [114.31, 30.52],
u'深圳': [114.07, 22.62],
u'郑州': [113.65, 34.76],
u'西安': [108.95, 34.27],
u'杭州': [120.19, 30.26],
u'长沙': [113, 28.21],
u'南京': [118.78, 32.04],
u'南昌': [115.89, 28.68],
u'沈阳': [123.38, 41.8],
u'昆明': [102.73, 25.04],
u'福州': [119.3, 26.08],
u'青岛': [120.33, 36.07],
u'南宁': [108.33, 22.84],
u'天津': [117.2, 39.13],
u'大连': [121.62, 38.92],
u'石家庄': [114.48, 38.03],
u'合肥': [117.27, 31.86],
u'兰州': [103.73, 36.03],
u'厦门': [118.1, 24.46],
u'哈尔滨': [126.63, 45.75],
u'苏州': [120.62, 31.32],
u'长春': [125.35, 43.88],
u'济南': [117, 36.65],
u'温州': [120.65, 28.01],
u'乌鲁木齐': [87.68, 43.77],
}
SALES_PERCENTAGE = [
{
'name': '北京',
'value': '21.85'
},
{
'name': '广州',
'value': '9.28'
},
{
'name': '上海',
'value': '9.15'
},
{
'name': '重庆',
'value': '8.84'
},
{
'name': '成都',
'value': '8.07'
},
{
'name': '武汉',
'value': '6.19'
},
{
'name': '深圳',
'value': '5.78'
},
{
'name': '郑州',
'value': '5.72'
},
{
'name': '西安',
'value': '4.29'
},
{
'name': '杭州',
'value': '3.37'
},
{
'name': '长沙',
'value': '2.67'
},
{
'name': '南京',
'value': '2.40'
},
{
'name': '南昌',
'value': '1.82'
},
{
'name': '沈阳',
'value': '1.02'
},
{
'name': '昆明',
'value': '0.97'
},
{
'name': '福州',
'value': '0.82'
},
{
'name': '青岛',
'value': '0.80'
},
{
'name': '南宁',
'value': '0.77'
},
{
'name': '天津',
'value': '0.61'
},
{
'name': '大连',
'value': '0.55'
},
{
'name': '石家庄',
'value': '0.52'
},
{
'name': '合肥',
'value': '0.49'
},
{
'name': '兰州',
'value': '0.49'
},
{
'name': '厦门',
'value': '0.44'
},
{
'name': '哈尔滨',
'value': '0.43'
},
{
'name': '苏州',
'value': '0.39'
},
{
'name': '长春',
'value': '0.38'
},
{
'name': '济南',
'value': '0.37'
},
{
'name': '温州',
'value': '0.33'
},
{
'name': '乌鲁木齐',
'value': '0.32',
}
]
RECOMMEND_SPECIAL = [
{
# 鼻综合
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/2cc1ed9f57',
'service_id': 1382,
'type': 0,
},
{
# 双眼皮
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/3df76bf778',
'service_id': 1383,
'type': 0,
},
{
# 祛眼袋
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/da4ba395e2',
'service_id': 1393,
'type': 0,
},
{
# 双眼皮修复
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/7e9502d169',
'service_id': 1399,
'type': 0,
},
{
# 自体脂肪填充
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/6f0e20d50e',
'service_id': 1378,
'type': 0,
},
{
# 韩式半永久妆
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/3811090eb6',
'service_id': 1401,
'type': 0,
},
{
# PRP自体脂肪填充面部
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/b8bdff1585',
'service_id': 1396,
'type': 0,
},
{
# 玻尿酸注射
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/6860a3a087',
'service_id': 1384,
'type': 0,
},
{
# 肉毒素除皱
'image_url': 'http://hera.s.gmei.com/bodypart/2017/05/10/1443e6166a',
'service_id': 1389,
'type': 0,
},
{
# 垫下巴
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/34e742bc97',
'service_id': 1391,
'type': 0,
},
{
# 除皱
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/5d9413b6e2',
'service_id': 1402,
'type': 0,
},
{
# 脱毛
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/b979bbcb34',
'service_id': 1403,
'type': 0,
},
{
# 瘦脸
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/b3eb6dc9ee',
'service_id': 1379,
'type': 0,
},
{
# 丰胸
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/9398dbaf0f',
'service_id': 1380,
'type': 0,
},
{
# 隆鼻
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/89a393fca1',
'service_id': 1381,
'type': 0,
},
{
# 吸脂
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/f8f8929462',
'service_id': 1386,
'type': 0,
},
{
# 鹳骨
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/108964153c',
'service_id': 1388,
'type': 0,
},
{
# 溶脂
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/49aec7d452',
'service_id': 1390,
'type': 0,
},
{
# 牙齿矫正
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/c077a93c4e',
'service_id': 1398,
'type': 0,
},
{
# 毛发移植
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/06746fd28c',
'service_id': 1397,
'type': 0,
},
{
# 眼部整形
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/9d8c38abed',
'service_id': 1395,
'type': 0,
},
{
# 补水保湿
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/a72456a347',
'service_id': 1392,
'type': 0,
},
{
# 埋线提升
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/9f4e67418e',
'service_id': 1385,
'type': 0,
},
{
# 手术减肥
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/d487aeb1dd',
'service_id': 1394,
'type': 0,
},
{
# 隆鼻修复
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/364f09ccdb',
'service_id': 1387,
'type': 0,
},
{
# 祛斑祛痣
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/b911178ab6',
'service_id': 1400,
'type': 0,
},
{
# 美白嫩肤
'image_url': 'http://hera.s.igengmei.com/bodypart/2017/05/10/cd55c8f2c6',
'service_id': 1404,
'type': 0,
},
{
'image_url': 'http://hera.s.igengmei.com/slide/2017/05/17/6fb7aa6612',
'service_id': 1311,
'type': 1,
},
{
'image_url': 'http://hera.s.igengmei.com/slide/2017/05/17/95ed3b0d65',
'service_id': 1319,
'type': 1,
},
{
'image_url': 'http://hera.s.igengmei.com/special/2017/05/17/0d38a70f3c',
'service_id': 1313,
'type': 1,
},
{
'image_url': 'http://hera.s.igengmei.com/slide/2017/05/17/e8d57229ba',
'service_id': 1307,
'type': 1,
},
{
'image_url': 'http://hera.s.igengmei.com/slide/2017/05/17/d9784a73de',
'service_id': 1306,
'type': 1,
},
{
'image_url': 'http://hera.s.igengmei.com/slide/2017/05/17/c3651f38ca',
'service_id': 1302,
'type': 1,
}
]
# 医院名同义词
HOSPITAL_SYNONYM = get_synonym()
API_HOST = 'http://backend.igengmei.com/'
SHIP_HOST = 'http://m.igengmei.com/'
# 分享购口令开关
FXG_SHOW_IN_SETTLEMENT = True
ICONS = [
{
'icon': 'http://hera.s.igengmei.com/2017/06/05/deaefdd5aa',
'name': u'看日记',
'jump_url': '/diary_list/',
},
{
'icon': 'http://hera.s.igengmei.com/2017/06/05/00557227b6',
'name': u'选美购',
'jump_url': '/promotion_index/',
},
{
'icon': 'http://hera.s.igengmei.com/2017/06/05/d92f750405',
'name': u'找专家',
'jump_url': '/expert_list/',
},
{
'icon': 'http://hera.s.igengmei.com/2017/06/05/4586f60484',
'name': u'查百科',
'jump_url': '/wiki_list/',
},
]
# Captcha 验证码图片样式(1:数字运算;2.四位字符或者数字)
CAPTCHA_STYLE = 2
SEARCH_NEW_SMART_RANK = ['3', '4']
SEARCH_SKU_GRAY = ['2', '0']
SEARCH_SMART_SERVICE = ['1']
FUN_CLAW_SPECIAL_ID = 2057
FUN_CLAW_IMG = 'http://hera.s.igengmei.com/activity/activity-crawl.jpg'
CATCH_CHANNEL_GIFT_IDS = [
('22_2136', 0.8, '10元无门槛优惠券'),
('22_2137', 0.8, '满1000减100元'),
('22_2138', 0.8, '满5000元500元'),
('22_2139', 0.8, '满10000减1000元'),
('5', 0.01, '机构免费项目 '),
('6', 0.002, '品牌化妆品 '),
]
# wechat pub connect prvmsg system
WECHATPUB_WHITE_LIST_FILE = os.path.join(BASE_DIR, 'mobile/views/wechatpub_prvmsg/files/tag_wiki.xlsx')
WECHATPUB_DOCTOR_INFO_XLSX = os.path.join(BASE_DIR, 'mobile/views/wechatpub_prvmsg/files/doctor_info.xlsx')
WECHATPUB_CITY_FILE = os.path.join(BASE_DIR, 'mobile/views/wechatpub_prvmsg/files/city.xlsx')
WECHATPUB_CLICKEVENT_EVENT_KEYS = {
'V1_CLICK_GM_SGROUP_TRAINING': u'''欢迎加入「21天Keep fit健身计划」基础训练班,21天健身计划,帮你瘦成一道闪电!
立即加入:http://m.igengmei.com/wechat/3
立即加入:http://m.igengmei.com/wechat/3
立即加入:http://m.igengmei.com/wechat/3
高级健身私教视频教学,每天组队训练,搭配健身食谱。坚持21天,见证身材每一天的变化。''',
'V1_CLICK_SERVICE_ACCOUNT_BTN': u'欢迎添加所长助理微信ID:gengmeizhuli',
}
# M站新人美券领取落地页配置
NEWBIE_COUPON_LANDING_PAGE = {
'gift_id': 283,
'business_channel_id': 78
}
# M站domain
SHIP_DOMAIN = '.igengmei.com'
# 金刀奖
DEFAULT_DOCTOR_PORTRAIT = 'http://hera.s.igengmei.com/2017/11/17/ba9df707a7'
DEFAULT_HOSPITAL_PORTRAIT = 'http://hera.s.igengmei.com/2017/11/17/036bf5046a'
MIP_DEFAULT_BANNER = "http://hera.s.igengmei.com/2018/04/21/cc0862879a"
MIP_DOWNLOAD_URL = "https://lnk0.com/doENx1"
# 问答内容为带html标签的格式
QA_RICH_TEXT_TYPE = (GRABBING_PLATFORM.ZHIHU, GRABBING_PLATFORM.WEIXIN, GRABBING_PLATFORM.WEIBO, GRABBING_PLATFORM.HERA)
SETTLEMENT_PAY_TIMEOUT = 30 # 待支付剩余时间,默认 30 min
# 手机号医生是否可见
PHONE_CAN_SEE_BY_DOCTOR = True
PAY_TOGGLE = {
'alipay': True,
'huabei': True,
'wechat': True,
'applepay': True,
'xiaoying': True,
'yinuo': True,
'renmai': True,
'maidan': True,
'zhongan': True,
'yirendai': True,
'renmai_credit': True,
}
MOMO_STAT_LOG_TEST_FLAG = False # 陌陌打点是否使用测试地址,正式环境为 False
GMTRACER_PARSER = 'ship.utils.setup_tracer'
# 采样率
TRACE_SAMPLE_RATE = 10.0
MESSAGE_ASK_CASE_IMAGES_LIST_FOR_MOMO_SECKILL = [ # 免费咨询页面案例,momo秒杀专用
{
"before": "http://hera.s.igengmei.com/2018/08/27/b6e003bd64",
"after": "http://hera.s.igengmei.com/2018/08/27/97f14240e8",
},
{
"before": "http://hera.s.igengmei.com/2018/08/27/d396ab0508",
"after": "http://hera.s.igengmei.com/2018/08/27/4f3667bd4c",
},
{
"before": "http://hera.s.igengmei.com/2018/08/27/87b174c469",
"after": "http://hera.s.igengmei.com/2018/08/27/7b3221873e",
},
]
MESSAGE_ASK_CASE_IMAGES_LIST = [ # 免费咨询页面案例
{
"before": "http://hera.s.igengmei.com/serviceactivity/2018/09/12/8f4c4d8f96",
"after": "http://hera.s.igengmei.com/2018/08/27/97f14240e8",
},
{
"before": "http://hera.s.igengmei.com/serviceactivity/2018/09/12/870ed8104d",
"after": "http://hera.s.igengmei.com/2018/08/27/4f3667bd4c",
},
{
"before": "http://hera.s.igengmei.com/serviceactivity/2018/09/12/b7edc1bc47",
"after": "http://hera.s.igengmei.com/2018/08/27/7b3221873e",
},
]
MESSAGE_ASK_CHANNEL_DICT = { # 免费咨询,推广渠道
"momo_seckill": TRANSFER_SOURCE.MOMO_SECKILL,
"momo_ios": TRANSFER_SOURCE.MOMO_IOS,
"bd_search": TRANSFER_SOURCE.BAIDU_SEARCH,
"bd_special_goods": TRANSFER_SOURCE.BAIDU_SPECIAL_GOODS,
"toutiao": TRANSFER_SOURCE.TOUTIAO,
"others": TRANSFER_SOURCE.OTHERS,
}
# 微信小程序的原始Id
WECHAT_SMALL_USER_NAME = 'gh_566b862e19b3'
# coding=utf-8
import datetime
import os
from datetime import timedelta
from celery.schedules import crontab
import helios.rpc
SECRET_KEY = 'fl-lv3j^czg(dupo@hbs(+_+djby9zelwt&rh71@b1x*ptmj4#(^'
STAGGER_FLAG = True
GRAY_TEST = True
AB_TEST_LIST = []
DIARY_SORT_WHITE_LIST = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9']
IOS_UPDATE = True
ANDROID_UPDATE = True
RAVEN_CONFIG = {
'dsn': 'http://97c46f2222a742a99271c70d2b9ccc67:90261dbdb8d0440d921977cd71fe170a@sentry.wanmeizhensuo.com/5',
}
BASE_DIR = os.path.dirname(os.path.dirname(__file__))
DEBUG = True
TEMPLATE_DEBUG = DEBUG
ALLOWED_HOSTS = ['*']
MEDIA_ROOT = '/srv/media/backend/media'
#STATIC_ROOT = '/srv/static/backend/static'
STATICFILES_DIRS = (
)
ENCRYPT_KEY = 'Up[K+ub%pliOnsO5UavFBd)cw5VcyHSX'
BODYPART_ALL_ICON = 'http://hera.s.gmei.com/bodypart/2016/05/25/c95f1dd609'
SERVICE_SPECIAL_DES_ICON = 'http://hera.s.gmei.com/2017/07/10/9950841785'
HIDE_TAGS = False
EVENT_DOCTOR_TITLES = [
('2015-08-05', u'自体脂肪'),
('2015-08-06', u'骨骼'),
('2015-08-07', u'美胸'),
('2015-08-08', u'鼻部'),
('2015-08-09', u'微整形'),
('2015-08-10', u'失败修复'),
('2015-08-11', u'人气医师'),
]
INTEGRAL_GDT = 'http://hermes.test.gmei.com/integralwall/record_activating'
HOT_TAG_ICON = 'http://pic.gmei.com/img/geng.jpg'
HOT_IN_24HRS_ICON = 'http://wanmeizhensuo.qiniudn.com/2015/09/18/49a291d255-thumb'
SHOW_THIRDPARTY_LOGIN_ICON = True
# ====================================================================================================
# =============================================RPC====================================================
# ====================================================================================================
RPC_URL = 'http://rpc.test.gmei.com/api/'
# RPC_URL = 'http://rpc.test.gengmei.cc/api/'
RPC_SECRET = 'basic:M21gQkp0vWmDxlB5wVsIGCgbjdcshCsYaTgl4Rq0E6ug6Ma2teM9tpGCf5TZHsCGGC4cGQ4as9N3KmrDPQ43gA=='
# RPC_INVOKER = helios.rpc.RPCFactory(RPC_URL, RPC_SECRET, debug=DEBUG, debug_unwrap_checker_raise_exception=False, debug_dump_curl=True, use_batch=False).create_invoker()
RPC_INVOKER = helios.rpc.create_default_invoker(debug=DEBUG)
# ====================================================================================================
# ============================================分期付款=================================================
# ====================================================================================================
JIKE_URL = "http://test.geexfinance.com/merchant/service/"
JIKE_USER_ID = 12369
JIKE_SERVICE_ID = "gengmei"
JIKE_SERVICE_HASH = "3710f84987aaa4f455a10f8bbb5c55e1"
# ====================================================================================================
# ============================================七牛存储=================================================
# ====================================================================================================
QINIU_ACCESS_KEY = "UPCOYIJkZOMcdd9FDzpBqYjzWUh55fBpVi3AhWpL"
QINIU_SECRET_KEY = "z5YvpDDSam_JE345Z8J_f3TufzelOW2VOGNoBl9e"
API_HOST = "http://backend-service.default/"
HTTPS_HOST = 'https://backend-service.default/'
WEB_API_HOST = "http://ship-service.default"
PCWEB_API_HOST = "http://pcweb.test.gmei.com"
OPBACK_URL = "http://admin.test.gmei.com"
QINIU_HOST = "http://wanmeizhensuo.qiniudn.com"
# ====================================================================================================
# ============================================ 微 信 =================================================
# ====================================================================================================
WECHAT_APP_ID = "wx403cd28c142c7d87"
WECHAT_PARTNER_ID = "1302548401"
WECHAT_SECRET = "e821f46be6ee45e3ca80d189f989313b"
WECHAT_NOTIFY_URL = "http://backend-service.default/pay/wechat/notify"
WECHAT_KEY = "/srv/secret/apiclient_key.pem"
WECHAT_CERT = "/srv/secret/apiclient_cert.pem"
# ====================================================================================================
# ============================================邮件发送=================================================
# ====================================================================================================
EMAIL_HOST = 'smtp.exmail.qq.com'
EMAIL_HOST_USER = 'doctor@wanmeizhensuo.com'
EMAIL_HOST_PASSWORD = 'gengmei098'
STATIS_EMAIL_USER = 'youjiantongji@wanmeizhensuo.com'
STATIS_EMAIL_PSWD = 'gengmei9801'
DEFAULT_FROM_EMAIL = 'doctor@wanmeizhensuo.com'
BrokenLinkEmailsMiddleware = True
SERVER_EMAIL = 'doctor@wanmeizhensuo.com'
EMAIL_PORT = 25
# ====================================================================================================
# ============================================支付宝===================================================
# ====================================================================================================
ALIPAY_MD5_KEY = "2894fddi6kahmpj56n008le81gjnvdwp"
ALIPAY_SIGN_TYPE = 'MD5'
# ====================================================================================================
# ============================================Redis===================================================
# ====================================================================================================
# REDIS = {'host': 'test-redis', 'port': 6379, 'db': 0}
REDIS = {'host': '192.168.168.142', 'port': 6379, 'db': 0, }
# BROKER_URL = 'redis://test-redis:6379/3'
BROKER_URL = 'redis://192.168.168.142:6379/3'
BROKER_TRANSPORT_OPTIONS = {'visibility_timeout': 259200} # 72 hours
CELERY_TIMEZONE = 'Asia/Shanghai'
CELERYBEAT_SCHEDULE = {
'allocate_stat_doctor': {
'task': 'statistic.tasks.allocate_stat_doctor',
'schedule': crontab(minute=50, hour=23),
'args': ()
},
'refresh_doctorstat_task': {
'task': 'statistic.tasks.refresh_doctorstat_task',
'schedule': timedelta(hours=4),
'args': ()
},
'share_topic_add_point': {
'task': 'api.tasks.share_topic_add_point',
'schedule': timedelta(minutes=30),
'args': ()
},
'link_doctor': {
'task': 'api.tasks.link_doctor',
'schedule': timedelta(minutes=6),
'args': ()
},
'send_sms_mail-9-am': {
'task': 'api.tasks.sms_service',
'schedule': crontab(minute=0, hour=9),
'args': ()
},
'send_stat_mail': {
'task': 'statistic.tasks.send_stat_mail',
'schedule': crontab(minute=5, hour=0),
'args': ()
},
'stat_user_daily': {
'task': 'statistic.tasks.stat_user_daily',
'schedule': crontab(minute=50, hour=23),
'args': ()
},
'hospital_body_sub_items': {
'task': 'api.tasks.hospital_body_sub_items',
'schedule': timedelta(days=1),
'args': ()
},
'doctors2redis': {
'task': 'api.tasks.doctors2redis',
'schedule': crontab(minute=0, hour=3),
'args': ()
},
'hospital2redis': {
'task': 'api.tasks.hospital2redis',
'schedule': crontab(minute=0, hour=3),
'args': ()
},
'send_conversation_stat_mail': {
'task': 'statistic.tasks.send_conversation_stat_mail',
'schedule': crontab(minute=10, hour=0),
'args': ()
},
'send_conversation_weekly_stat_mail': {
'task': 'statistic.tasks.send_conversation_weekly_stat_mail',
'schedule': crontab(minute=10, hour=0, day_of_week='tue'),
'args': ()
},
'doctor_tags': {
'task': 'api.tasks.doctor_tags',
'schedule': crontab(minute=20, hour=5),
'args': ()
},
'tag2redis': {
'task': 'api.tasks.tag2redis',
'schedule': crontab(minute=0, hour=6),
'args': ()
},
'autocomplete_words': {
'task': 'api.tasks.autocomplete_words',
'schedule': crontab(minute=30, hour=3, day_of_week='sunday'),
'args': ()
},
}
# ====================================================================================================
# ============================================美券====================================================
# ====================================================================================================
COUPON_SHARE_SECRET = 'kOMro0bJ.,D*YccA^b]i[)difDe!@llH'
COUPON_SHARE = {
'show_share': True,
'slogan': u'更美CEO刘迪送您“美元”啦!',
'title': '恭喜您获得更美<ems>现金劵!</ems>',
'image': 'http://hera.s.gmei.com/liudi_portrait@2x.png',
'content': u'分享红包给小伙伴,你和朋友都可以获得<ems>1000</ems>元大礼包!',
'wechat': {
'title': '更美CEO刘迪来给我的好朋友们送“美元”啦!',
'text': '8.5更美大促! 800个医美项目免费送,91场0元秒杀,全场低至1折!',
'icon': 'http://hera.s.gmei.com/liudi_portrait.png',
'share_url': 'http://ship-service.default/ticket_share/',
},
'wechat_moments': {
'title': '更美CEO刘迪来给我的好朋友们送“美元”啦!',
'text': '更美CEO刘迪来给我的好朋友们送“美元”啦!',
'icon': 'http://hera.s.gmei.com/liudi_portrait.png',
'share_url': 'http://ship-service.default/ticket_share/',
},
}
SERVICE_HOME_SECKILL_ICON = 'http://wanmeizhensuo.qiniudn.com/2015/11/28/0fa3033388'
ANONYMOUS_USER_ID = 19634221
ORDER_ARBIT_TIMEOUT_DELTA=60
GAIA_REDIS = {'host': '192.168.168.142', 'port': 6379, 'db': 0, }
ANDROID_CURRENT_VERSION_DATA = {
'version': '5.9.2',
'version_code': 592,
'minimum_support_version': '5.5.0',
'description': u'''更美APP,中国第一美容整形与健康服务平台。\n1.新年,新颜,新气象~更美陪你过大年!\n2.首页内容展示焕然一新!are you ready? \n3.部分页面设计大变身,快来>看看我是不是更美了~ \n4. 程序猿GG又一次打败了小怪兽!对不起,让宝宝们受惊了~ \n5. 欢迎你的任何冷酷批评或热烈表白:hi@gmei.com''',
'apk': 'http://dl.gmei.com/apk/gengmei.apk?version=5.9.3',
}
IOS_CURRENT_VERSION_DATA = {
'version': '5.9.2',
'version_code': 11,
'minimum_support_version': '5.5.0',
'apps_latest_support_version': '5.9.2',
'description': u'',
'apk': ''
}
PK_TOPICS = {
24568: {
'title': u'中韩医生pk1',
'start_time': '2016-03-31',
'end_time': '2016-04-30',
'doctors': {
'02adf94ef1a711e5903d0242c0a8001f': {
'flag': 'http://7d9qwy.com2.z0.glb.qiniucdn.com/2016/03/24/5119e449eb',
},
'02adf94ef1a711e5903d0242c0a8001f': {
'flag': 'http://7d9qwy.com2.z0.glb.qiniucdn.com/2016/03/24/b0762d446e',
}
},
'share_data': {
'image': 'http://hera.s.gmei.com/share9.9.jpg',
'wechat_title': u'微信分享标题',
'wechat_content': u'微信分享文案',
'wechat_line': u'微信分享朋友圈文案',
'weibo': u'分享到微博文案 http://xxxxxxx @更美App',
}
},
12177482: {
'title': u'中韩医生pk1',
'start_time': '2016-03-30',
'end_time': '2016-04-04',
'doctors': {
'100001': {
'flag': 'http://7d9qwy.com2.z0.glb.qiniucdn.com/2016/03/24/5119e449eb',
},
'100002': {
'flag': 'http://7d9qwy.com2.z0.glb.qiniucdn.com/2016/03/24/b0762d446e',
}
},
'share_data': {
'image': 'http://hera.s.gmei.com/share9.9.jpg',
'wechat_title': u'中韩医生PK',
'wechat_content': u'快来给自己支持的医生投票了',
'wechat_line': u'中韩医生pk',
'weibo': u'#中韩医生#双眼皮技术谁最好?快来投票→http://m.gmei.com/topic/12177482/ @更美APP',
},
},
12177487: {
'title': u'中韩医生pk1',
'start_time': '2016-03-30',
'end_time': '2016-04-04',
'doctors': {
'100001': {
'flag': 'http://7d9qwy.com2.z0.glb.qiniucdn.com/2016/03/24/5119e449eb',
},
'100002': {
'flag': 'http://7d9qwy.com2.z0.glb.qiniucdn.com/2016/03/24/b0762d446e',
}
},
'share_data': {
'image': 'http://hera.s.gmei.com/share9.9.jpg',
'wechat_title': u'中韩医生PK',
'wechat_content': u'快来给自己支持的医生投票了',
'wechat_line': u'中韩医生pk',
'weibo': u'#中韩医生#双眼皮技术谁最好?快来投票→http://m.gmei.com/topic/12177482/ @更美APP',
},
},
}
PK_TOPICS={}
TIME_CAN_ACCEPT_CALL = (datetime.time(9, 0, 0), datetime.time(15, 0, 0))
GENGMEI_TENANT_ID = 'b2119c17665b4f509ddade8397d58e84'
GENGMEI_KEFU_USER_ID = 20889691
GENGMEI_KEFU_PERSON_ID = '2b64c68727cb11e68181f45c899f3b33'
FEEDBACK_CS_GROUP = '455979578157409fab1ca83f4f824e87'
#SESSION_COOKIE_DOMAIN_GENGMEI = 'backend.test.gengmei.cc'
SESSION_COOKIE_DOMAIN_BACKEND_GENGMEI = 'backend-service.default'
SESSION_COOKIE_DOMAIN_IGENGMEI = '.test.env'
SESSION_COOKIE_DOMAIN = '.test.env' # since 6.0
PUSH_NOTIFICATION_AFTER_FOLLOW_USER = True
ORDER_COMPLETE_SHARE_COUPONGIFT_ID = 40
PAY_TOGGLE = {
'alipay': True,
'wechat': True,
'applepay': True,
'xiaoying': True,
'yinuo': True,
'renmai': True,
'maidan': True,
'zhongan': True,
'yirendai': True,
'renmai_credit': True,
}
PROMOTE_AREA_SERVICE = []
IS_ACCEPT_CALL = True
COUPON_GIFT_URL = 'http://ship-service.default/coupon_gift'
## UNION ##
#CUSTOM_SERVICE_PHONE = 'tel://4006999227,,6666#'
#
#CSC_400_EXT_LITERAL = u'4006-999-227转6666#'
#CSC_400_CALL_URL = 'tel://4006999227,,6666#'
## ZHHT ##
# CUSTOM_SERVICE_PHONE_CALL_TIP = u'如不能接通,请按提示输入分机号 {ext}'
CUSTOM_SERVICE_PHONE = 'tel://01059658065,,6666'
CSC_400_EXT_LITERAL = u'010-5965-8065转6666'
CSC_400_CALL_URL = 'tel://01059658065,,6666'
# 买单分期开关
MAIDAN_INSTALLMENT_TOGGLE = True
INDEX_TAB_CONFIG_2X = [
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/10/7ea40e5e4e",# 普通icon 为空则不更新
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/10/543f0d9aba",# 高亮icon 为空则不更新
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/10/c8566c0463",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/10/406c970989",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/10/392009518b",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/10/392009518b",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/10/56e5bb9217",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/10/cd7e926b40",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/10/64c8969b25",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/10/da466e68ca",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
}
]
INDEX_TAB_CONFIG = [
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/08/2d4e0f337f",# 普通icon 为空则不更新
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/08/b90918ec43",# 高亮icon 为空则不更新
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/08/e47f4bf721",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/08/b5a70ded46",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/08/99deaba0a9",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/08/99deaba0a9",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/08/60cdb44bc0",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/08/e60b5dbc39",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
},
{
'icon_normal': "http://hera.s.gmei.com/slide/2017/02/08/19739929b6",
'icon_pressed': "http://hera.s.gmei.com/slide/2017/02/08/34650a5c69",
'colour_normal': "FFEC8B",
'colour_pressed': "FF0000"
}
]
TEMPLATES = [
{
"BACKEND": "django_jinja.backend.Jinja2",
"APP_DIRS": True,
"DIRS": [os.path.join(BASE_DIR, 'doctor_client', 'templates'), ],
"OPTIONS": {
"match_extension": ".jinja.html",
"newstyle_gettext": True,
"auto_reload": DEBUG,
"context_processors": [
"django.contrib.auth.context_processors.auth",
"django.template.context_processors.debug",
"django.template.context_processors.i18n",
"django.template.context_processors.media",
"django.template.context_processors.static",
"django.template.context_processors.tz",
"django.contrib.messages.context_processors.messages",
],
},
},
{
"BACKEND": "django.template.backends.django.DjangoTemplates",
"DIRS": [],
"APP_DIRS": True,
"OPTIONS": {
"context_processors": [
"django.contrib.auth.context_processors.auth",
"django.template.context_processors.debug",
"django.template.context_processors.i18n",
"django.template.context_processors.media",
"django.template.context_processors.static",
"django.template.context_processors.tz",
"django.contrib.messages.context_processors.messages",
],
},
},
]
# 2017.5 分享文案开关
NEW_SHARE_DATA = True
SERVICE_DETAIL_IN_TEST = True # 全量测试开关
{
"mysql": {
"prod": {
"host": "rdsmaqevmuzj6jy.mysql.rds.aliyuncs.com",
"db": "zhengxing_test"
},
"slave": {
"host": "rdsmaqevmuzj6jy.mysql.rds.aliyuncs.com",
"db": "zhengxing_test"
},
"hera":{
"host": "rdsmaqevmuzj6jy.mysql.rds.aliyuncs.com",
"db": "hera_test"
},
"doris":{
"host": "rdsmaqevmuzj6jy.mysql.rds.aliyuncs.com",
"db": "doris_test"
}
},
"elasticsearch": {
"index": "gm_test"
}
}
{
"dsn": "http://76cf5d6006ad4688a9060d7de3a80396:e652d6a0c45547008943056ec51731c6@sentry.igengmei.com/55"
}
{
"kafka": {
"hosts": [{
"host": "192.168.168.143",
"port": 9092,
"_comment": "zk-kafka.paas"
}],
"default_topic": "gm-logging-paas",
"topics": {
"py_logging": "gm-logging-paas.py-logging",
"inspect": "gm-logging-paas.inspect",
"app": "gm-logging-paas.app"
}
}
}
{
"broker_url": "pyamqp://work:workwork@10.25.251.33:5672/"
}
\ No newline at end of file
{
"redis": {
"host": "redis.test.gengmei",
"port": 6379,
"db": 0
},
"expire": 60,
"dsn": ""
}
{
"redis": {
"host": "r-2ze0670c3c1bb194.redis.rds.aliyuncs.com",
"pass": "Gengmei1!",
"port": 6379,
"db": 15
},
"expire": 60,
"dsn": ""
}
{
"gaia": {
"api_url": "http://gaia-service.default/api/"
},
"rpcd_map": {
"passport": {
"service_list": [
"passport"
],
"url": "http://passport-service.default/"
},
"plutus": {
"service_list": [
"plutus"
],
"url": "http://plutus-service.default/"
},
"poll": {
"service_list": [
"poll"
],
"url": "http://poll--service.default/"
},
"zeus": {
"service_list": [
"zeus"
],
"url": "http://zeus--service.default/"
},
"uc-sms":{
"url": "http://us-sms-service.default/",
"service_list": [
"sms_intermediate_endpoint",
"sms"
]
},
"push2": {
"service_list": [
"push2"
],
"url": "http://push2-service.default/"
},
"themis": {
"service_list": [
"themis"
],
"url": "http://themis-service.default/"
},
"doris": {
"service_list": [
"doris"
],
"url": "http://doris-service.default/"
},
"artemis": {
"service_list": [
"artemis"
],
"url": "http://artemis-service.default/"
},
"apollo": {
"service_list": [
"apollo"
],
"url": "http://apollo-service.default/"
},
"gm-face": {
"service_list": [
"face"
],
"url": "http://gm-face-service.default/"
},
"antispam": {
"service_list": [
"antispam"
],
"url": "http://artispam-service.default/"
},
"mimas": {
"service_list": [
"mimas",
"qa",
"topic",
"diary"
],
"url": "http://mimas-service.default/"
}
}
}
# gaia local settings template
CACHES = {
"default": {
"BACKEND": "django_redis.cache.RedisCache",
"LOCATION": "redis://192.168.168.142/4",
"OPTIONS": {
"CLIENT_CLASS": "django_redis.client.DefaultClient",
}
}
}
# -*- coding:utf-8 -*-
DEBUG = False
RAVEN_CONFIG = {
'dsn': 'http://9f8992868f0348efaca2f4375e8db1df:11764cbbdb1440c38142c9e1a1e663ac@sentry.igengmei.com/131',
}
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # 设置为mysql数据库
'NAME': 'zeus',
'USER': 'work',
'PASSWORD': 'Gengmei1',
'HOST': 'rm-2ze0v6uua2hl9he8e.mysql.rds.aliyuncs.com',
'PORT': '3506',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
"charset": "utf8mb4", # 为了支持emoji表情
},
},
}
DEFAULT_REDIS = {'host': '192.168.168.142', 'port': 6379, 'db': 90, }
BROKER_URL = 'redis://192.168.168.142/91'
CELERY_IMPORTS = ("kefu.tasks",)
CELERY_GMLOGGING_DIR = '/data/log/zeus-celery/celery/'
CAN_NOT_DELETE_ENTRIES = ['455979578157409fab1ca83f4f824e87']
{
"mysql": {
"prod": {
"host": "rdsmaqevmuzj6jy.mysql.rds.aliyuncs.com",
"db": "zhengxing_test"
},
"slave": {
"host": "rdsmaqevmuzj6jy.mysql.rds.aliyuncs.com",
"db": "zhengxing_test"
},
"hera":{
"host": "rdsmaqevmuzj6jy.mysql.rds.aliyuncs.com",
"db": "hera_test"
},
"doris":{
"host": "rdsmaqevmuzj6jy.mysql.rds.aliyuncs.com",
"db": "doris_test"
}
},
"elasticsearch": {
"index": "gm_test"
}
}
{"dsn": "http://c5b4ede52bc6452182565b529735a090:0324e8fff118445a9b38576213b8e759@sentry.igengmei.com/120"}
{
"kafka": {
"hosts": [{
"host": "kafka.dev.gengmei",
"port": 9092
}],
"default_topic": "gm-logging-test",
"topics": {
"inspect": "gm-logging-test.inspect",
"app": "doris"
}
}
}
{
"kafka": {
"hosts": [{
"host": "kafka.dev.gengmei",
"port": 9092
}],
"default_topic": "gm-logging-test",
"topics": {
"inspect": "gm-logging-test.inspect",
"app": "doris"
}
}
}
{
"broker_url": "pyamqp://localhost//"
}
{
"redis": {
"host": "127.0.0.1",
"port": 6379,
"db": 0
},
"expire": 60,
"dsn": ""
}
{
"gaia": {
"api_url": "http://gaia-service.default/api/"
},
"rpcd_map": {
"passport": {
"service_list": [
"passport"
],
"url": "http://passport-service.default/"
},
"plutus": {
"service_list": [
"plutus"
],
"url": "http://plutus-service.default/"
},
"poll": {
"service_list": [
"poll"
],
"url": "http://poll--service.default/"
},
"zeus": {
"service_list": [
"zeus"
],
"url": "http://zeus--service.default/"
},
"uc-sms":{
"url": "http://us-sms-service.default/",
"service_list": [
"sms_intermediate_endpoint",
"sms"
]
},
"push2": {
"service_list": [
"push2"
],
"url": "http://push2-service.default/"
},
"themis": {
"service_list": [
"themis"
],
"url": "http://themis-service.default/"
},
"doris": {
"service_list": [
"doris"
],
"url": "http://doris-service.default/"
},
"artemis": {
"service_list": [
"artemis"
],
"url": "http://artemis-service.default/"
},
"apollo": {
"service_list": [
"apollo"
],
"url": "http://apollo-service.default/"
},
"gm-face": {
"service_list": [
"face"
],
"url": "http://gm-face-service.default/"
},
"antispam": {
"service_list": [
"antispam"
],
"url": "http://artispam-service.default/"
},
"mimas": {
"service_list": [
"mimas",
"qa",
"topic",
"diary"
],
"url": "http://mimas-service.default/"
}
}
}
<!DOCTYPE html>
<html lang='en'>
<head prefix='og: http://ogp.me/ns#'>
<meta charset='utf-8'>
<meta content='IE=edge' http-equiv='X-UA-Compatible'>
<meta content='object' property='og:type'>
<meta content='GitLab' property='og:site_name'>
<meta content='Sign in' property='og:title'>
<meta content='GitLab Community Edition' property='og:description'>
<meta content='http://git.wanmeizhensuo.com/assets/gitlab_logo-f94735ed1486ec1e35ce78e4c1747b4d.png' property='og:image'>
<meta content='http://git.wanmeizhensuo.com/users/sign_in' property='og:url'>
<meta content='summary' property='twitter:card'>
<meta content='Sign in' property='twitter:title'>
<meta content='GitLab Community Edition' property='twitter:description'>
<meta content='http://git.wanmeizhensuo.com/assets/gitlab_logo-f94735ed1486ec1e35ce78e4c1747b4d.png' property='twitter:image'>
<title>Sign in · GitLab</title>
<meta content='GitLab Community Edition' name='description'>
<link rel="shortcut icon" type="image/x-icon" href="/assets/favicon-0037f4682f7f2d45973338aad43f3d54.ico" />
<link rel="stylesheet" media="all" href="/assets/application-9b36a04f9f4e169587d71114d5cea44e.css" />
<link rel="stylesheet" media="print" href="/assets/print-2cb1262fb60ceb73f2fe76fd1a61dccf.css" />
<script src="/assets/application-da325dfd87be97395662ee59f5f4b1b1.js"></script>
<meta name="csrf-param" content="authenticity_token" />
<meta name="csrf-token" content="39yuVeX12lHh8GBRzo3pfxotVlF15mPWVGx6nN1dx8riH08byNv8ktsmUc8Vxu+wNo0JGAbSoChz/7u43FYT2g==" />
<script>
//<![CDATA[
window.gon={};gon.api_version="v3";gon.default_avatar_url="http://git.wanmeizhensuo.com/assets/no_avatar-0801eb7ed213327da2a534095a75b248.png";gon.default_issues_tracker="gitlab";gon.max_file_size=20;gon.relative_url_root="";gon.user_color_scheme="white";
//]]>
</script>
<meta content='origin-when-cross-origin' name='referrer'>
<meta content='width=device-width, initial-scale=1, maximum-scale=1' name='viewport'>
<meta content='#474D57' name='theme-color'>
<link rel="apple-touch-icon" type="image/x-icon" href="/assets/touch-icon-iphone-c2b181d197c3b7be4f8ac381458895bb.png" />
<link rel="apple-touch-icon" type="image/x-icon" href="/assets/touch-icon-ipad-fede15aef7610235936a27957400503a.png" sizes="76x76" />
<link rel="apple-touch-icon" type="image/x-icon" href="/assets/touch-icon-iphone-retina-88529dea2f9320df1a3cc45d92e86147.png" sizes="120x120" />
<link rel="apple-touch-icon" type="image/x-icon" href="/assets/touch-icon-ipad-retina-c0dbda7e71802ee480f6d666da4b834a.png" sizes="152x152" />
<meta content='/assets/msapplication-tile-2efcb14bec26fd879dd1914db581f8f9.png' name='msapplication-TileImage'>
<meta content='#30353E' name='msapplication-TileColor'>
<style>
[data-user-is] {
display: none !important;
}
[data-user-is=""] {
display: block !important;
}
[data-user-is=""][data-display="inline"] {
display: inline !important;
}
[data-user-is-not] {
display: block !important;
}
[data-user-is-not][data-display="inline"] {
display: inline !important;
}
[data-user-is-not=""] {
display: none !important;
}
</style>
</head>
<body class='ui_charcoal login-page application navless'>
<header class='navbar navbar-fixed-top navbar-empty'>
<div class='container'>
<div class='center-logo'>
<svg width="36" height="36" id="tanuki-logo">
<path id="tanuki-right-ear" class="tanuki-shape" fill="#e24329" d="M2 14l9.38 9v-9l-4-12.28c-.205-.632-1.176-.632-1.38 0z"/>
<path id="tanuki-left-ear" class="tanuki-shape" fill="#e24329" d="M34 14l-9.38 9v-9l4-12.28c.205-.632 1.176-.632 1.38 0z"/>
<path id="tanuki-nose" class="tanuki-shape" fill="#e24329" d="M18,34.38 3,14 33,14 Z"/>
<path id="tanuki-right-eye" class="tanuki-shape" fill="#fc6d26" d="M18,34.38 11.38,14 2,14 6,25Z"/>
<path id="tanuki-left-eye" class="tanuki-shape" fill="#fc6d26" d="M18,34.38 24.62,14 34,14 30,25Z"/>
<path id="tanuki-right-cheek" class="tanuki-shape" fill="#fca326" d="M2 14L.1 20.16c-.18.565 0 1.2.5 1.56l17.42 12.66z"/>
<path id="tanuki-left-cheek" class="tanuki-shape" fill="#fca326" d="M34 14l1.9 6.16c.18.565 0 1.2-.5 1.56L18 34.38z"/>
</svg>
</div>
</div>
</header>
<div class='container navless-container'>
<div class='content'>
<div class='flash-container'>
<div class='flash-alert'>
You need to sign in or sign up before continuing.
</div>
</div>
<div class='row'>
<div class='col-sm-5 pull-right'>
<div>
<div class='login-box'>
<div class='login-heading'>
<h3>Sign in</h3>
</div>
<div class='login-body'>
<form class="new_user" id="new_user" action="/users/sign_in" accept-charset="UTF-8" method="post"><input name="utf8" type="hidden" value="&#x2713;" /><input type="hidden" name="authenticity_token" value="9GyDlQm8LQH5Ngv0zB4jMe0RBvXtIeij6x1m1JUR8bvJr2LbJJILwsPgOmoXVSX+wbFZvJ4VK13MjqfwlBolqw==" /><input class="form-control top" placeholder="Username or Email" autofocus="autofocus" autocapitalize="off" autocorrect="off" type="text" name="user[login]" id="user_login" />
<input class="form-control bottom" placeholder="Password" type="password" name="user[password]" id="user_password" />
<div class='remember-me checkbox'>
<label for='user_remember_me'>
<input name="user[remember_me]" type="hidden" value="0" /><input type="checkbox" value="1" name="user[remember_me]" id="user_remember_me" />
<span>Remember me</span>
</label>
<div class='pull-right'>
<a href="/users/password/new">Forgot your password?</a>
</div>
</div>
<div>
<input type="submit" name="commit" value="Sign in" class="btn btn-save" />
</div>
</form>
</div>
</div>
<div class='clearfix prepend-top-20'>
<p>
<span class='light'>
Sign in with &nbsp;
</span>
<span class='light'>
<a class="oauth-image-link" data-no-turbolink="true" rel="nofollow" data-method="post" href="/users/auth/github"><img alt="GitHub" title="Sign in with GitHub" src="/assets/auth_buttons/github_64-93c6eb739ee4d6e27937c4b14aea5e8f.png" /></a>
</span>
</p>
</div>
</div>
</div>
<div class='col-sm-7 brand-holder pull-left'>
<h1>
GitLab Community Edition
</h1>
<h3>Open source software to collaborate on code</h3>
<p>
Manage git repositories with fine grained access controls that keep your code secure.
Perform code reviews and enhance collaboration with merge requests.
Each project can also have an issue tracker and a wiki.
</p>
</div>
</div>
</div>
</div>
<hr>
<div class='container'>
<div class='footer-links'>
<a href="/explore">Explore</a>
<a href="/help">Help</a>
<a href="https://about.gitlab.com/">About GitLab</a>
</div>
</div>
</body>
</html>
<!DOCTYPE html>
<html lang='en'>
<head prefix='og: http://ogp.me/ns#'>
<meta charset='utf-8'>
<meta content='IE=edge' http-equiv='X-UA-Compatible'>
<meta content='object' property='og:type'>
<meta content='GitLab' property='og:site_name'>
<meta content='Sign in' property='og:title'>
<meta content='GitLab Community Edition' property='og:description'>
<meta content='http://git.wanmeizhensuo.com/assets/gitlab_logo-f94735ed1486ec1e35ce78e4c1747b4d.png' property='og:image'>
<meta content='http://git.wanmeizhensuo.com/users/sign_in' property='og:url'>
<meta content='summary' property='twitter:card'>
<meta content='Sign in' property='twitter:title'>
<meta content='GitLab Community Edition' property='twitter:description'>
<meta content='http://git.wanmeizhensuo.com/assets/gitlab_logo-f94735ed1486ec1e35ce78e4c1747b4d.png' property='twitter:image'>
<title>Sign in · GitLab</title>
<meta content='GitLab Community Edition' name='description'>
<link rel="shortcut icon" type="image/x-icon" href="/assets/favicon-0037f4682f7f2d45973338aad43f3d54.ico" />
<link rel="stylesheet" media="all" href="/assets/application-9b36a04f9f4e169587d71114d5cea44e.css" />
<link rel="stylesheet" media="print" href="/assets/print-2cb1262fb60ceb73f2fe76fd1a61dccf.css" />
<script src="/assets/application-da325dfd87be97395662ee59f5f4b1b1.js"></script>
<meta name="csrf-param" content="authenticity_token" />
<meta name="csrf-token" content="9OZnTfHE54/OoeiMKEywZnla3aaKvMqJU7mtnEd8UqmosQguxdHiyLx0kNccTEFWxGAWGHtp8tdnt1JWEpkyzg==" />
<script>
//<![CDATA[
window.gon={};gon.api_version="v3";gon.default_avatar_url="http://git.wanmeizhensuo.com/assets/no_avatar-0801eb7ed213327da2a534095a75b248.png";gon.default_issues_tracker="gitlab";gon.max_file_size=20;gon.relative_url_root="";gon.user_color_scheme="white";
//]]>
</script>
<meta content='origin-when-cross-origin' name='referrer'>
<meta content='width=device-width, initial-scale=1, maximum-scale=1' name='viewport'>
<meta content='#474D57' name='theme-color'>
<link rel="apple-touch-icon" type="image/x-icon" href="/assets/touch-icon-iphone-c2b181d197c3b7be4f8ac381458895bb.png" />
<link rel="apple-touch-icon" type="image/x-icon" href="/assets/touch-icon-ipad-fede15aef7610235936a27957400503a.png" sizes="76x76" />
<link rel="apple-touch-icon" type="image/x-icon" href="/assets/touch-icon-iphone-retina-88529dea2f9320df1a3cc45d92e86147.png" sizes="120x120" />
<link rel="apple-touch-icon" type="image/x-icon" href="/assets/touch-icon-ipad-retina-c0dbda7e71802ee480f6d666da4b834a.png" sizes="152x152" />
<meta content='/assets/msapplication-tile-2efcb14bec26fd879dd1914db581f8f9.png' name='msapplication-TileImage'>
<meta content='#30353E' name='msapplication-TileColor'>
<style>
[data-user-is] {
display: none !important;
}
[data-user-is=""] {
display: block !important;
}
[data-user-is=""][data-display="inline"] {
display: inline !important;
}
[data-user-is-not] {
display: block !important;
}
[data-user-is-not][data-display="inline"] {
display: inline !important;
}
[data-user-is-not=""] {
display: none !important;
}
</style>
</head>
<body class='ui_charcoal login-page application navless'>
<header class='navbar navbar-fixed-top navbar-empty'>
<div class='container'>
<div class='center-logo'>
<svg width="36" height="36" id="tanuki-logo">
<path id="tanuki-right-ear" class="tanuki-shape" fill="#e24329" d="M2 14l9.38 9v-9l-4-12.28c-.205-.632-1.176-.632-1.38 0z"/>
<path id="tanuki-left-ear" class="tanuki-shape" fill="#e24329" d="M34 14l-9.38 9v-9l4-12.28c.205-.632 1.176-.632 1.38 0z"/>
<path id="tanuki-nose" class="tanuki-shape" fill="#e24329" d="M18,34.38 3,14 33,14 Z"/>
<path id="tanuki-right-eye" class="tanuki-shape" fill="#fc6d26" d="M18,34.38 11.38,14 2,14 6,25Z"/>
<path id="tanuki-left-eye" class="tanuki-shape" fill="#fc6d26" d="M18,34.38 24.62,14 34,14 30,25Z"/>
<path id="tanuki-right-cheek" class="tanuki-shape" fill="#fca326" d="M2 14L.1 20.16c-.18.565 0 1.2.5 1.56l17.42 12.66z"/>
<path id="tanuki-left-cheek" class="tanuki-shape" fill="#fca326" d="M34 14l1.9 6.16c.18.565 0 1.2-.5 1.56L18 34.38z"/>
</svg>
</div>
</div>
</header>
<div class='container navless-container'>
<div class='content'>
<div class='flash-container'>
<div class='flash-alert'>
You need to sign in or sign up before continuing.
</div>
</div>
<div class='row'>
<div class='col-sm-5 pull-right'>
<div>
<div class='login-box'>
<div class='login-heading'>
<h3>Sign in</h3>
</div>
<div class='login-body'>
<form class="new_user" id="new_user" action="/users/sign_in" accept-charset="UTF-8" method="post"><input name="utf8" type="hidden" value="&#x2713;" /><input type="hidden" name="authenticity_token" value="9O8JVOq9QQMdENm4nM1qhSnYvbtQc8hpi0c1LOInNAqouGY33qhERG/FoeOozZu1lOJ2BaGm8De/Scrmt8JUbQ==" /><input class="form-control top" placeholder="Username or Email" autofocus="autofocus" autocapitalize="off" autocorrect="off" type="text" name="user[login]" id="user_login" />
<input class="form-control bottom" placeholder="Password" type="password" name="user[password]" id="user_password" />
<div class='remember-me checkbox'>
<label for='user_remember_me'>
<input name="user[remember_me]" type="hidden" value="0" /><input type="checkbox" value="1" name="user[remember_me]" id="user_remember_me" />
<span>Remember me</span>
</label>
<div class='pull-right'>
<a href="/users/password/new">Forgot your password?</a>
</div>
</div>
<div>
<input type="submit" name="commit" value="Sign in" class="btn btn-save" />
</div>
</form>
</div>
</div>
<div class='clearfix prepend-top-20'>
<p>
<span class='light'>
Sign in with &nbsp;
</span>
<span class='light'>
<a class="oauth-image-link" data-no-turbolink="true" rel="nofollow" data-method="post" href="/users/auth/github"><img alt="GitHub" title="Sign in with GitHub" src="/assets/auth_buttons/github_64-93c6eb739ee4d6e27937c4b14aea5e8f.png" /></a>
</span>
</p>
</div>
</div>
</div>
<div class='col-sm-7 brand-holder pull-left'>
<h1>
GitLab Community Edition
</h1>
<h3>Open source software to collaborate on code</h3>
<p>
Manage git repositories with fine grained access controls that keep your code secure.
Perform code reviews and enhance collaboration with merge requests.
Each project can also have an issue tracker and a wiki.
</p>
</div>
</div>
</div>
</div>
<hr>
<div class='container'>
<div class='footer-links'>
<a href="/explore">Explore</a>
<a href="/help">Help</a>
<a href="https://about.gitlab.com/">About GitLab</a>
</div>
</div>
</body>
</html>
{
"gaia": {
"api_url": "http://rpc.test.env/api/"
},
"rpcd_map": {
"antispam": {
"service_list": [
"antispam"
],
"url": "http://antispam.test.env/"
},
"apollo": {
"service_list": [
"apollo"
],
"url": "http://apollo.test.gengmei"
},
"artemis": {
"service_list": [
"artemis"
],
"url": "http://artemis.test.env"
},
"cadus": {
"service_list": [
"cadus"
],
"url": "http://cadus.test.env:5201/"
},
"doris": {
"service_list": [
"doris"
],
"url": "http://doris.test.env"
},
"face": {
"service_list": [
"face"
],
"url": "http://gm-face.test.gengmei:8888/"
},
"mimas": {
"service_list": [
"mimas",
"qa",
"topic",
"diary"
],
"url": "http://mimas.test.env/"
},
"passport": {
"service_list": [
"passport"
],
"url": "http://passport.test.gengmei"
},
"plutus": {
"service_list": [
"plutus"
],
"url": "http://plutus.test.gengmei"
},
"poll": {
"service_list": [
"poll"
],
"url": "http://gm-poll.test.gengmei:6501/"
},
"push2": {
"service_list": [
"push2"
],
"url": "http://push2.test.gengmei/"
},
"themis": {
"service_list": [
"themis"
],
"url": "http://themis.test.gengmei"
},
"uc-sms": {
"service_list": [
"sms_intermediate_endpoint",
"sms"
],
"url": "http://sms.test.gengmei/"
},
"zeus": {
"service_list": [
"zeus"
],
"url": "http://zeus.test.gengmei"
}
}
}
{
"gaia": {
"api_url": "http://localhost:8001/api/"
},
"rpcd_map": {
"antispam": {
"service_list": [
"antispam"
],
"url": "http://antispam.test.env/"
},
"apollo": {
"service_list": [
"apollo"
],
"url": "http://apollo.test.gengmei"
},
"artemis": {
"service_list": [
"artemis"
],
"url": "http://artemis.test.env"
},
"cadus": {
"service_list": [
"cadus"
],
"url": "http://cadus.test.env:5201/"
},
"doris": {
"service_list": [
"doris"
],
"url": "http://localhost:8003"
},
"face": {
"service_list": [
"face"
],
"url": "http://gm-face.test.gengmei:8888/"
},
"mimas": {
"service_list": [
"mimas",
"qa",
"topic",
"diary"
],
"url": "http://127.0.0.1:8002/"
},
"passport": {
"service_list": [
"passport"
],
"url": "http://passport.test.gengmei"
},
"plutus": {
"service_list": [
"plutus"
],
"url": "http://plutus.test.gengmei"
},
"poll": {
"service_list": [
"poll"
],
"url": "http://gm-poll.test.gengmei:6501/"
},
"push2": {
"service_list": [
"push2"
],
"url": "http://push2.test.gengmei/"
},
"themis": {
"service_list": [
"themis"
],
"url": "http://themis.test.gengmei"
},
"uc-sms": {
"service_list": [
"sms_intermediate_endpoint",
"sms"
],
"url": "http://sms.test.gengmei/"
},
"zeus": {
"service_list": [
"zeus"
],
"url": "http://zeus.test.gengmei"
}
}
}
{
"gaia": {
"api_url": "http://127.0.0.1:4321/api/"
},
"rpcd_map": {
"passport": {
"service_list": [
"passport"
],
"url": "http://127.0.0.1:4321/"
},
"plutus": {
"service_list": [
"plutus"
],
"url": "http://127.0.0.1:4321/"
},
"poll": {
"service_list": [
"poll"
],
"url": "http://127.0.0.1:4321/"
},
"zeus": {
"service_list": [
"zeus"
],
"url": "http://127.0.0.1:4321/"
},
"uc-sms":{
"url": "http://127.0.0.1:4321/",
"service_list": [
"sms_intermediate_endpoint",
"sms"
]
},
"push2": {
"service_list": [
"push2"
],
"url": "http://127.0.0.1:4321/"
},
"themis": {
"service_list": [
"themis"
],
"url": "http://127.0.0.1:4321/"
},
"doris": {
"service_list": [
"doris"
],
"url": "http://127.0.0.1:4321/"
},
"artemis": {
"service_list": [
"artemis"
],
"url": "http://127.0.0.1:4321/"
},
"apollo": {
"service_list": [
"apollo"
],
"url": "http://127.0.0.1:4321/"
},
"gm-face": {
"service_list": [
"face"
],
"url": "http://127.0.0.1:4321/"
},
"antispam": {
"service_list": [
"antispam"
],
"url": "http://127.0.0.1:4321/"
},
"mimas": {
"service_list": [
"mimas",
"qa",
"topic",
"diary"
],
"url": "http://127.0.0.1:4321/"
}
}
}
\ No newline at end of file
{
"gaia": {
"api_url": "http://localhost:8001/api/"
},
"rpcd_map": {
"antispam": {
"service_list": [
"antispam"
],
"url": "http://antispam.test.env/"
},
"apollo": {
"service_list": [
"apollo"
],
"url": "http://apollo.test.gengmei"
},
"artemis": {
"service_list": [
"artemis"
],
"url": "http://localhost:8004/"
},
"cadus": {
"service_list": [
"cadus"
],
"url": "http://cadus.test.env:5201/"
},
"doris": {
"service_list": [
"doris"
],
"url": "http://localhost:8003"
},
"face": {
"service_list": [
"face"
],
"url": "http://gm-face.test.gengmei:8888/"
},
"mimas": {
"service_list": [
"mimas",
"qa",
"topic",
"diary"
],
"url": "http://127.0.0.1:8002/"
},
"passport": {
"service_list": [
"passport"
],
"url": "http://passport.test.gengmei"
},
"plutus": {
"service_list": [
"plutus"
],
"url": "http://plutus.test.gengmei"
},
"poll": {
"service_list": [
"poll"
],
"url": "http://gm-poll.test.gengmei:6501/"
},
"push2": {
"service_list": [
"push2"
],
"url": "http://push2.test.gengmei/"
},
"themis": {
"service_list": [
"themis"
],
"url": "http://themis.test.gengmei"
},
"uc-sms": {
"service_list": [
"sms_intermediate_endpoint",
"sms"
],
"url": "http://sms.test.gengmei/"
},
"zeus": {
"service_list": [
"zeus"
],
"url": "http://zeus.test.gengmei"
}
}
}
{
"gaia": {
"api_url": "http://gaia-service/api/"
},
"rpcd_map": {
"antispam": {
"service_list": [
"antispam"
],
"url": "http://antispam.test.env/"
},
"apollo": {
"service_list": [
"apollo"
],
"url": "http://apollo.test.gengmei"
},
"artemis": {
"service_list": [
"artemis"
],
"url": "http://artemis.test.env"
},
"cadus": {
"service_list": [
"cadus"
],
"url": "http://cadus.test.env:5201/"
},
"doris": {
"service_list": [
"doris"
],
"url": "http://doris-service"
},
"face": {
"service_list": [
"face"
],
"url": "http://gm-face.test.gengmei:8888/"
},
"mimas": {
"service_list": [
"mimas",
"qa",
"topic",
"diary"
],
"url": "http://mimas-service/"
},
"passport": {
"service_list": [
"passport"
],
"url": "http://passport.test.gengmei"
},
"plutus": {
"service_list": [
"plutus"
],
"url": "http://plutus.test.gengmei"
},
"poll": {
"service_list": [
"poll"
],
"url": "http://gm-poll.test.gengmei:6501/"
},
"push2": {
"service_list": [
"push2"
],
"url": "http://push2.test.gengmei/"
},
"themis": {
"service_list": [
"themis"
],
"url": "http://themis.test.gengmei"
},
"uc-sms": {
"service_list": [
"sms_intermediate_endpoint",
"sms"
],
"url": "http://sms.test.gengmei/"
},
"zeus": {
"service_list": [
"zeus"
],
"url": "http://zeus.test.gengmei"
}
}
}
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 to comment