diff --git a/Application.cfc b/Application.cfc index caa4626..74cf4fa 100644 --- a/Application.cfc +++ b/Application.cfc @@ -1,34 +1,37 @@ -component { - this.name = "contractor"; - this.applicationTimeout = createTimeSpan(0, 0, 3, 0); - this.sessionmanagement = true; - this.datasource = "baza"; - this.restEnabled = true; - this.restSettings = {skipCFCWithError: true}; + - // defaults - var dbHost = "postgresqlk8s-master.418f9960-2eb7-4429-b2ec-ac64319d7268.svc.cluster.local"; - var dbPort = "5432"; - var dbName = "baza"; + + + + + + - // из env или дефолт - var sys = createObject("java", "java.lang.System"); - var user = sys.getenv("DB_USER"); - if (isNull(user) || !len(user)) user = "super"; - var pass = sys.getenv("DB_PASS"); - if (isNull(pass) || !len(pass)) pass = "hoHdkA23yxlD9oMUlZ1bIbNyc6DE2mNJmyHMNkEpVD1F4suQs7O2lyN4t0qITyzt"; + - this.datasources["baza"] = { + + + + + + + + + + + - function onRequestStart(targetPage) { - if (structKeyExists(url, "reload")) applicationStop(); - return true; - } -} + + + + + + +