comparison GenerateConfigurationForTests.py @ 11:c660a64ce2dd

cont
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 18 Jun 2015 14:18:49 +0200
parents 2dbba2e6aa4b
children 7b69a561f4d3
comparison
equal deleted inserted replaced
10:5f73008bb873 11:c660a64ce2dd
73 73
74 config = re.sub(r'("DicomAet"\s*:)\s*".*?"', r'\1 "ORTHANC"', config) 74 config = re.sub(r'("DicomAet"\s*:)\s*".*?"', r'\1 "ORTHANC"', config)
75 config = re.sub(r'("RemoteAccessAllowed"\s*:)\s*false', r'\1 true', config) 75 config = re.sub(r'("RemoteAccessAllowed"\s*:)\s*false', r'\1 true', config)
76 config = re.sub(r'("AuthenticationEnabled"\s*:)\s*false', r'\1 true', config) 76 config = re.sub(r'("AuthenticationEnabled"\s*:)\s*false', r'\1 true', config)
77 config = re.sub(r'("RegisteredUsers"\s*:)\s*{', r'\1 { "alice" : "orthanctest"', config) 77 config = re.sub(r'("RegisteredUsers"\s*:)\s*{', r'\1 { "alice" : "orthanctest"', config)
78 config = re.sub(r'("DicomModalities"\s*:)\s*{', r'\1 { "orthanc" : [ "%s", "%s", %d ]' % 78 config = re.sub(r'("DicomModalities"\s*:)\s*{', r'\1 { "orthanctest" : [ "%s", "%s", %d ]' %
79 ('ORTHANCTEST', ip, 5001), config) 79 ('ORTHANCTEST', ip, 5001), config)
80 config = re.sub(r'("OrthancPeers"\s*:)\s*{', r'\1 { "peer" : [ "http://%s:%d/", "%s", "%s" ]' %
81 (ip, 5000, 'alice', 'orthanctest'), config)
80 82
81 with open(args.target, 'wt') as f: 83 with open(args.target, 'wt') as f:
82 f.write(config) 84 f.write(config)
83 85