1
This commit is contained in:
parent
dd284f76a7
commit
f2a73368ff
File diff suppressed because one or more lines are too long
10
role/shanhai/files/pay.py
Normal file
10
role/shanhai/files/pay.py
Normal file
@ -0,0 +1,10 @@
|
||||
import json
|
||||
|
||||
res = {
|
||||
'paycon': {'default': None}
|
||||
}
|
||||
with open('pay.json', 'r', encoding='utf8') as f:
|
||||
res['paycon']['default'] = json.load(f)
|
||||
|
||||
with open('pay.json', 'w', encoding='utf8') as f:
|
||||
json.dump(res, f)
|
@ -2,13 +2,19 @@
|
||||
- name: 下载 pay
|
||||
local_action: subversion
|
||||
args:
|
||||
repo: "{{svn}}/shanhai/trunk/server/json/pay.json"
|
||||
repo: "{{svn}}/shanhai/trunk/server/pay/default.json"
|
||||
dest: "{{ansible_role_name}}/files/pay.json"
|
||||
username: "{{username}}"
|
||||
password: "{{password}}"
|
||||
export: yes
|
||||
force: yes
|
||||
|
||||
- name: 处理pay
|
||||
local_action: shell
|
||||
args:
|
||||
chdir: "{{ansible_role_name}}/files/"
|
||||
cmd: "python3 pay.py"
|
||||
|
||||
- name: 拷贝到gm
|
||||
copy:
|
||||
src: pay.json
|
||||
|
Loading…
Reference in New Issue
Block a user