|
|
|
|
@ -10,9 +10,9 @@ def get_production_connection():
|
|
|
|
|
try:
|
|
|
|
|
# Konfigurasi koneksi database produksi
|
|
|
|
|
production_connection = psycopg2.connect(
|
|
|
|
|
dbname="digital_twin",
|
|
|
|
|
user="digital_twin",
|
|
|
|
|
password="Pr0jec7@D!g!tTwiN",
|
|
|
|
|
dbname=COLLECTOR_NAME,
|
|
|
|
|
user=COLLECTOR_CREDENTIAL_USER,
|
|
|
|
|
password=COLLECTOR_CREDENTIAL_PASSWORD,
|
|
|
|
|
host=COLLECTOR_HOSTNAME,
|
|
|
|
|
port=COLLECTOR_PORT,
|
|
|
|
|
)
|
|
|
|
|
@ -33,16 +33,16 @@ def get_connection():
|
|
|
|
|
# password="ariwa"
|
|
|
|
|
# )
|
|
|
|
|
connection = psycopg2.connect(
|
|
|
|
|
dbname="digital_twin",
|
|
|
|
|
user="postgres",
|
|
|
|
|
password="postgres",
|
|
|
|
|
dbname=DATABASE_NAME,
|
|
|
|
|
user=DATABASE_CREDENTIAL_USER,
|
|
|
|
|
password=DATABASE_CREDENTIAL_PASSWORD,
|
|
|
|
|
host=DATABASE_HOSTNAME,
|
|
|
|
|
port=DATABASE_PORT,
|
|
|
|
|
)
|
|
|
|
|
connection_wo_db = psycopg2.connect(
|
|
|
|
|
dbname="digital_twin",
|
|
|
|
|
user="postgres",
|
|
|
|
|
password="postgres",
|
|
|
|
|
dbname=COLLECTOR_NAME,
|
|
|
|
|
user=COLLECTOR_CREDENTIAL_USER,
|
|
|
|
|
password=COLLECTOR_CREDENTIAL_PASSWORD,
|
|
|
|
|
host=COLLECTOR_HOSTNAME,
|
|
|
|
|
port=COLLECTOR_PORT,
|
|
|
|
|
)
|
|
|
|
|
|