Merge branch 'feature/use_env_file'
This commit is contained in:
@@ -5,3 +5,4 @@ appointment.log
|
||||
utils/*.log
|
||||
.~contact.xlsx
|
||||
/db/sim_infos.xlsx
|
||||
.env
|
||||
|
||||
Binary file not shown.
@@ -1,4 +1,9 @@
|
||||
import os
|
||||
from dotenv import load_dotenv
|
||||
|
||||
load_dotenv()
|
||||
|
||||
LOG_SOURCE = os.getenv("LOG_SOURCE")
|
||||
|
||||
BAUDRATE = 115200
|
||||
|
||||
|
||||
+3
-1
@@ -6,6 +6,8 @@ import oci
|
||||
from oci.loggingingestion import LoggingClient
|
||||
from oci.loggingingestion.models import PutLogsDetails, LogEntryBatch, LogEntry
|
||||
|
||||
import definitions
|
||||
import params
|
||||
from logs.AppLogging import init_logger
|
||||
from pojo import ReserveResultPojo
|
||||
from pojo.ReserveResultPojo import PublishType
|
||||
@@ -43,7 +45,7 @@ class LogSender:
|
||||
msg = "{}, email: {}".format(result.message, result.email)
|
||||
self.send_log(msg, type=LOG_APPOINTMENT_ERROR)
|
||||
|
||||
def send_log(self, msg: str, source="Appointment", subject="appointment", type: str = "INFO"):
|
||||
def send_log(self, msg: str, source=definitions.LOG_SOURCE, subject="appointment", type: str = "INFO"):
|
||||
log_id = "ocid1.log.oc1.eu-frankfurt-1.amaaaaaacvc3jtia5enufv5jxe6binq4ndaty7pt5mk7uidipfd62ynwdhnq"
|
||||
response = self._loggingingestion_client.put_logs(
|
||||
log_id=log_id,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import pika
|
||||
import os
|
||||
|
||||
from db.DbManager import DataManager
|
||||
from logs.LogSender import LogSender
|
||||
@@ -22,18 +22,10 @@ MODEM_POOL_PORTS = [
|
||||
"/dev/tty.usbmodem1431407"
|
||||
]
|
||||
CARD_POOL_PORT = "/dev/tty.usbmodem1432101"
|
||||
|
||||
firebase_store_manager = DataManager()
|
||||
oracle_log_sender = LogSender()
|
||||
|
||||
# proxy
|
||||
PROXY_SERVER = "http://gw.ntnt.io:5959"
|
||||
PROXY_USERNAME = "panleicim-stc-fr-192012"
|
||||
PROXY_PASSWORD = "94sY7zwBG13i"
|
||||
|
||||
# rabittmq
|
||||
rabittMQ_host = "rabbitmq.lpaconsulting.fr"
|
||||
rabittMQ_port = 6672
|
||||
_credentials = pika.PlainCredentials('scrapy_rabbitmq', '4x!hReCbA5v3heKWfPJV-Y')
|
||||
rabittmq_connection = pika.BlockingConnection(
|
||||
pika.ConnectionParameters(host='rabbitmq.lpaconsulting.fr', port=6672, credentials=_credentials))
|
||||
PROXY_PASSWORD = "94sY7zwBG13i"
|
||||
@@ -1,7 +1,6 @@
|
||||
dataclasses_json==0.5.6
|
||||
firebase_admin==5.2.0
|
||||
pandas==1.4.1
|
||||
pika==1.2.0
|
||||
playwright==1.19.0
|
||||
pyserial==3.5
|
||||
python_gsmmodem_new==0.13.0
|
||||
|
||||
Binary file not shown.
Reference in New Issue
Block a user