Commit e1b70428 authored by Thibault's avatar Thibault
Browse files

Modification scan clair

parent 32ba7756
......@@ -27,21 +27,11 @@ node{
stage('Scan Clair'){
sh '''
docker run -d --name db arminc/clair-db
sleep 15 # wait for db to come up
docker run -p 6060:6060 --link db:postgres -d --name clair arminc/clair-local-scan
sleep 1
DOCKER_GATEWAY=$(docker network inspect bridge --format "{{range .IPAM.Config}}{{.Gateway}}{{end}}")
wget -qO clair-scanner https://github.com/arminc/clair-scanner/releases/download/v8/clair-scanner_linux_amd64 && chmod +x clair-scanner
./clair-scanner --ip="http://172.17.0.1" -c 127.0.0.1 debian:buster || exit 0
'''
}
stage('Delete moi tous la dedans jveux plus rien reconnaitre'){
sh 'docker stop db'
sh 'docker stop clair'
sh 'docker rm db'
sh 'docker rm clair'
wget -qO clair-scanner https://github.com/arminc/clair-scanner/releases/download/v8/clair-scanner_linux_amd64 && chmod +x clair-scanner
./clair-scanner --ip="http://172.20.0.6" -c 127.0.0.1 debian:buster || exit 0
'''
}
stage('Push on repo nexus'){
docker.withRegistry(registryProject,'reg2'){
img.push 'latest'
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment