Commit 5117889f by Feanil Patel

Change how the deployment gets updated.

parent 51ffbc06
...@@ -71,7 +71,7 @@ class MongoConnection: ...@@ -71,7 +71,7 @@ class MongoConnection:
Adds the built AMI to the deployment Adds the built AMI to the deployment
collection collection
""" """
query = { update = {
'_id': args.jenkins_build, '_id': args.jenkins_build,
'plays': { 'plays': {
args.play: { args.play: {
...@@ -79,9 +79,9 @@ class MongoConnection: ...@@ -79,9 +79,9 @@ class MongoConnection:
}, },
}, },
} }
update = query.copy() query = { '_id': args.jenkins_build }
pprint(update)
update['plays'][args.play]['amis'][args.environment] = ami update['plays'][args.play]['amis'][args.environment] = ami
pprint(update)
self.mongo_deployment.update(query, update, True) self.mongo_deployment.update(query, update, True)
......
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