aboutsummaryrefslogtreecommitdiffstats
path: root/sanitycheck/tools/README.md
blob: 2d6b3d098a9ab726acc9af82e071f54097e96966 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
Standalone PNF Simulator configuration for HTTPS communication with VES
------------------------

### Description

docker-compose.yml prepares PNF simulator container for HTTPS communication with VES.

When docker-compose starts certs-init container fills connected volume with certificates, truststores, keystores, 
passwords etc. Next pnf-simulator container starts and connects to the same volume. On startup it should read password
values from proper files and set them in system environment variables. With these variables and files in volume 
application is ready to work on HTTPS.

### Prerequisites

1. certs-init container works with external AAF on cloud. Due to that fact it must have set correct IPs to workers that
has access to AAF. In docker-compose.yml fields with mentioned IPs are:
    
    * aaf-locate.onap
    * aaf-cm.onap
    * aaf-service.onap

### Start

**ATTENTION** 

Proper IPs to AAF must be set in the docker-compose.yml before start (as described in prerequisites)!

```
docker-compose up
```

### Send event

**ATTENTION**

``sanitycheck/events/eventToVes.json`` file which is request for sending event to VES must have correct ``vesServerURL`` 
field before sending event. 
IP of ``vesServerURL`` should be the same as given in docker-compose.yml in ``aaf-locate.onap`` field.
To use secured connection remember about setting protocol to https:// and port to proper secured port of VES.

To send event from PNF simulator to VES use this command from ``pnf-simulator/sanitycheck`` directory:

````
make generate-event
````

Sample ``sanitycheck/events/eventToVes.json`` file content is:

```json
{
  "vesServerUrl": "https://10.183.35.177:30417/eventListener/v7",
  "event": {
    "event": {
      "commonEventHeader": {
        "version": "4.0.1",
        "vesEventListenerVersion": "7.0.1",
        "domain": "fault",
        "eventName": "Fault_Vscf:Acs-Ericcson_PilotNumberPoolExhaustion",
        "eventId": "fault0000245",
        "sequence": 1,
        "priority": "High",
        "reportingEntityId": "cc305d54-75b4-431b-adb2-eb6b9e541234",
        "reportingEntityName": "ibcx0001vm002oam001",
        "sourceId": "de305d54-75b4-431b-adb2-eb6b9e546014",
        "sourceName": "scfx0001vm002cap001",
        "nfVendorName": "Ericsson",
        "nfNamingCode": "scfx",
        "nfcNamingCode": "ssc",
        "startEpochMicrosec": 1413378172000000,
        "lastEpochMicrosec": 1413378172000000,
        "timeZoneOffset": "UTC-05:30"
      },
      "faultFields": {
        "faultFieldsVersion": "4.0",
        "alarmCondition": "PilotNumberPoolExhaustion",
        "eventSourceType": "other",
        "specificProblem": "Calls cannot complete - pilot numbers are unavailable",
        "eventSeverity": "CRITICAL",
        "vfStatus": "Active",
        "alarmAdditionalInformation": {
          "PilotNumberPoolSize": "1000"
        }
      }
    }
  }
}

```

### Stop
```
docker-compose down
```