Explorar o código

Updated how get the information in env

Jean Sumara %!s(int64=5) %!d(string=hai) anos
pai
achega
93183634ff
Modificáronse 1 ficheiros con 4 adicións e 1 borrados
  1. 4 1
      src/App/Listener/ExportListener.php

+ 4 - 1
src/App/Listener/ExportListener.php

@@ -41,13 +41,16 @@ class ExportListener
     public function run(){
         echo "Running listener\n";
 
-        $envNameQueue = getenv('FTTH_AMQP');
+        $envNameQueue = getenv('FTTH_EXPORT');
         if($this->getNameQueue()){
             $envNameQueue = $this->getNameQueue();
         }
         $callbackMessage = function($msg) {
             $msgBody = unserialize($msg->body);
 
+            $msgBody['endpointBase'] = 'https://base.'.getenv('CLIENT').'.'.getenv('DOMAIN');
+            $msgBody['endpointOnus'] = 'https://ftth.'.getenv('CLIENT').'.'.getenv('DOMAIN').'/api/onus-export';
+
             $headers = TokenFactory::create($msgBody);
 
             $notificationId = $msgBody['notificationId'];