Skip to content

Commit e7a3077

Browse files
authored
Merge pull request #40 from ARGOeu/devel
Version 0.2.1
2 parents 231832a + 7989bc0 commit e7a3077

17 files changed

+308
-528
lines changed

.travis.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
language: python
2-
# Target py version 2.7
2+
# Target py version 3.6
33
python:
4-
- "2.7"
4+
- "3.6"
55

6-
script: pytest
6+
script:
7+
- pip install -r ./requirements.txt
8+
- pytest

Jenkinsfile

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
pipeline {
2+
agent any
3+
options {
4+
checkoutToSubdirectory('argo-alert')
5+
}
6+
environment {
7+
PROJECT_DIR="argo-alert"
8+
}
9+
stages {
10+
stage ('Test Centos 7') {
11+
agent {
12+
docker {
13+
image 'argo.registry:5000/epel-7-ams'
14+
args '-u jenkins:jenkins'
15+
}
16+
}
17+
steps {
18+
sh '''
19+
cd ${WORKSPACE}/$PROJECT_DIR
20+
pipenv install -r requirements.txt
21+
pipenv run python setup.py install
22+
pipenv run coverage run --source=./argoalert -m py.test
23+
pipenv run coverage xml
24+
pipenv run py.test ./ --junitxml=./junit.xml
25+
'''
26+
cobertura coberturaReportFile: '**/coverage.xml'
27+
}
28+
}
29+
}
30+
post {
31+
always {
32+
cleanWs()
33+
}
34+
}
35+
}

README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,19 @@ of your own email aliases (before using client contact emails) issue:
137137
The rule list will be generated using the configured client sources but each client
138138
email will be replaced (using round-robin method) by a test-email (as defined in the cli arg list)
139139

140+
Ingore notification flag for groups (top-level)
141+
-----------------------------------------------
142+
For the special case that top level groups have different notification flag requirement the special cli parameter
143+
`--group-notification-flag` or `-g` can be used and set to `true` or `false`.
144+
For example if config file honors the use of notification flag in general but user needs to turn it of for top level
145+
groups, can issue:
146+
147+
$ argo-alert-rulegen -c /path/to/argo-alert.conf -g false
148+
149+
The rule list will be generated using the configured client sources but each client
150+
email will be replaced (using round-robin method) by a test-email (as defined in the cli arg list)
151+
152+
140153
Run tests
141154
---------
142155

0 commit comments

Comments
 (0)