import sys
import socket
import os
IPAddr=socket.gethostbyname(socket.gethostname())
#print(IPAddr)
if IPAddr[0:11] == "100.100.100": #4269
    host = "100.100.100.81"
    port = "5432"
    dbname = "sig4269"
    sigdb="sig4269"
    refdb="ref_geo4269"
    password = "xxxxx"
if IPAddr[0:9] == "192.168.0": #01
    host = "192.168.0.201"
    port = "5432"
    dbname = "sig01"
    sigdb="sig01"
    refdb="ref_geo01"
    password = "xxxxx"
if IPAddr[0:9] == "192.168.1": #0726
    host = "192.168.1.201"
    port = "5432"
    dbname = "sig0726"
    sigdb="sig0726"
    refdb="ref_geo0726"
    password = "xxxxx"
if sys.platform == 'linux':
    os_user = os.environ['USER']
else:
    os_user = os.environ['USERNAME']
if os_user == 'STAGE':
    os_user='stage'
if os_user == 'Administrateur':
    os_user='stage'