Added dockerfile and yaml file
[ealt-edge.git] / example-apps / ROBO / retail_app / config.py
1 #
2 # Copyright 2020 Huawei Technologies Co., Ltd.
3 #
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
7 #
8 #     http://www.apache.org/licenses/LICENSE-2.0
9 #
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
15 #
16
17 import os
18
19 # [Server Configurations]
20 server_port = 9995
21 # server_address = os.environ.get('LISTEN_IP')
22 server_address = "0.0.0.0"
23
24 # [InfluxDB config]
25 IPADDRESS = os.environ.get('INFLUXDB_IP')
26 PORT = os.environ.get('INFLUXDB_PORT')
27 DATABASE_NAME = "Shelf_Inventry"
28
29 # [SSL Configurations]
30 ssl_enabled = False
31 ssl_protocol = "TLSv1.2"
32 ssl_ciphers = ["TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256",
33                "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256",
34                "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384",
35                "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384"]
36 ssl_certfilepath = "/usr/app/ssl/server_tls.crt"
37 ssl_keyfilepath = "/usr/app/ssl/server_tls.key"
38 ssl_cacertpath = "/usr/app/ssl/ca.crt"
39 ssl_server_name = os.environ.get('SERVER_NAME', "ealtedge")
40
41 # [Service Configurations]
42 api_gateway = os.environ.get("API_GATEWAY", "apigw.mep.org")
43 # Obj_Det_SER_IP = os.environ.get("OBJ_DET_SER_IP", "localhost")
44
45 Obj_Det_SER_IP = os.environ.get("OBJ_DET_SER_IP")
46 # Obj_Det_SER_IP = os.environ.get("OBJ_DET_SER_IP")
47 Obj_Det_SER_PORT = os.environ.get("OBJ_DET_SER_PORT")
48 # Obj_Det_SER_PORT = os.environ.get("OBJ_DET_SER_PORT")
49 Obj_Det = os.environ.get("OBJ_DETECTION", "mep/v1/obj_detection")
50
51 # [Constants]
52 # detection_url = "http://" + api_gateway + "/" + Obj_Det
53 detection_url = "http://" + Obj_Det_SER_IP + ":" + Obj_Det_SER_PORT + "/" + \
54                                            Obj_Det + "/"