Ubuntu Pastebin

Paste from cmars at Tue, 30 Aug 2016 12:43:29 +0000

Download as text
 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
# Example use of local-monitors

bundle.yaml:
```
series: trusty                 
services:                      
    myapp:
        charm: "~/trusty/myapp"   
        num_units: 1           
    myapp-nrpe:             
        charm: "cs:trusty/nrpe"
    nagios:
        charm: "cs:trusty/nagios"       
        num_units: 1           

relations:
    - - "myapp:local-monitors"
      - "myapp-nrpe:local-monitors"
    - - "nagios"
      - "myapp-nrpe"
```

config.yaml:
```
myapp-nrpe: 
    monitors: |
        monitors:
            remote:
                nrpe:
                    check_http:
                        command: check_http
```

I've found that you need to declare every nagios check that your charm provides over the relation in the config.yaml.
Download as text