Updates to maintenance script for EBS compatibility
parent
c1e7fa936c
commit
386a8515a7
|
@ -3,3 +3,7 @@ config.yaml
|
|||
*.pyc
|
||||
*.xml
|
||||
*.code-workspace
|
||||
# Elastic Beanstalk Files
|
||||
.elasticbeanstalk/*
|
||||
!.elasticbeanstalk/*.cfg.yml
|
||||
!.elasticbeanstalk/*.global.yml
|
||||
|
|
3
main.py
3
main.py
|
@ -77,7 +77,10 @@ def loadConfig():
|
|||
|
||||
if __name__ == '__main__':
|
||||
args = parseArgs()
|
||||
try:
|
||||
loadConfig()
|
||||
except FileNotFoundError:
|
||||
pass
|
||||
main(
|
||||
secondsAgo=args.time,
|
||||
year=args.year,
|
||||
|
|
|
@ -45,9 +45,7 @@ class Renewal(BaseDoc):
|
|||
claimants = Nested(Claimant)
|
||||
|
||||
class Index:
|
||||
with open('config.yaml', 'r') as yamlFile:
|
||||
config = yaml.safe_load(yamlFile)
|
||||
name = config['ELASTICSEARCH']['ES_CCR_INDEX']
|
||||
name = os.environ['ES_CCR_INDEX']
|
||||
|
||||
|
||||
class CCE(BaseDoc):
|
||||
|
@ -60,6 +58,4 @@ class CCE(BaseDoc):
|
|||
registrations = Nested(Registration)
|
||||
|
||||
class Index:
|
||||
with open('config.yaml', 'r') as yamlFile:
|
||||
config = yaml.safe_load(yamlFile)
|
||||
name = config['ELASTICSEARCH']['ES_CCE_INDEX']
|
||||
name = os.environ['ES_CCE_INDEX']
|
||||
|
|
Loading…
Reference in New Issue