添加日志
This commit is contained in:
parent
bf9582b5ca
commit
5508f274a9
@ -51,8 +51,10 @@ class Build_Gamelog_Config():
|
|||||||
),"""
|
),"""
|
||||||
except Exception:
|
except Exception:
|
||||||
log.error(f"build context failed with {line}.", exc_info=True)
|
log.error(f"build context failed with {line}.", exc_info=True)
|
||||||
|
return False
|
||||||
with open(self.filename, 'w') as f:
|
with open(self.filename, 'w') as f:
|
||||||
f.write(f"{start}\n{content}\n{end}")
|
f.write(f"{start}\n{content}\n{end}")
|
||||||
|
return True
|
||||||
|
|
||||||
def deploy_config(self):
|
def deploy_config(self):
|
||||||
ip_addr = self.get_ip_addr()
|
ip_addr = self.get_ip_addr()
|
||||||
@ -89,8 +91,9 @@ class Build_Gamelog_Config():
|
|||||||
|
|
||||||
def run(self):
|
def run(self):
|
||||||
keys = self.get_keys()
|
keys = self.get_keys()
|
||||||
print(f"1={keys}")
|
|
||||||
data = self.split_data(keys)
|
data = self.split_data(keys)
|
||||||
print(f"2={data}")
|
if self.build_config(data):
|
||||||
self.build_config(data)
|
if self.deploy_config():
|
||||||
self.deploy_config()
|
log.info("deploy config 2 gamelog success!")
|
||||||
|
else:
|
||||||
|
log.error("deploy config failed!")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user