Replace under scores in xapp helm resource files that create helm chart rendering...
[it/dev.git] / xapp_onboarder / README.md
1 xApp Onboarder
2 ==============
3
4 xApp onboarder onboards xApp to the near-rt RIC platform. The operators provides the xApp descriptors and their schemas, the xApp onboarder generates the xApp helm charts dynamically.
5
6 ## Install xapp_onboarder
7
8 Run  [pip](https://pip.pypa.io/en/stable/) to install xapp_onboarder.
9
10 ```bash
11 pip install xapp_onboarder
12 ```
13
14 ## Prerequisite Requirements
15 A helm chart repo is needed to store the xApp helm charts. You can use [chartmuseum](https://github.com/helm/chartmuseum) for this purpose.
16  
17 Environment variables:
18 * **FLASK_SERVER_NAME**: Address that the xapp_onboarder is listening on. Default http://0.0.0.0:8888
19 * **CHART_REPO_URL**: helm chart repo URL. Default http://0.0.0.0:8080
20 * **DBAAS_SERVICE_HOST**: DBAAS service host URL that will be injected into the xApp config
21 * **DBAAS_MASTER_NAME**: DBAAS_HA sentinel master URL that will be injected into the xApp config
22 * **DBAAS_SERVICE_SENTINEL_PORT**: DBAAS_HA sentinel port that will be injected into the xApp config
23 * **DBAAS_SERVICE_PORT**: DBAAS service port that will be injected into the xApp config
24
25 ## Configurations
26 Environment variables:
27 * **CHART_WORKSPACE_PATH**: Temporary directory that will store the xApp helm chart artifacts. Default /tmp/xapp_onboarder
28 * **CHART_WORKSPACE_SIZE**: Size limit of the temporary directory. Default 500MB
29 * **ALLOW_REDEPLOY**: Enable or disable redeploying of xApp helm charts. Default True
30 * **HTTP_TIME_OUT**: Timeout of all http requests. Default 10 
31 * **HTTP_RETRY**: Number of retry xapp_onboarder will use for the http requests. Default 3
32
33 ## Run the API server
34 ```bash
35 python3 -m xapp_onboarder.server.server
36 ```
37 Or we recommend you can set up the symbolic link in your PATH
38 ```bash
39 ln -s $(pip show xapp_onboarder | grep Location | awk '{printf  $2 "/xapp_onboarder/xapp_onboarder"}') /usr/local/bin/xapp_onboarder
40 ```
41 Then you can run the server
42 ```bash
43 xapp_onboarder
44 ```
45 ## Run the CLI tool
46 ```bash
47 python3 -m xapp_onboarder.server.cli
48 ```
49 Or we recommend you can set up the symbolic link in your PATH
50 ```bash
51 ln -s $(pip show xapp_onboarder | grep Location | awk '{printf  $2 "/xapp_onboarder/cli"}') /usr/local/bin/cli
52 ```
53 Then you can run the server
54 ```bash
55 cli
56 ```