added environmant path

This commit is contained in:
CHIEFSOFT\ameye
2024-09-18 06:42:53 -04:00
parent 8ab04e55e1
commit 3c436fa40a
5 changed files with 167 additions and 1 deletions
+1
View File
@@ -1,6 +1,7 @@
CONTAINER_PORT=9088
UID=1000
CI_ENV=development
API_ENDPOINT="https://apigate.lotus.g1.wrenchboard.com"
# $arr["host"] = "10.10.10.23";
# $arr["name"] = "wrenchboard";
# $arr["user"] = "wrenchboard";
+80
View File
@@ -0,0 +1,80 @@
CONTAINER_PORT=9088
UID=1000
CI_ENV=development
API_ENDPOINT="https://apigate.lotus.g1.wrenchboard.com"
# $arr["host"] = "10.10.10.23";
# $arr["name"] = "wrenchboard";
# $arr["user"] = "wrenchboard";
# $arr["pass"] = "wrenchboard";
# $arr["port"] = 5432;
#--------------------------------------------------------------------
# Example Environment Configuration file
#
# This file can be used as a starting point for your own
# custom .env files, and contains most of the possible settings
# available in a default install.
#
# By default, all of the settings are commented out. If you want
# to override the setting, you must un-comment it by removing the '#'
# at the beginning of the line.
#--------------------------------------------------------------------
#--------------------------------------------------------------------
# ENVIRONMENT
#--------------------------------------------------------------------
# CI_ENVIRONMENT = production
#--------------------------------------------------------------------
# APP
#--------------------------------------------------------------------
# app.baseURL = ''
# If you have trouble with `.`, you could also use `_`.
# app_baseURL = ''
# app.forceGlobalSecureRequests = false
# app.CSPEnabled = false
#--------------------------------------------------------------------
# DATABASE
#--------------------------------------------------------------------
# database.default.hostname = localhost
# database.default.database = ci4
# database.default.username = root
# database.default.password = root
# database.default.DBDriver = MySQLi
# database.default.DBPrefix =
# database.default.port = 3306
# If you use MySQLi as tests, first update the values of Config\Database::$tests.
# database.tests.hostname = localhost
# database.tests.database = ci4_test
# database.tests.username = root
# database.tests.password = root
# database.tests.DBDriver = MySQLi
# database.tests.DBPrefix =
# database.tests.charset = utf8mb4
# database.tests.DBCollat = utf8mb4_general_ci
# database.tests.port = 3306
#--------------------------------------------------------------------
# ENCRYPTION
#--------------------------------------------------------------------
# encryption.key =
#--------------------------------------------------------------------
# SESSION
#--------------------------------------------------------------------
# session.driver = 'CodeIgniter\Session\Handlers\FileHandler'
# session.savePath = null
#--------------------------------------------------------------------
# LOGGER
#--------------------------------------------------------------------
# logger.threshold = 4
+80
View File
@@ -0,0 +1,80 @@
CONTAINER_PORT=9088
UID=1000
CI_ENV=development
API_ENDPOINT="https://apigate.orion.g1.wrenchboard.com"
# $arr["host"] = "10.10.10.23";
# $arr["name"] = "wrenchboard";
# $arr["user"] = "wrenchboard";
# $arr["pass"] = "wrenchboard";
# $arr["port"] = 5432;
#--------------------------------------------------------------------
# Example Environment Configuration file
#
# This file can be used as a starting point for your own
# custom .env files, and contains most of the possible settings
# available in a default install.
#
# By default, all of the settings are commented out. If you want
# to override the setting, you must un-comment it by removing the '#'
# at the beginning of the line.
#--------------------------------------------------------------------
#--------------------------------------------------------------------
# ENVIRONMENT
#--------------------------------------------------------------------
# CI_ENVIRONMENT = production
#--------------------------------------------------------------------
# APP
#--------------------------------------------------------------------
# app.baseURL = ''
# If you have trouble with `.`, you could also use `_`.
# app_baseURL = ''
# app.forceGlobalSecureRequests = false
# app.CSPEnabled = false
#--------------------------------------------------------------------
# DATABASE
#--------------------------------------------------------------------
# database.default.hostname = localhost
# database.default.database = ci4
# database.default.username = root
# database.default.password = root
# database.default.DBDriver = MySQLi
# database.default.DBPrefix =
# database.default.port = 3306
# If you use MySQLi as tests, first update the values of Config\Database::$tests.
# database.tests.hostname = localhost
# database.tests.database = ci4_test
# database.tests.username = root
# database.tests.password = root
# database.tests.DBDriver = MySQLi
# database.tests.DBPrefix =
# database.tests.charset = utf8mb4
# database.tests.DBCollat = utf8mb4_general_ci
# database.tests.port = 3306
#--------------------------------------------------------------------
# ENCRYPTION
#--------------------------------------------------------------------
# encryption.key =
#--------------------------------------------------------------------
# SESSION
#--------------------------------------------------------------------
# session.driver = 'CodeIgniter\Session\Handlers\FileHandler'
# session.savePath = null
#--------------------------------------------------------------------
# LOGGER
#--------------------------------------------------------------------
# logger.threshold = 4
+4
View File
@@ -102,4 +102,8 @@ abstract class BaseController extends Controller
curl_close($curl);
return json_decode($result, true);
}
public function wrenchApiServer():string{
return getenv("API_ENDPOINT")."/en/promo/api/v1/";
}
}
+2 -1
View File
@@ -14,10 +14,11 @@ class Home extends BaseController
// echo $promoOwner;
//http://10.204.5.100:9083/en/promo/api/v1/start
// echo $backend_server = getenv("API_ENDPOINT");
$in["promo"] = $promo;
$in["promo_owner"] = $promoOwner;
$out = $this->APIcall('POST','http://10.204.5.100:9083/en/promo/api/v1/start',[]);
$out = $this->APIcall('POST', $this->wrenchApiServer(). 'start',[]);
//var_dump($out);
return view('welcome_message', $out);
}