denishpatel / pygmy

Pygmy: Saving AWS Bills on Standby DB Servers
5 stars 1 forks source link

Pygmy is using the wrong db credentials #46

Closed benchub closed 3 years ago

benchub commented 3 years ago

We fixed this on the call with

diff --git a/engine/aws/ec_wrapper.py b/engine/aws/ec_wrapper.py
index 6942e0f..c214a3e 100644
--- a/engine/aws/ec_wrapper.py
+++ b/engine/aws/ec_wrapper.py
@@ -18,8 +18,9 @@ class EC2Service(AWSServices, metaclass=Singleton):
         super(EC2Service, self).__init__()

     def create_connection(self, db):
-        credentials = DbCredentials.objects.get(name="ec2")
+        credentials = DbCredentials.objects.get(name="postgres")

...but I don't know if that's the way you want to do it.

AadiMehta commented 3 years ago

Fixed in current commit: SHA-1: 2fb166f2fb52b1fd8e45151bffc80e55244c9237